pypy: parallel build improvements, remove some patching
incorporates http://paste.pound-python.org/show/oFyMaSSzvb07lenWYmAK/ from NixCon sprints
This commit is contained in:
parent
da698fd9da
commit
5c2c881c57
@ -31,16 +31,6 @@ let
|
||||
(stdenv.lib.filter (x : x.outPath != stdenv.cc.libc.outPath or "") buildInputs));
|
||||
|
||||
preConfigure = ''
|
||||
substituteInPlace Makefile \
|
||||
--replace "-Ojit" "-Ojit --batch" \
|
||||
--replace "pypy/goal/targetpypystandalone.py" "pypy/goal/targetpypystandalone.py --withmod-_minimal_curses --withmod-unicodedata --withmod-thread --withmod-bz2 --withmod-_multiprocessing"
|
||||
|
||||
# we are using cpython and not pypy to do translation
|
||||
substituteInPlace rpython/bin/rpython \
|
||||
--replace "/usr/bin/env pypy" "${pythonFull}/bin/python"
|
||||
substituteInPlace pypy/goal/targetpypystandalone.py \
|
||||
--replace "/usr/bin/env pypy" "${pythonFull}/bin/python"
|
||||
|
||||
# hint pypy to find nix ncurses
|
||||
substituteInPlace pypy/module/_minimal_curses/fficurses.py \
|
||||
--replace "/usr/include/ncurses/curses.h" "${ncurses}/include/curses.h" \
|
||||
@ -57,6 +47,10 @@ let
|
||||
sed -i "s@libraries=\['sqlite3'\]\$@libraries=['sqlite3'], include_dirs=['${sqlite}/include'], library_dirs=['${sqlite}/lib']@" lib_pypy/_sqlite3_build.py
|
||||
'';
|
||||
|
||||
buildPhase = ''
|
||||
${pythonFull.interpreter} rpython/bin/rpython --make-jobs="$NIX_BUILD_CORES" -Ojit --batch pypy/goal/targetpypystandalone.py --withmod-_minimal_curses --withmod-unicodedata --withmod-thread --withmod-bz2 --withmod-_multiprocessing
|
||||
'';
|
||||
|
||||
setupHook = ./setup-hook.sh;
|
||||
|
||||
postBuild = ''
|
||||
|
Loading…
Reference in New Issue
Block a user