lua5.2/cross: Fix build for Darwin.
The ld from cctools doesn't like the -soname argument, so let's strip it off for now until we have a binutils <-> cctools bridge. Signed-off-by: aszlig <aszlig@redmoonstudios.org>
This commit is contained in:
parent
3940b21988
commit
745c477930
1 changed files with 24 additions and 0 deletions
|
@ -49,6 +49,30 @@ stdenv.mkDerivation rec {
|
|||
EOF
|
||||
'';
|
||||
|
||||
crossAttrs = let
|
||||
isDarwin = stdenv.cross.libc == "libSystem";
|
||||
in {
|
||||
configurePhase = ''
|
||||
makeFlagsArray=(
|
||||
INSTALL_TOP=$out
|
||||
INSTALL_MAN=$out/share/man/man1
|
||||
CC=${stdenv.cross.config}-gcc
|
||||
STRIP=:
|
||||
RANLIB=${stdenv.cross.config}-ranlib
|
||||
V=${majorVersion}
|
||||
R=${version}
|
||||
${stdenv.lib.optionalString isDarwin ''
|
||||
AR="${stdenv.cross.config}-ar rcu"
|
||||
macosx
|
||||
''}
|
||||
)
|
||||
'';
|
||||
} // stdenv.lib.optionalAttrs isDarwin {
|
||||
postPatch = ''
|
||||
sed -i -e 's/-Wl,-soname[^ ]* *//' src/Makefile
|
||||
'';
|
||||
};
|
||||
|
||||
meta = {
|
||||
homepage = "http://www.lua.org";
|
||||
description = "Powerful, fast, lightweight, embeddable scripting language";
|
||||
|
|
Loading…
Reference in a new issue