Hello,
I used to compile OpenTTD myself (to get lastest source code, test my own patches, or try other patches) with Visual Studio 2019.
There were solution and projects files, but they were removed a few ago.
How can I open it now in Visual Studio and compile it ?
How to compile with Visual Studio 2019 ?
Moderator: OpenTTD Developers
Re: How to compile with Visual Studio 2019 ?
Make sure you have the CMake tools support installed, just enable it in the VS installer tool.
Then use File > Open > Open Folder to open your checkout copy.
After that you'll want to find CMakeLists.txt in the folder browser view, right click and open the CMake Settings from there. Maybe add a Release configuration.
Most importantly, you'll probably need to add/change the CMake variable named VCPKG_TARGET_TRIPLET to "x64-windows-static" (or "x86-windows-static" for 32 bit builds) so it can find your installed dependencies.
Then use File > Open > Open Folder to open your checkout copy.
After that you'll want to find CMakeLists.txt in the folder browser view, right click and open the CMake Settings from there. Maybe add a Release configuration.
Most importantly, you'll probably need to add/change the CMake variable named VCPKG_TARGET_TRIPLET to "x64-windows-static" (or "x86-windows-static" for 32 bit builds) so it can find your installed dependencies.
Re: How to compile with Visual Studio 2019 ?
Thank you jfs, it worked
I was trying to build it directly from CMake with no success. Using VS helped me to find the problems
I was trying to build it directly from CMake with no success. Using VS helped me to find the problems
Who is online
Users browsing this forum: No registered users and 15 guests