nixpkgs mirror (for testing) github.com/NixOS/nixpkgs
nix
0
fork

Configure Feed

Select the types of activity you want to include in your feed.

python313Packages.scikit-build-core: fix `cmakeFlags`

This was broken when using multiple `cmakeFlags` without
`__structuredAttrs`, because `args+=($cmakeFlags)` wouldn’t split
it on whitespace. Let’s do something much cleaner instead.

Emily 7c98af33 26c2977c

+4 -13
+4 -13
pkgs/development/python-modules/scikit-build-core/append-cmakeFlags.sh
··· 1 1 scikitBuildFlagsHook() { 2 - OLD_IFS="$IFS" 3 - IFS=';' 2 + concatTo flagsArray cmakeFlags cmakeFlagsArray 4 3 5 - local args=() 6 - if [[ -n "$SKBUILD_CMAKE_ARGS" ]]; then 7 - read -ra existing_args <<< "$SKBUILD_CMAKE_ARGS" 8 - args+=("${existing_args[@]}") 9 - fi 10 - args+=($cmakeFlags) 11 - args+=("${cmakeFlagsArray[@]}") 12 - export SKBUILD_CMAKE_ARGS="${args[*]}" 13 - 14 - IFS="$OLD_IFS" 15 - unset OLD_IFS 4 + for arg in "${flagsArray[@]}"; do 5 + appendToVar pypaBuildFlags "-Ccmake.args=$arg" 6 + done 16 7 } 17 8 18 9 preConfigureHooks+=(scikitBuildFlagsHook)