python: allow stripping tkinter

This commit is contained in:
Florian Klink 2019-08-19 00:11:17 +02:00
parent db087f226d
commit 100eae3b77

View File

@ -24,6 +24,7 @@
, stripConfig ? false
, stripIdlelib ? false
, stripTests ? false
, stripTkinter ? false
, rebuildBytecode ? true
, stripBytecode ? false
}:
@ -232,6 +233,8 @@ in with passthru; stdenv.mkDerivation {
'' + optionalString stripIdlelib ''
# Strip IDLE (and turtledemo, which uses it)
rm -R $out/bin/idle* $out/lib/python*/{idlelib,turtledemo}
'' + optionalString stripTkinter ''
rm -R $out/lib/python*/tkinter
'' + optionalString stripTests ''
# Strip tests
rm -R $out/lib/python*/test $out/lib/python*/**/test{,s}