summary refs log tree commit diff
path: root/pkgs/build-support/bintools-wrapper/setup-hook.sh
diff options
context:
space:
mode:
authorJohn Ericson <John.Ericson@Obsidian.Systems>2017-08-28 11:33:08 -0400
committerJohn Ericson <John.Ericson@Obsidian.Systems>2017-12-30 22:04:23 -0500
commit469fd8983276d851c19827cd9e78a89dd53a5914 (patch)
tree6fac2af13cf6544fb93a1f9bbdbe454d2cd860ad /pkgs/build-support/bintools-wrapper/setup-hook.sh
parentf083248290fb1268fba1beb8e1c353c4cb39528d (diff)
downloadnixpkgs-469fd8983276d851c19827cd9e78a89dd53a5914.tar
nixpkgs-469fd8983276d851c19827cd9e78a89dd53a5914.tar.gz
nixpkgs-469fd8983276d851c19827cd9e78a89dd53a5914.tar.bz2
nixpkgs-469fd8983276d851c19827cd9e78a89dd53a5914.tar.lz
nixpkgs-469fd8983276d851c19827cd9e78a89dd53a5914.tar.xz
nixpkgs-469fd8983276d851c19827cd9e78a89dd53a5914.tar.zst
nixpkgs-469fd8983276d851c19827cd9e78a89dd53a5914.zip
stdenv-setup: Ease the transition with native builds
 - All deps go on the PATH

 - CC and Bintools wrappers with their host != depender's host still get their
   setup hooks run.

 - Environment hooks get applied to all packages

This isn't so elegent, but eases the transition on a very significant
PR.
Diffstat (limited to 'pkgs/build-support/bintools-wrapper/setup-hook.sh')
-rw-r--r--pkgs/build-support/bintools-wrapper/setup-hook.sh7
1 files changed, 5 insertions, 2 deletions
diff --git a/pkgs/build-support/bintools-wrapper/setup-hook.sh b/pkgs/build-support/bintools-wrapper/setup-hook.sh
index c508963ac33..48a00b0b9b0 100644
--- a/pkgs/build-support/bintools-wrapper/setup-hook.sh
+++ b/pkgs/build-support/bintools-wrapper/setup-hook.sh
@@ -4,8 +4,11 @@
 
 set -u
 
-# Skip setup hook if we're not a build-time dep
-(( "$hostOffset" < 0 )) || return 0
+# Skip setup hook if we're neither a build-time dep, nor, temporarily, doing a
+# native compile.
+#
+# TODO(@Ericson2314): No native exception
+[[ -z ${crossConfig-} ]] || (( "$hostOffset" < 0 )) || return 0
 
 bintoolsWrapper_addLDVars () {
     case $depHostOffset in