python: add pythonRemoveTestsDirHook
This will automatically remove a top-level "tests" directory from being installed.
This commit is contained in:
committed by
Frederik Rietdijk
parent
fe898d5f76
commit
3973a3c79c
@@ -0,0 +1,15 @@
|
||||
# Clean up top-level tests directory in site-package installation.
|
||||
echo "Sourcing python-remove-tests-dir-hook"
|
||||
|
||||
pythonRemoveTestsDir() {
|
||||
echo "Executing pythonRemoveTestsDir"
|
||||
|
||||
rm -rf $out/@pythonSitePackages@/tests
|
||||
|
||||
echo "Finished executing pythonRemoveTestsDir"
|
||||
}
|
||||
|
||||
if [ -z "${dontUsePythonRemoveTestsDir-}" ]; then
|
||||
postFixupHooks+=(pythonRemoveTestsDir)
|
||||
fi
|
||||
|
||||
Reference in New Issue
Block a user