[PATCH] [FreeBSD 5] Install Python subunit test in a proper location

Timur I. Bakeyev timur at com.bat.ru
Sun Jun 7 12:21:26 GMT 2009


This patch is against Samba4 subtree. The way, how some Samba4 Python
bindings got installed(just copy subtree with compiled modules into
the Python site library directory) plays a dirty trick with the 'subunit'
modules, as it's subtree lays outside the common prefix, which got stripped
during installation. so, subunit tests end up somewhere outside of the
standart Python lib path.

This patch additionally strips out prefix of the subunit module, making
it end up in a proper location.

With regards,
Timur Bakeyev.
-------------- next part --------------
--- ./source4/scripting/python/config.mk.orig	2009-04-30 07:53:01.000000000 +0000
+++ ./source4/scripting/python/config.mk	2009-06-01 11:49:40.000000000 +0000
@@ -25,7 +25,7 @@
 
 _PY_FILES = $(shell find $(pyscriptsrcdir)/samba ../lib/subunit/python -name "*.py")
 
-$(eval $(foreach pyfile, $(_PY_FILES),$(call python_py_module_template,$(patsubst $(pyscriptsrcdir)/%,%,$(pyfile)),$(pyfile))))
+$(eval $(foreach pyfile, $(_PY_FILES),$(call python_py_module_template,$(patsubst $(pyscriptsrcdir)/%,%,$(subst ../lib/subunit/python,,$(pyfile))),$(pyfile))))
 
 EPYDOC_OPTIONS = --no-private --url http://www.samba.org/ --no-sourcecode
 


More information about the samba-technical mailing list