How-To: Compile on Windows
- Rachael
- Developer
- Posts: 3646
- Joined: Sat May 13, 2006 10:30
How-To: Compile on Windows
If you wish to compile QZDoom on Windows, the instructions are the same as found here:
Compile ZDoom on Windows
There are some exceptions.
Use this git repository: https://github.com/raa-eruanna/qzdoom
You also must download additional LLVM libraries: http://qzdoom.drdteam.org/download/development/
Install them by simply dropping the "llvm" folder into the root of your QZDoom source tree. CMake will find them automatically and use them.
Everything else should be the same.
(If you are a true open source fanatic, you can compile the LLVM libraries yourself - but bear in mind this takes up a ton of room on your hard drive and can take hours to complete - these precompiled libraries are provided as a convenience to get you up and going much more quickly)
Compile ZDoom on Windows
There are some exceptions.
Use this git repository: https://github.com/raa-eruanna/qzdoom
You also must download additional LLVM libraries: http://qzdoom.drdteam.org/download/development/
Install them by simply dropping the "llvm" folder into the root of your QZDoom source tree. CMake will find them automatically and use them.
Everything else should be the same.
(If you are a true open source fanatic, you can compile the LLVM libraries yourself - but bear in mind this takes up a ton of room on your hard drive and can take hours to complete - these precompiled libraries are provided as a convenience to get you up and going much more quickly)
-
- Posts: 12
- Joined: Tue Jan 07, 2014 20:56
Re: How-To: Compile on Windows
Hey, could you update your pre-combiled llvm-builds please? The latest QZDoom source now also uses llvm-bitreader, which doesn't seem to be included in the previous pre-compiled version.
-
- Developer
- Posts: 798
- Joined: Sat Jul 23, 2016 7:53
Re: How-To: Compile on Windows
You can find the missing .lib file in the llvm-3.9.0-everything.7z package. Either unzip that one instead, or copy the 4 versions of the bitreader lib file.
Eruanna: Can you add those to the smaller .7z files, or do you want me to do it? Probably easier if you do it as we don't need to find a way for me to send those files to you then.
Eruanna: Can you add those to the smaller .7z files, or do you want me to do it? Probably easier if you do it as we don't need to find a way for me to send those files to you then.
-
- Posts: 12
- Joined: Tue Jan 07, 2014 20:56
Re: How-To: Compile on Windows
Ah, thank you. I meant Bitwriter, but I found the files in there as well.dpJudas wrote:You can find the missing .lib file in the llvm-3.9.0-everything.7z package. Either unzip that one instead, or copy the 4 versions of the bitreader lib file.
- Rachael
- Developer
- Posts: 3646
- Joined: Sat May 13, 2006 10:30
Re: How-To: Compile on Windows
Can you give me an exact file name list that I can just input in on the shell?dpJudas wrote:Eruanna: Can you add those to the smaller .7z files, or do you want me to do it? Probably easier if you do it as we don't need to find a way for me to send those files to you then.
-
- Developer
- Posts: 798
- Joined: Sat Jul 23, 2016 7:53
Re: How-To: Compile on Windows
Sure. The missing files are:
llvm\32bit-debug\LLVMBitWriter.lib
llvm\32bit-release\LLVMBitWriter.lib
llvm\64bit-debug\LLVMBitWriter.lib
llvm\64bit-release\LLVMBitWriter.lib
llvm\32bit-debug\LLVMBitWriter.lib
llvm\32bit-release\LLVMBitWriter.lib
llvm\64bit-debug\LLVMBitWriter.lib
llvm\64bit-release\LLVMBitWriter.lib
- Rachael
- Developer
- Posts: 3646
- Joined: Sat May 13, 2006 10:30
Re: How-To: Compile on Windows
The files should be updated now. Or at the very least, 7za said "Everything is Ok" 4 times on the shell. >_>
-
- Developer
- Posts: 798
- Joined: Sat Jul 23, 2016 7:53
Re: How-To: Compile on Windows
Perfect. Thanks Eruanna.
- Rachael
- Developer
- Posts: 3646
- Joined: Sat May 13, 2006 10:30
Re: How-To: Compile on Windows
You're welcome.
-
- Posts: 12
- Joined: Tue Jan 07, 2014 20:56
Re: How-To: Compile on Windows
I cannot compile QZDoom anymore. I checked why, apparently my CMake doesn't find the llvm libraries automatically anymore. The funny thing is: Even with 64-Bit selected he looks for the 32-bit ones (which obviously won't work). I am using Windows 10 64-Bit and CMake 3.5.1 (32 bit) and now tested CMake 3.7.1 (64 bit), both the same result. Since 2 weeks or so it cannot find them automatically and selecting them all manually is a bit cumbersome. I think the error persists since you added something called "drawergen" but not sure if that is related in any way.
The error message I am getting in CMake is and then he simply says that all the LLVM stuff is missing (even though it is in the QZDoom source tree).
Any idea to why this is happening?
I am using Visual Studio 14 2015 Win64.
The error message I am getting in CMake is
Code: Select all
CMake Error: The following variables are used in this project, but they are set to NOTFOUND.
Please set them or make sure they are set and tested correctly in the CMake files:
LLVM_analysis_LIBRARY_RELEASE
linked by target "drawergen" in directory C:/qzdoom/src/tools/drawergen
Any idea to why this is happening?
I am using Visual Studio 14 2015 Win64.
-
- Developer
- Posts: 798
- Joined: Sat Jul 23, 2016 7:53
Re: How-To: Compile on Windows
Maybe I broke something when I moved over the LLVM stuff from one CMakeLists.txt file to another. That did indeed happen when I moved the LLVM code generation to its own utility (drawergen). It is probably the search path that is wrong. It looks correct to me, though. I'm assuming I'll have to fully clean out my build directory to see this, because it has been working fine on my computer so far.
-
- Posts: 12
- Joined: Tue Jan 07, 2014 20:56
Re: How-To: Compile on Windows
I just did a test within "tools/drawergen" and edited the CMakeLists.txt.
Just for testing I changed the entries for 32-bit to "64bit". That worked and the CMake low loaded the correct LLVM files. So it seems that my CMake doesn't recognize that it has to look for the 64-bit ones.
Still getting an error message on compiling though:
I also tried already completely refreshing my whole source tree, with deleting the old and re-downloading it again, still cannot get it done.
EDIT:
I changed the (mentioned above)
to
and now CMake has properly detected 64-bit and has now compiled without a problem.
Code: Select all
include_directories( "${LLVM_PRECOMPILED_DIR}/include" )
if( X64 )
include_directories( "${LLVM_PRECOMPILED_DIR}/64bit-include" )
set( llvm_libs_base "${LLVM_PRECOMPILED_DIR}/64bit-" )
else()
include_directories( "${LLVM_PRECOMPILED_DIR}/32bit-include" )
set( llvm_libs_base "${LLVM_PRECOMPILED_DIR}/32bit-" )
endif()
Still getting an error message on compiling though:
Code: Select all
"C:\qzdoom\build64\qzdoom.sln" (Build Ziel) (1) ->
"C:\qzdoom\build64\ALL_BUILD.vcxproj.metaproj" (Standardziel) (2) ->
"C:\qzdoom\build64\wadsrc_bm\brightmaps_pk3.vcxproj.metaproj" (Standardziel) (4) ->
"C:\qzdoom\build64\src\zdoom.vcxproj.metaproj" (Standardziel) (5) ->
"C:\qzdoom\build64\src\drawergen_target.vcxproj.metaproj" (Standardziel) (8) ->
"C:\qzdoom\build64\tools\drawergen\drawergen.vcxproj.metaproj" (Standardziel) (9) ->
"C:\qzdoom\build64\tools\drawergen\drawergen.vcxproj" (Standardziel) (10) ->
(ClCompile Ziel) ->
C:\qzdoom\src\tools\drawergen\..\..\llvm\include\llvm/Support/Compiler.h(18): fatal error C1083: Cannot open include
file: 'llvm/Config/llvm-config.h': No such file or directory [C:\qzdoom\build64\tools\drawergen\drawergen.vcxproj]
EDIT:
I changed the
Code: Select all
if ( x64)
to
Code: Select all
if( CMAKE_SIZEOF_VOID_P EQUAL 8 )
-
- Developer
- Posts: 798
- Joined: Sat Jul 23, 2016 7:53
Re: How-To: Compile on Windows
Ah, seems the CMakeLists.txt file I grabbed the stuff from had this at the very top:
So that explains why it stopped working when I moved it, and why your fix got it working again.
Code: Select all
if( CMAKE_SIZEOF_VOID_P MATCHES "8" )
set( X64 64 )
endif()