Page 1 of 1

[DEPRECATED] [WINDOWS] Compiling GZDoom with CMake GUI, Visual Studio and vcpkg

Posted: Tue Aug 22, 2023 10:26 pm
by Nash
Deprecated as of April 2024. You don't need vcpkg anymore.
Spoiler:

Re: Compiling GZDoom with CMake GUI, Visual Studio and vcpkg

Posted: Wed Aug 23, 2023 1:06 am
by Rachael
Thank you for doing this Nash. You turned my technical babblespeak into something everyone could use. And you also were the one to figure out that the only piece of the puzzle that was missing was the toolchain file thing - it was my mistake to not think of that, first.

Re: Compiling GZDoom with CMake GUI, Visual Studio and vcpkg

Posted: Wed Aug 23, 2023 7:12 am
by Iluin
> Step 2: Inside the newly-cloned vcpkg folder, run bootstrap-vcpkg.bat (Windows) or bootstrap-vcpkg.sh (other OSes). It should finish fairly quickly. That's fine.

That step is not required in manifest mode. vcpkg should be able to bootstrap itself.

Re: Compiling GZDoom with CMake GUI, Visual Studio and vcpkg

Posted: Wed Aug 23, 2023 11:02 am
by MartinHowe
This is good for the GUI crowd, but what about terminal only building? I have a set of scripts that "just work" for building GZDoom and would hate to see them require user input during the process :( Presumably it will still be possible on Linux to build entirely from terminal commands?

Re: Compiling GZDoom with CMake GUI, Visual Studio and vcpkg

Posted: Wed Aug 23, 2023 2:05 pm
by JPL
Might be worth appending "in Windows" to the title of this thread to preempt people coming into this thread to ask about support for other build methods / OSes. Likewise a separate "compiling the new way in Linux" might be able to collect what would otherwise be lots of smaller more isolated support requests.

Re: Compiling GZDoom with CMake GUI, Visual Studio and vcpkg

Posted: Wed Aug 23, 2023 2:18 pm
by Jay0
JPL wrote: Wed Aug 23, 2023 2:05 pm "compiling the new way in Linux"
The "old" way isn't really going away, what this update is doing is adding vcpkg support and removing the bundled windows dependencies -- ex. on Linux you'll be free to continue using the system package manager, use vcpkg, or get the dependencies you need any other method (basically, the build method for non-windows platfoms hasn't changed at all)

Re: Compiling GZDoom with CMake GUI, Visual Studio and vcpkg

Posted: Wed Aug 23, 2023 6:14 pm
by Nash
JPL wrote: Wed Aug 23, 2023 2:05 pm Might be worth appending "in Windows" to the title of this thread to preempt people coming into this thread to ask about support for other build methods / OSes. Likewise a separate "compiling the new way in Linux" might be able to collect what would otherwise be lots of smaller more isolated support requests.
Done.
MartinHowe wrote: Wed Aug 23, 2023 11:02 am This is good for the GUI crowd, but what about terminal only building? I have a set of scripts that "just work" for building GZDoom and would hate to see them require user input during the process :( Presumably it will still be possible on Linux to build entirely from terminal commands?
Yeah sorry this thread is only for the GUI crowd, for command lines, only new thing you need to add to your CMake call is the -DCMAKE_TOOLCHAIN_FILE=<path to vcpkg.cmake> parameter. I won't be covering it though, someone else may feel free to take care of that. :D

Re: [WINDOWS] Compiling GZDoom with CMake GUI, Visual Studio and vcpkg

Posted: Wed Aug 23, 2023 9:21 pm
by Rachael
It's basically the same for other OS's, and Cmake-GUI is available on all platforms, so saying "for windows" is really a bit misleading.

The command line is indeed just simply using -DCMAKE_TOOLCHAIN_FILE to point to your vcpkg installation with the script inside, it requires a very specific file but it should be pretty clear which one if you follow the instructions here.

Re: [WINDOWS] Compiling GZDoom with CMake GUI, Visual Studio and vcpkg

Posted: Thu Aug 24, 2023 12:29 am
by MartinHowe
Thanks everyone, I'll look into this next time I need to build it. Hopefully the Wiki for it will be updated eventually.

Re: [WINDOWS] Compiling GZDoom with CMake GUI, Visual Studio and vcpkg

Posted: Sat Oct 28, 2023 1:12 pm
by Major Cooke
And the windows instructions need updating as well but also there has to be a way not to rely upon vcpkg. Apparently all someone has to do is not load the toolchain file, build libwebp with 'vcpkg install' and link manually to it, but right now I'm struggling with some of this.

If it could be explained more in detail, that'd be definitely appreciated.

To be clear, I've only ever set up GZDoom before and I've never had to deal with this prior.

Re: [WINDOWS] Compiling GZDoom with CMake GUI, Visual Studio and vcpkg

Posted: Tue Oct 31, 2023 8:05 am
by Graf Zahl
There isn't really more to it. All you need is manually provide the path to libwebp.
The path should be {vcpkg_dir}/installed/x64-windows-static/share/WebP

For just building an EXE, and not working with the project, auto-setup-windows.cmd should be enough. It downloads everything you need, except CMake and then builds everything in one go.

Re: [DEPRECATED] [WINDOWS] Compiling GZDoom with CMake GUI, Visual Studio and vcpkg

Posted: Sun Apr 14, 2024 9:42 am
by Nash
Deprecated as of April 2024. You don't need vcpkg anymore.