2017-08-28 18:56:08 +00:00
|
|
|
# See cc-wrapper for comments.
|
|
|
|
var_templates_list=(
|
|
|
|
NIX+IGNORE_LD_THROUGH_GCC
|
|
|
|
NIX+LDFLAGS
|
|
|
|
NIX+LDFLAGS_BEFORE
|
|
|
|
NIX+LDFLAGS_AFTER
|
|
|
|
NIX+LDFLAGS_HARDEN
|
2018-04-11 18:00:13 +00:00
|
|
|
NIX+HARDENING_ENABLE
|
2017-08-28 18:56:08 +00:00
|
|
|
)
|
|
|
|
var_templates_bool=(
|
|
|
|
NIX+SET_BUILD_ID
|
|
|
|
NIX+DONT_SET_RPATH
|
|
|
|
)
|
|
|
|
|
2018-05-07 17:15:34 +00:00
|
|
|
accumulateRoles
|
2017-08-28 18:56:08 +00:00
|
|
|
|
|
|
|
for var in "${var_templates_list[@]}"; do
|
2018-04-11 18:00:13 +00:00
|
|
|
mangleVarList "$var" ${role_infixes[@]+"${role_infixes[@]}"}
|
2017-08-28 18:56:08 +00:00
|
|
|
done
|
|
|
|
for var in "${var_templates_bool[@]}"; do
|
2018-04-11 18:00:13 +00:00
|
|
|
mangleVarBool "$var" ${role_infixes[@]+"${role_infixes[@]}"}
|
2017-08-28 18:56:08 +00:00
|
|
|
done
|
|
|
|
|
|
|
|
if [ -e @out@/nix-support/libc-ldflags ]; then
|
|
|
|
NIX_@infixSalt@_LDFLAGS+=" $(< @out@/nix-support/libc-ldflags)"
|
|
|
|
fi
|
|
|
|
|
|
|
|
if [ -e @out@/nix-support/libc-ldflags-before ]; then
|
|
|
|
NIX_@infixSalt@_LDFLAGS_BEFORE="$(< @out@/nix-support/libc-ldflags-before) $NIX_@infixSalt@_LDFLAGS_BEFORE"
|
|
|
|
fi
|
|
|
|
|
|
|
|
export NIX_BINTOOLS_WRAPPER_@infixSalt@_FLAGS_SET=1
|