renpy-build icon indicating copy to clipboard operation
renpy-build copied to clipboard

Improve CMake build system integration

Open brainos233 opened this issue 8 months ago • 0 comments

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 into cmake_configure and cmake_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

brainos233 avatar May 30 '24 15:05 brainos233