Trying to compile GZDoom with Linux

Advanced OpenGL source port fork from ZDoom, picking up where ZDoomGL left off.
[Home] [Download] [Git builds (Win)] [Git builds (Mac)] [Wiki] [Repo] [Bugs&Suggestions]

Moderator: Graf Zahl

User avatar
Graf Zahl
GZDoom Developer
GZDoom Developer
Posts: 7148
Joined: Wed Jul 20, 2005 9:48
Location: Germany
Contact:

Post by Graf Zahl »

Can you please post the command line to apply the patch? I'm not using the patch tool on a regular basis and all the standard tries failed so far.
Costja
Posts: 59
Joined: Thu Sep 08, 2005 20:02
Contact:

Post by Costja »

When in gzdoom dir run "patch -p1 < patch27"
Costja
Posts: 59
Joined: Thu Sep 08, 2005 20:02
Contact:

Post by Costja »

Following recommendation by GuntherDW and recommendations in READMEs I removed -IFLAC and -Izlib in the makefile.linux
So now those lines are:

Code: Select all

CFLAGS += `pkg-config gtk+-2.0 --cflags`
CFLAGS += -DHAVE_FILELENGTH -D__forceinline=inline `sdl-config --cflags`
CFLAGS += -Dstricmp=strcasecmp -Dstrnicmp=strncasecmp -DNEED_STRUPR
So now headers shipped with these libraries will be used instead of zdoom ones.
Attachments
patch27L.zip
small update
(446 Bytes) Downloaded 138 times
Last edited by Costja on Tue Oct 16, 2007 21:38, edited 1 time in total.
stevenaaus
Posts: 35
Joined: Fri Sep 21, 2007 2:09
Location: Australia
Contact:

Post by stevenaaus »

Patch is a bit of a bitch. I alias:
"alias patchy='patch --dry-run"
and test out every patch first this way to make sure everything is fine
User avatar
Graf Zahl
GZDoom Developer
GZDoom Developer
Posts: 7148
Joined: Wed Jul 20, 2005 9:48
Location: Germany
Contact:

Post by Graf Zahl »

It was the line breaks. Apparently my patch.exe doesn't like Unix text files.
disturbedite
Posts: 34
Joined: Fri Jul 07, 2006 1:35
Location: 66 Exeter Street

Post by disturbedite »

i like that with most unix/linux text editors you can choose which EOL format you wanna use...
User avatar
Graf Zahl
GZDoom Developer
GZDoom Developer
Posts: 7148
Joined: Wed Jul 20, 2005 9:48
Location: Germany
Contact:

Post by Graf Zahl »

Most Windows editors have the same, some even a conversion option. Unfortunately some cheap tools are a little inflexible due to badly written code.
Costja
Posts: 59
Joined: Thu Sep 08, 2005 20:02
Contact:

Post by Costja »

Ok, patch should be fixed now. Sorry, it was my mistake to ignore that fuzz warning.

Graf Zahl, should I upload patched source somewhere?
User avatar
Graf Zahl
GZDoom Developer
GZDoom Developer
Posts: 7148
Joined: Wed Jul 20, 2005 9:48
Location: Germany
Contact:

Post by Graf Zahl »

No, after converting the patch to Windows format it worked fine.
User avatar
TheDarkArchon
Posts: 1000
Joined: Wed Jul 06, 2005 11:58
Location: What's that fucking smell
Contact:

Post by TheDarkArchon »

Graf Zahl wrote:Most Windows editors have the same, some even a conversion option.
VS2005 does, I know that, even though it appear to have the ability to run programs from itself without going into debug mode missing (the reason why I prefer VC++ 6.0 for code).
User avatar
Graf Zahl
GZDoom Developer
GZDoom Developer
Posts: 7148
Joined: Wed Jul 20, 2005 9:48
Location: Germany
Contact:

Post by Graf Zahl »

I am using VS2005. What are you talking about? I can't make any sense out of your sentence.
User avatar
TheDarkArchon
Posts: 1000
Joined: Wed Jul 06, 2005 11:58
Location: What's that fucking smell
Contact:

Post by TheDarkArchon »

Basically, VC++ 6.0's Execute <projectname>.exe command (In the build menu) doesn't appear to be in VS2005. At least, I can't find it in VS2005.
User avatar
Graf Zahl
GZDoom Developer
GZDoom Developer
Posts: 7148
Joined: Wed Jul 20, 2005 9:48
Location: Germany
Contact:

Post by Graf Zahl »

Debug -> Start Without Debugging seems to be the same.
User avatar
Daniele C.
Posts: 54
Joined: Sun Oct 21, 2007 23:24
Location: Roma

Post by Daniele C. »

Hi, I have Gentoo Linux and I am a C programmer (I also compiled various flavoors of the origina Doom source code when I was on Windows), so I would like to help to debug the GZDoom port (I might also mantain the package at Gentoo, if you agree).

I cannot get GZDoom to compile, I had to fix a few issues before getting stuck at last:

1. the config directory is not present, so bootstrap cannot do its work
2. after having created the config directory the src/Makefile.in is missing. I copied Makefile.linux there
3. now bootstrap will do its job, but finally it cannot find libfmod. I manually edited the configure script not to link -lfmod-3.74 but -lfmod (I have the package for v3.75 installed)

In the end I got stuck:

Code: Select all

g++ -lFLAC++ -lFLAC -lz -lfmod `sdl-config --libs` -Wl,-Map=zdoom.map releaseobj/autostart.o \
         \
        releaseobj/autozend.o -o zdoom
g++: releaseobj/autostart.o: No such file or directory
g++: releaseobj/autozend.o: No such file or directory
I compiled those two objects with:

Code: Select all

gcc -c src/autozend.cpp -o src/releaseobj/autozend.o
gcc -c src/autostart.cpp -o src/releaseobj/autostart.o
but obviously they don't work, as I now get:

Code: Select all

g++ -lFLAC++ -lFLAC -lz -lfmod `sdl-config --libs` -Wl,-Map=zdoom.map releaseobj/autostart.o \
         \
        releaseobj/autozend.o -o zdoom
/usr/lib/gcc/i686-pc-linux-gnu/4.1.2/../../../crt1.o: In function `_start':
(.text+0x18): undefined reference to `main'
collect2: ld returned 1 exit status
That's possibly due to missing -D definitions on the gcc commandline

I have tried to remove -IFLAC and -Izlib (as suggested by the patch) but that does not work in my case - or I am not yet at the failure point that will need such changes

Thanks!
Costja
Posts: 59
Joined: Thu Sep 08, 2005 20:02
Contact:

Post by Costja »

Are any changes required to run ZDoom on your system? IMHO, ZDoom supports Linux more "cleanly", so its better to patch it first.

AFAIK configure script in gzdoom archive is not working. i compile GZDoom on my system without configuring it (after applying two latest patches from this thread). Makefile.linux is included from the makefile.
Locked

Return to “GZDoom”