Add cmakeBuildType and dontAddCmakeBuildType variables to be able to make Debug builds.#17828
Closed
nbp wants to merge 1 commit intoNixOS:stagingfrom
Closed
Add cmakeBuildType and dontAddCmakeBuildType variables to be able to make Debug builds.#17828nbp wants to merge 1 commit intoNixOS:stagingfrom
nbp wants to merge 1 commit intoNixOS:stagingfrom
Conversation
…make Debug builds.
| cmakeFlags="-DCMAKE_SKIP_BUILD_RPATH=ON $cmakeFlags" | ||
|
|
||
| if [ -n "$cmakeBuildType" ]; then | ||
| cmakeFlags="-DCMAKE_BUILD_TYPE=$cmakeBuildType $cmakeFlags" |
Member
There was a problem hiding this comment.
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.
7 tasks
Member
|
You might be interested in #17886 |
Contributor
|
@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 |
Member
|
Can I suggest doing something like: |
Member
|
(triage) Isn't this fixed now?
|
Member
|
I think so. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
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
cmakeBuildTypeattribute, 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-chrootinnix.confon non-NixOS)
nix-shell -p nox --run "nox-review wip"rr../result/bin/)