We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
I wonder if we would like to recommend using ninja to build the project.
ninja
To enable ninja, simply add -G Ninja to the CMake command.
-G Ninja
CMake
cmake ../ -G Ninja -DCMAKE_INSTALL_PREFIX=/usr -DCMAKE_BUILD_TYPE=Debug -DENABLE_CLANG_TIDY=On cmake --build . # or just `ninja`
I observed a ~2x boost on my system ( Intel(R) Core(TM) i9-9900K CPU @ 3.60GHz)
Intel(R) Core(TM) i9-9900K CPU @ 3.60GHz
# ninja uses $(nproc) +2 jobs by default $ nproc 16 $ time ninja [40/40] Linking CXX shared module src/mcbopomofo.so real 0m22.833s user 2m46.923s sys 0m4.956s
$ time make -j 18 ... [100%] Built target mcbopomofo real 0m48.043s user 2m9.943s sys 0m4.526s
The text was updated successfully, but these errors were encountered:
One can create CMakeUserPresets.json file with cmake presets
CMakeUserPresets.json
CMakeUserPresets.json:
{ "version": 8, "cmakeMinimumRequired": { "major": 3, "minor": 28, "patch": 0 }, "configurePresets": [ { "name": "release", "displayName": "Release", "description": "Release build with Ninja", "generator": "Ninja", "binaryDir": "${sourceDir}/build/", "cacheVariables": { "CMAKE_INSTALL_PREFIX": "/usr", "CMAKE_BUILD_TYPE": "Release", "ENABLE_CLANG_TIDY": "On" } }, { "name": "debug", "displayName": "Debug", "description": "Debug build with Ninja", "generator": "Ninja", "binaryDir": "${sourceDir}/build/", "cacheVariables": { "CMAKE_INSTALL_PREFIX": "/usr", "CMAKE_BUILD_TYPE": "Debug", "ENABLE_CLANG_TIDY": "On" } } ] }
This will simplify the commands for developers:
$ cmake ../ --preset release $ ninja $ cmake ../ --preset debug ninja && ninja test
Sorry, something went wrong.
No branches or pull requests
I wonder if we would like to recommend using
ninja
to build the project.To enable
ninja
, simply add-G Ninja
to theCMake
command.I observed a ~2x boost on my system (
Intel(R) Core(TM) i9-9900K CPU @ 3.60GHz
)$ time make -j 18 ... [100%] Built target mcbopomofo real 0m48.043s user 2m9.943s sys 0m4.526s
The text was updated successfully, but these errors were encountered: