renpy-build
renpy-build copied to clipboard
Improve CMake build system integration
This PR enhances the cmake build system integration, specifically, it does the following things:
- Set
-fuse-ld=lld
directly, this is llvm's recommend method to use lld in https://lld.llvm.org/#using-lld - Remove
ccache
from the build utils, since ccache is only effective for compiler - Split variable
cmake
intocmake_configure
andcmake_args
for clarity - Use
ninja
as default generator for cmake to speed up building process - Add
CMAKE_BUILD_PARALLEL_LEVEL
to control the maximum number of build processes - Call cmake to compile and install, which allows set generator without changing compile and install commands, and making
CMAKE_BUILD_PARALLEL_LEVEL
take effect automatically - Prefer to use cmake's own way of setting C/C++ standard and linker type if available, this prevents cmake projects from setting the default value for
CMAKE_<LANG>_STANDARD
and overwriting renpy's C/C++ std version