forked from mirrors/nixpkgs
Csu: fix build with CoreFoundation
This commit is contained in:
parent
72cf3e856a
commit
a0948ffdb0
|
@ -1,24 +1,22 @@
|
||||||
{ stdenv, appleDerivation }:
|
{ stdenv, appleDerivation }:
|
||||||
|
|
||||||
appleDerivation {
|
appleDerivation {
|
||||||
postUnpack = ''
|
prePatch = ''
|
||||||
substituteInPlace $sourceRoot/Makefile \
|
substituteInPlace Makefile \
|
||||||
--replace "/usr/lib" "/lib" \
|
--replace /usr/lib /lib \
|
||||||
--replace "/usr/local/lib" "/lib" \
|
--replace /usr/local/lib /lib \
|
||||||
--replace "/usr/bin" "" \
|
--replace /usr/bin "" \
|
||||||
--replace "/bin/" "" \
|
--replace /bin/ "" \
|
||||||
--replace "CC = " "CC = cc #" \
|
--replace "CC = " "CC = cc #" \
|
||||||
--replace "SDK_DIR = " "SDK_DIR = . #"
|
--replace "SDK_DIR = " "SDK_DIR = . #" \
|
||||||
|
|
||||||
|
# Mac OS didn't support rpaths back before 10.5, but we don't care about it.
|
||||||
|
substituteInPlace Makefile \
|
||||||
|
--replace -mmacosx-version-min=10.4 -mmacosx-version-min=10.6 \
|
||||||
|
--replace -mmacosx-version-min=10.5 -mmacosx-version-min=10.6
|
||||||
'';
|
'';
|
||||||
|
|
||||||
# Mac OS didn't support rpaths back before 10.5, and this package intentionally builds stubs targeting versions prior to that
|
installFlags = [ "DSTROOT=$(out)" ];
|
||||||
NIX_DONT_SET_RPATH = "1";
|
|
||||||
NIX_NO_SELF_RPATH = "1";
|
|
||||||
|
|
||||||
installPhase = ''
|
|
||||||
export DSTROOT=$out
|
|
||||||
make install
|
|
||||||
'';
|
|
||||||
|
|
||||||
meta = with stdenv.lib; {
|
meta = with stdenv.lib; {
|
||||||
description = "Apple's common startup stubs for darwin";
|
description = "Apple's common startup stubs for darwin";
|
||||||
|
|
Loading…
Reference in a new issue