boost-build: fix overriding target when llvm

Changed files
+16 -1
pkgs
development
+2 -1
pkgs/development/tools/boost-build/default.nix
···
sourceRoot="$sourceRoot/tools/build"
'';
-
patches = useBoost.boostBuildPatches or [];
+
patches = useBoost.boostBuildPatches or []
+
++ lib.optional (useBoost ? version && lib.versionAtLeast useBoost.version "1.81") ./fix-clang-target.patch;
# Upstream defaults to gcc on darwin, but we use clang.
postPatch = ''
+14
pkgs/development/tools/boost-build/fix-clang-target.patch
···
+
--- a/src/tools/clang.jam 2024-07-25 10:38:16.278401900 -0700
+
+++ b/src/tools/clang.jam 2024-07-25 10:38:52.659750666 -0700
+
@@ -90,11 +90,6 @@
+
case x86-64 : arch = x86_64 ;
+
case x86-32 : arch = i386 ;
+
}
+
-
+
- toolset.flags $(toolset)
+
- OPTIONS $(condition)/<target-os>$(target-os)/<architecture>$(_architecture_)/<address-model>$(_address-model_)
+
- : "--target=$(arch)-$(vendor-sys)"
+
- : unchecked ;
+
}
+
}
+
}