-
Notifications
You must be signed in to change notification settings - Fork 13.5k
build(cmake): simplify instructions (cmake -B build && cmake --build build ...)
#6964
New issue
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
Conversation
cmake . -B build && cmake --build build is all you need)cmake . -B build && cmake --build build is all you need)
|
The source directory defaults to the current directory when using |
Co-authored-by: Jared Van Bortel <[email protected]>
cmake . -B build && cmake --build build is all you need)cmake -B build && cmake --build build is all you need)
@cebtenzzre Neat! Updated. |
Co-authored-by: Neo Zhang Jianyu <[email protected]>
I am not sure that this is entirely correct. |
|
I just ran a quick test, and without |
…rs + document how to build Debug
@slaren Oops I misspoke, it's the default for single-generator configs (as set here), and the default is generator dependent for the others.
Thanks a lot for catching this! I just checked if setting I've reverted the |
cmake -B build && cmake --build build is all you need)cmake -B build && cmake --build build ...)
… build ...`) (ggml-org#6964) * readme: cmake . -B build && cmake --build build * build: fix typo Co-authored-by: Jared Van Bortel <[email protected]> * build: drop implicit . from cmake config command * build: remove another superfluous . * build: update MinGW cmake commands * Update README-sycl.md Co-authored-by: Neo Zhang Jianyu <[email protected]> * build: reinstate --config Release as not the default w/ some generators + document how to build Debug * build: revert more --config Release * build: nit / remove -H from cmake example * build: reword debug instructions around single/multi config split --------- Co-authored-by: Jared Van Bortel <[email protected]> Co-authored-by: Neo Zhang Jianyu <[email protected]>
Updated instructions & CI to skip the
mkdir -p build && cd buildsteps using config-time flag-Band build-time flag--buildBecomes:
cmake -B build cmake --build build --config Release # --config flag is ignored for Makefile generation (default) but crucial for Release builds w/ Xcode / MSVC, as pointed out by reviewersDocumented how to do
DebugbuildsRemoved--config Releasefrom most cmake build commands (except for Visual Studio) asReleaseis the default and the--configflag is often useless anyway)Note: To build in Debug w/ CMake one generally needs to set
-DCMAKE_BUILD_TYPE=Debugin the "config" command (--config Debugon the build command works only for Ninja Multi-Config, XCode or Visual Studio generators)