-
-
Notifications
You must be signed in to change notification settings - Fork 14.1k
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
Add cmakeBuildType and dontAddCmakeBuildType variables to be able to make Debug builds. #17828
Conversation
…make Debug builds.
cmakeFlags="-DCMAKE_SKIP_BUILD_RPATH=ON $cmakeFlags" | ||
|
||
if [ -n "$cmakeBuildType" ]; then | ||
cmakeFlags="-DCMAKE_BUILD_TYPE=$cmakeBuildType $cmakeFlags" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
If one appends -DCMAKE_BUILD_TYPE=Debug
to cmakeFlags
, does that not override the setting made here? In which case, we need only the dontAddBuildType
option.
You might be interested in #17886 |
@rasendubi Thanks for linking me in! I've added a commit to address this in my PR #17886 - I think this is a prime example of why sets are a more ergonomic approach to |
Can I suggest doing something like:
|
(triage) Isn't this fixed now?
|
I think so. |
Motivation for this change
Current cmake setup-tools.sh only allow us to make release builds, and one cannot just remove the command as it is baked in right before calling cmake.
This pull request add the ability to set
cmakeBuildType
attribute, and default toRelease
.This change is likely a mass-rebuild, so I am making this pull request against the staging branch.
Things done
(nix.useChroot on NixOS,
or option
build-use-chroot
innix.conf
on non-NixOS)
nix-shell -p nox --run "nox-review wip"
rr
../result/bin/
)