Python 3.5: separate output for tkinter
This commit is contained in:
parent
0bd4b31f87
commit
0a08fcd858
@ -27,6 +27,7 @@ let
|
|||||||
pythonVersion = majorVersion;
|
pythonVersion = majorVersion;
|
||||||
version = "${majorVersion}.${minorVersion}${minorVersionSuffix}";
|
version = "${majorVersion}.${minorVersion}${minorVersionSuffix}";
|
||||||
libPrefix = "python${majorVersion}";
|
libPrefix = "python${majorVersion}";
|
||||||
|
sitePackages = "lib/${libPrefix}/site-packages";
|
||||||
|
|
||||||
buildInputs = filter (p: p != null) [
|
buildInputs = filter (p: p != null) [
|
||||||
zlib
|
zlib
|
||||||
@ -102,16 +103,22 @@ stdenv.mkDerivation {
|
|||||||
postFixup = ''
|
postFixup = ''
|
||||||
# Get rid of retained dependencies on -dev packages, and remove
|
# Get rid of retained dependencies on -dev packages, and remove
|
||||||
# some $TMPDIR references to improve binary reproducibility.
|
# some $TMPDIR references to improve binary reproducibility.
|
||||||
for i in $out/lib//python${majorVersion}/_sysconfigdata.py $out/lib/python${majorVersion}/config-${majorVersion}m/Makefile; do
|
for i in $out/lib/python${majorVersion}/_sysconfigdata.py $out/lib/python${majorVersion}/config-${majorVersion}m/Makefile; do
|
||||||
sed -i $i -e "s|-I/nix/store/[^ ']*||g" -e "s|-L/nix/store/[^ ']*||g" -e "s|$TMPDIR|/no-such-path|g"
|
sed -i $i -e "s|-I/nix/store/[^ ']*||g" -e "s|-L/nix/store/[^ ']*||g" -e "s|$TMPDIR|/no-such-path|g"
|
||||||
done
|
done
|
||||||
|
|
||||||
# FIXME: should regenerate this.
|
# FIXME: should regenerate this.
|
||||||
rm $out/lib/python${majorVersion}/__pycache__/_sysconfigdata.cpython*
|
rm $out/lib/python${majorVersion}/__pycache__/_sysconfigdata.cpython*
|
||||||
|
|
||||||
|
# tkinter goes in a separate output
|
||||||
|
mkdir -p $tkinter/${sitePackages}
|
||||||
|
mv $out/lib/${libPrefix}/lib-dynload/_tkinter* $tkinter/${sitePackages}/
|
||||||
'';
|
'';
|
||||||
|
|
||||||
|
outputs = ["out" "tkinter"];
|
||||||
|
|
||||||
passthru = rec {
|
passthru = rec {
|
||||||
inherit libPrefix;
|
inherit libPrefix sitePackages;
|
||||||
zlibSupport = zlib != null;
|
zlibSupport = zlib != null;
|
||||||
sqliteSupport = sqlite != null;
|
sqliteSupport = sqlite != null;
|
||||||
dbSupport = false;
|
dbSupport = false;
|
||||||
@ -124,7 +131,6 @@ stdenv.mkDerivation {
|
|||||||
isPy3 = true;
|
isPy3 = true;
|
||||||
isPy35 = true;
|
isPy35 = true;
|
||||||
is_py3k = true; # deprecated
|
is_py3k = true; # deprecated
|
||||||
sitePackages = "lib/${libPrefix}/site-packages";
|
|
||||||
interpreter = "${self}/bin/${executable}";
|
interpreter = "${self}/bin/${executable}";
|
||||||
};
|
};
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user