mirror of
https://github.com/ilyakooo0/nixpkgs.git
synced 2024-11-15 21:57:02 +03:00
cd6de2880f
They enable automatically the -fPIC only on x86_64, while I think most non-i686 needs it. svn path=/nixpkgs/branches/stdenv-updates/; revision=25189
28 lines
656 B
Nix
28 lines
656 B
Nix
{ stdenv, fetchurl, readline }:
|
|
|
|
stdenv.mkDerivation rec {
|
|
name = "spidermonkey-1.7";
|
|
|
|
src = fetchurl {
|
|
url = ftp://ftp.mozilla.org/pub/mozilla.org/js/js-1.7.0.tar.gz;
|
|
sha256 = "12v6v2ccw1y6ng3kny3xw0lfs58d1klylqq707k0x04m707kydj4";
|
|
};
|
|
|
|
buildInputs = [ readline ];
|
|
|
|
postUnpack = "sourceRoot=\${sourceRoot}/src";
|
|
|
|
makefileExtra = ./Makefile.extra;
|
|
makefile = "Makefile.ref";
|
|
|
|
patchPhase =
|
|
''
|
|
cat ${makefileExtra} >> ${makefile}
|
|
sed -e 's/ -ltermcap/ -lncurses/' -i ${makefile}
|
|
'';
|
|
|
|
CFLAGS = "-DPIC -fPIC -DJS_C_STRINGS_ARE_UTF8";
|
|
|
|
makeFlags = "-f ${makefile} JS_DIST=\${out} BUILD_OPT=1 JS_READLINE=1";
|
|
}
|