forked from mirrors/nixpkgs
gcc-cross-wrapper: Allow to pass US X min version.
This allows to pass a new attribute osxMinVersion to crossSystem, which specifies the minimum Mac OS X version you want to be compatible to. Signed-off-by: aszlig <aszlig@redmoonstudios.org>
This commit is contained in:
parent
8c053312b5
commit
2d17335f68
|
@ -26,6 +26,10 @@ if test -z "$nativeLibc"; then
|
|||
fi
|
||||
fi
|
||||
|
||||
if [ -n "$osxMinVersion" ]; then
|
||||
cflagsCompile="$cflagsCompile -mmacosx-version-min=$osxMinVersion"
|
||||
fi
|
||||
|
||||
echo "$cflagsCompile -B$libc/lib/ -idirafter $libc/include -idirafter $gcc/lib/gcc/*/*/include-fixed" > $out/nix-support/libc-cflags
|
||||
|
||||
echo "-L$libc/lib -rpath $libc/lib -rpath-link $libc/lib" > $out/nix-support/libc-ldflags
|
||||
|
|
|
@ -46,6 +46,7 @@ stdenv.mkDerivation {
|
|||
addFlags = ./add-flags;
|
||||
inherit nativeTools nativeLibc nativePrefix gcc libc binutils;
|
||||
crossConfig = if cross != null then cross.config else null;
|
||||
osxMinVersion = cross.osxMinVersion or null;
|
||||
gccLibs = if gcc != null then gccLibs else null;
|
||||
name = chosenName;
|
||||
langC = if nativeTools then true else gcc.langC;
|
||||
|
|
Loading…
Reference in a new issue