How to compile x64 ZDoom & GZDoom?

Archive of the old editing forum
Forum rules
Before asking on how to use a ZDoom feature, read the ZDoom wiki first. This forum is archived - please use this set of forums to ask new questions.
Locked
User avatar
Nash
 
 
Posts: 17501
Joined: Mon Oct 27, 2003 12:07 am
Location: Kuala Lumpur, Malaysia
Contact:

How to compile x64 ZDoom & GZDoom?

Post by Nash »

Thread title. I think it's high time I start moving away from 32 bit builds. Thing is, I don't see anywhere in CMake where I can specify the build to be x64. Help?

Also, what about the supporting DLLs (Fmod, OpenAL, libsnd etc etc), how would I build those to be 64 bit?
_mental_
 
 
Posts: 3820
Joined: Sun Aug 07, 2011 4:32 am

Re: How to compile x64 ZDoom & GZDoom?

Post by _mental_ »

You need to configure to new build directory and select Visual Studio 14 2015 64-bit in CMake's generator dialog.
User avatar
Nash
 
 
Posts: 17501
Joined: Mon Oct 27, 2003 12:07 am
Location: Kuala Lumpur, Malaysia
Contact:

Re: How to compile x64 ZDoom & GZDoom?

Post by Nash »

Errors:
Severity Code Description Project File Line Suppression State
Error LNK2019 unresolved external symbol mpg123_init referenced in function "protected: virtual bool __cdecl MPG123Decoder::open(class FileReader *)" (?open@MPG123Decoder@@MEAA_NPEAVFileReader@@@Z) zdoom D:\Projects\Game Projects\Doom\GZDoom-GPL-build\src\mpg123_decoder.obj 1
Error LNK2019 unresolved external symbol mpg123_new referenced in function "protected: virtual bool __cdecl MPG123Decoder::open(class FileReader *)" (?open@MPG123Decoder@@MEAA_NPEAVFileReader@@@Z) zdoom D:\Projects\Game Projects\Doom\GZDoom-GPL-build\src\mpg123_decoder.obj 1
Error LNK2019 unresolved external symbol mpg123_delete referenced in function "public: virtual __cdecl MPG123Decoder::~MPG123Decoder(void)" (??1MPG123Decoder@@UEAA@XZ) zdoom D:\Projects\Game Projects\Doom\GZDoom-GPL-build\src\mpg123_decoder.obj 1
Error LNK2019 unresolved external symbol mpg123_format_none referenced in function "protected: virtual bool __cdecl MPG123Decoder::open(class FileReader *)" (?open@MPG123Decoder@@MEAA_NPEAVFileReader@@@Z) zdoom D:\Projects\Game Projects\Doom\GZDoom-GPL-build\src\mpg123_decoder.obj 1
Error LNK2019 unresolved external symbol mpg123_format referenced in function "protected: virtual bool __cdecl MPG123Decoder::open(class FileReader *)" (?open@MPG123Decoder@@MEAA_NPEAVFileReader@@@Z) zdoom D:\Projects\Game Projects\Doom\GZDoom-GPL-build\src\mpg123_decoder.obj 1
Error LNK2019 unresolved external symbol mpg123_getformat referenced in function "public: virtual void __cdecl MPG123Decoder::getInfo(int *,enum ChannelConfig *,enum SampleType *)" (?getInfo@MPG123Decoder@@UEAAXPEAHPEAW4ChannelConfig@@PEAW4SampleType@@@Z) zdoom D:\Projects\Game Projects\Doom\GZDoom-GPL-build\src\mpg123_decoder.obj 1
Error LNK2019 unresolved external symbol mpg123_open_handle referenced in function "protected: virtual bool __cdecl MPG123Decoder::open(class FileReader *)" (?open@MPG123Decoder@@MEAA_NPEAVFileReader@@@Z) zdoom D:\Projects\Game Projects\Doom\GZDoom-GPL-build\src\mpg123_decoder.obj 1
Error LNK2019 unresolved external symbol mpg123_close referenced in function "public: virtual __cdecl MPG123Decoder::~MPG123Decoder(void)" (??1MPG123Decoder@@UEAA@XZ) zdoom D:\Projects\Game Projects\Doom\GZDoom-GPL-build\src\mpg123_decoder.obj 1
Error LNK2019 unresolved external symbol mpg123_read referenced in function "public: virtual unsigned __int64 __cdecl MPG123Decoder::read(char *,unsigned __int64)" (?read@MPG123Decoder@@UEAA_KPEAD_K@Z) zdoom D:\Projects\Game Projects\Doom\GZDoom-GPL-build\src\mpg123_decoder.obj 1
Error LNK2019 unresolved external symbol mpg123_tell referenced in function "public: virtual unsigned __int64 __cdecl MPG123Decoder::getSampleOffset(void)" (?getSampleOffset@MPG123Decoder@@UEAA_KXZ) zdoom D:\Projects\Game Projects\Doom\GZDoom-GPL-build\src\mpg123_decoder.obj 1
Error LNK2019 unresolved external symbol mpg123_seek referenced in function "public: virtual bool __cdecl MPG123Decoder::seek(unsigned __int64)" (?seek@MPG123Decoder@@UEAA_N_K@Z) zdoom D:\Projects\Game Projects\Doom\GZDoom-GPL-build\src\mpg123_decoder.obj 1
Error LNK2019 unresolved external symbol mpg123_length referenced in function "public: virtual unsigned __int64 __cdecl MPG123Decoder::getSampleLength(void)" (?getSampleLength@MPG123Decoder@@UEAA_KXZ) zdoom D:\Projects\Game Projects\Doom\GZDoom-GPL-build\src\mpg123_decoder.obj 1
Error LNK2019 unresolved external symbol mpg123_replace_reader_handle referenced in function "protected: virtual bool __cdecl MPG123Decoder::open(class FileReader *)" (?open@MPG123Decoder@@MEAA_NPEAVFileReader@@@Z) zdoom D:\Projects\Game Projects\Doom\GZDoom-GPL-build\src\mpg123_decoder.obj 1
Error LNK2019 unresolved external symbol sf_open_virtual referenced in function "protected: virtual bool __cdecl SndFileDecoder::open(class FileReader *)" (?open@SndFileDecoder@@MEAA_NPEAVFileReader@@@Z) zdoom D:\Projects\Game Projects\Doom\GZDoom-GPL-build\src\sndfile_decoder.obj 1
Error LNK2019 unresolved external symbol sf_seek referenced in function "public: virtual unsigned __int64 __cdecl SndFileDecoder::getSampleOffset(void)" (?getSampleOffset@SndFileDecoder@@UEAA_KXZ) zdoom D:\Projects\Game Projects\Doom\GZDoom-GPL-build\src\sndfile_decoder.obj 1
Error LNK2019 unresolved external symbol sf_readf_float referenced in function "public: virtual unsigned __int64 __cdecl SndFileDecoder::read(char *,unsigned __int64)" (?read@SndFileDecoder@@UEAA_KPEAD_K@Z) zdoom D:\Projects\Game Projects\Doom\GZDoom-GPL-build\src\sndfile_decoder.obj 1
Error LNK2019 unresolved external symbol sf_close referenced in function "public: virtual __cdecl SndFileDecoder::~SndFileDecoder(void)" (??1SndFileDecoder@@UEAA@XZ) zdoom D:\Projects\Game Projects\Doom\GZDoom-GPL-build\src\sndfile_decoder.obj 1
Error LNK1120 17 unresolved externals zdoom D:\Projects\Game Projects\Doom\GZDoom-GPL-build\Release\gzdoom.exe 1
Warnings:
Severity Code Description Project File Line Suppression State
Warning D9002 ignoring unknown option '/arch:SSE2' updaterevision D:\Projects\Game Projects\Doom\GZDoom-GPL-build\tools\updaterevision\cl 1
Warning D9002 ignoring unknown option '/arch:SSE2' bz2 D:\Projects\Game Projects\Doom\GZDoom-GPL-build\bzip2\cl 1
Warning D9002 ignoring unknown option '/arch:SSE2' gdtoa D:\Projects\Game Projects\Doom\GZDoom-GPL-build\gdtoa\cl 1
Warning D9002 ignoring unknown option '/arch:SSE2' lemon D:\Projects\Game Projects\Doom\GZDoom-GPL-build\tools\lemon\cl 1
Warning C4244 '=': conversion from '__int64' to 'int', possible loss of data lemon D:\Projects\Game Projects\Doom\GZDoom-GPL\tools\lemon\lemon.c 412
Warning C4267 'function': conversion from 'size_t' to 'int', possible loss of data lemon D:\Projects\Game Projects\Doom\GZDoom-GPL\tools\lemon\lemon.c 1949
Warning C4267 'function': conversion from 'size_t' to 'int', possible loss of data lemon D:\Projects\Game Projects\Doom\GZDoom-GPL\tools\lemon\lemon.c 1960
Warning D9002 ignoring unknown option '/arch:SSE2' lzma D:\Projects\Game Projects\Doom\GZDoom-GPL-build\lzma\cl 1
Warning D9002 ignoring unknown option '/arch:SSE2' jpeg D:\Projects\Game Projects\Doom\GZDoom-GPL-build\jpeg-6b\cl 1
Warning D9002 ignoring unknown option '/arch:SSE2' gme D:\Projects\Game Projects\Doom\GZDoom-GPL-build\game-music-emu\gme\cl 1
Warning D9002 ignoring unknown option '/arch:SSE2' dumb D:\Projects\Game Projects\Doom\GZDoom-GPL-build\dumb\cl 1
Warning D9002 ignoring unknown option '/arch:SSE2' re2c D:\Projects\Game Projects\Doom\GZDoom-GPL-build\tools\re2c\cl 1
Warning D9002 ignoring unknown option '/arch:SSE2' z D:\Projects\Game Projects\Doom\GZDoom-GPL-build\zlib\cl 1
Warning C4244 'return': conversion from '__int64' to 'long', possible loss of data gme D:\Projects\Game Projects\Doom\GZDoom-GPL\game-music-emu\gme\Music_Emu.cpp 309
Warning C4244 'argument': conversion from '__int64' to 'uint32_t', possible loss of data re2c D:\Projects\Game Projects\Doom\GZDoom-GPL-build\tools\src\parse\lex.re 616
Warning C4244 'argument': conversion from '__int64' to 'uint32_t', possible loss of data re2c D:\Projects\Game Projects\Doom\GZDoom-GPL-build\tools\src\parse\lex.re 648
Warning D9002 ignoring unknown option '/arch:SSE2' zipdir D:\Projects\Game Projects\Doom\GZDoom-GPL-build\tools\zipdir\cl 1
Warning D9002 ignoring unknown option '/arch:SSE2' zdoom D:\Projects\Game Projects\Doom\GZDoom-GPL-build\src\cl 1
Warning D9002 ignoring unknown option '/arch:SSE2' zdoom D:\Projects\Game Projects\Doom\GZDoom-GPL-build\src\cl 1
Warning D9002 ignoring unknown option '/arch:SSE2' zdoom D:\Projects\Game Projects\Doom\GZDoom-GPL-build\src\cl 1
Warning D9002 ignoring unknown option '/arch:SSE2' zdoom D:\Projects\Game Projects\Doom\GZDoom-GPL-build\src\cl 1
Warning D9002 ignoring unknown option '/arch:SSE2' zdoom D:\Projects\Game Projects\Doom\GZDoom-GPL-build\src\cl 1
Warning D9002 ignoring unknown option '/arch:SSE2' zdoom D:\Projects\Game Projects\Doom\GZDoom-GPL-build\src\cl 1
Warning LNK4199 /DELAYLOAD:OpenAL32.dll ignored; no imports found from OpenAL32.dll zdoom D:\Projects\Game Projects\Doom\GZDoom-GPL-build\src\LINK 1
Warning LNK4199 /DELAYLOAD:libmpg123-0.dll ignored; no imports found from libmpg123-0.dll zdoom D:\Projects\Game Projects\Doom\GZDoom-GPL-build\src\LINK 1
Warning LNK4199 /DELAYLOAD:libsndfile-1.dll ignored; no imports found from libsndfile-1.dll zdoom D:\Projects\Game Projects\Doom\GZDoom-GPL-build\src\LINK 1
Warning LNK4272 library machine type 'X86' conflicts with target machine type 'x64' zdoom C:\SDK\libsndfile\lib\libsndfile-1.lib 1
Warning LNK4272 library machine type 'X86' conflicts with target machine type 'x64' zdoom C:\SDK\mpg123-1.20.1-x86\libmpg123-0.lib 1
Fun stuff. :mrgreen: Some help please? ;(
User avatar
Graf Zahl
Lead GZDoom+Raze Developer
Lead GZDoom+Raze Developer
Posts: 49238
Joined: Sat Jul 19, 2003 10:19 am
Location: Germany

Re: How to compile x64 ZDoom & GZDoom?

Post by Graf Zahl »

Looks like you are trying to link to 32 bit versions of libsndfile and libmpg123. You have to link with 64 bit versions and use 64 bit DLLs.
User avatar
Nash
 
 
Posts: 17501
Joined: Mon Oct 27, 2003 12:07 am
Location: Kuala Lumpur, Malaysia
Contact:

Re: How to compile x64 ZDoom & GZDoom?

Post by Nash »

Graf Zahl wrote:Looks like you are trying to link to 32 bit versions of libsndfile and libmpg123. You have to link with 64 bit versions and use 64 bit DLLs.
Thanks, everything works perfectly now. GZDoom-GPL now comes in x86 and x64 flavours, yay!
Blue Shadow
Posts: 5046
Joined: Sun Nov 14, 2010 12:59 am

Re: How to compile x64 ZDoom & GZDoom?

Post by Blue Shadow »

@Nash: How did you resolve the non-OpenAL-related warnings? I'm getting warnings like those.

I'm also getting this:

Code: Select all

dinput8.lib(dilib2.obj) : warning LNK4078: multiple '.text' sections found with different attributes (C0500040) [C:\Users\Night Creature\Repos\zdoom_builds\src\zdoom.vcxproj]
User avatar
Graf Zahl
Lead GZDoom+Raze Developer
Lead GZDoom+Raze Developer
Posts: 49238
Joined: Sat Jul 19, 2003 10:19 am
Location: Germany

Re: How to compile x64 ZDoom & GZDoom?

Post by Graf Zahl »

Can't fix. That looks like a problem with VC-provided data. It doesn't seem to mtter.
User avatar
Nash
 
 
Posts: 17501
Joined: Mon Oct 27, 2003 12:07 am
Location: Kuala Lumpur, Malaysia
Contact:

Re: How to compile x64 ZDoom & GZDoom?

Post by Nash »

Blue Shadow: I only ever build with OpenAL and I do get some OpenAL delay load warning or something like that. Doesn't seem to cause any harm for now...
Locked

Return to “Editing (Archive)”