[SCM] Samba Shared Repository - branch master updated

Andrew Tridgell tridge at samba.org
Fri Jan 14 00:20:01 MST 2011


The branch, master has been updated
       via  46a3588 waf: use PYTHONARCHDIR for installing python shared libs
       via  0346b5b waf: new version of waf
      from  ad8965c s4-dsdb: only enforce the extended dn rules over ldap

http://gitweb.samba.org/?p=samba.git;a=shortlog;h=master


- Log -----------------------------------------------------------------
commit 46a3588d3fca3a5dd702ce6e9b4a108b884a9cf8
Author: Andrew Tridgell <tridge at samba.org>
Date:   Fri Jan 14 17:20:01 2011 +1100

    waf: use PYTHONARCHDIR for installing python shared libs
    
    Pair-Programmed-With: Andrew Bartlett <abartlet at samba.org>
    
    Autobuild-User: Andrew Tridgell <tridge at samba.org>
    Autobuild-Date: Fri Jan 14 08:19:40 CET 2011 on sn-devel-104

commit 0346b5b93c5215ecb8a56c664d99fc700ca23bfb
Author: Andrew Tridgell <tridge at samba.org>
Date:   Fri Jan 14 17:19:22 2011 +1100

    waf: new version of waf
    
    this one adds PYTHONARCHDIR to fix bug 7905
    
    thanks to Thomas Nagy for the fix!

-----------------------------------------------------------------------

Summary of changes:
 buildtools/bin/waf-svn              |  Bin 109173 -> 109281 bytes
 buildtools/wafsamba/samba_python.py |    2 +-
 buildtools/wafsamba/wafsamba.py     |    4 ++--
 source4/dynconfig/dynconfig.c       |    1 +
 source4/dynconfig/dynconfig.h       |    1 +
 source4/dynconfig/wscript           |    3 ++-
 source4/scripting/python/modules.c  |    4 ++++
 source4/wscript                     |    2 ++
 8 files changed, 13 insertions(+), 4 deletions(-)


Changeset truncated at 500 lines:

diff --git a/buildtools/bin/waf-svn b/buildtools/bin/waf-svn
index 7dc8507..b2e4885 100755
Binary files a/buildtools/bin/waf-svn and b/buildtools/bin/waf-svn differ
diff --git a/buildtools/wafsamba/samba_python.py b/buildtools/wafsamba/samba_python.py
index a663b19..e9afa93 100644
--- a/buildtools/wafsamba/samba_python.py
+++ b/buildtools/wafsamba/samba_python.py
@@ -63,7 +63,7 @@ def SAMBA_PYTHON(bld, name,
                       link_name=link_name,
                       pyembed=True,
                       target_type='PYTHON',
-                      install_path='${PYTHONDIR}',
+                      install_path='${PYTHONARCHDIR}',
                       enabled=enabled)
 
 Build.BuildContext.SAMBA_PYTHON = SAMBA_PYTHON
diff --git a/buildtools/wafsamba/wafsamba.py b/buildtools/wafsamba/wafsamba.py
index 571cd48..050777f 100644
--- a/buildtools/wafsamba/wafsamba.py
+++ b/buildtools/wafsamba/wafsamba.py
@@ -634,8 +634,8 @@ def install_file(bld, destdir, file, chmod=MODE_644, flat=False,
     if python_fixup:
         # fixup the python path it will use to find Samba modules
         inst_file = file + '.inst'
-        if bld.env["PYTHONDIR"] not in sys.path:
-            regex = "s|\(sys.path.insert.*\)bin/python\(.*\)$|\\1${PYTHONDIR}\\2|g"
+        if bld.env["PYTHONARCHDIR"] not in sys.path:
+            regex = "s|\(sys.path.insert.*\)bin/python\(.*\)$|\\1${PYTHONARCHDIR}\\2|g"
         else:
             # Eliminate updating sys.path if the target python dir is already
             # in python path.
diff --git a/source4/dynconfig/dynconfig.c b/source4/dynconfig/dynconfig.c
index 0c23452..9fbfed0 100644
--- a/source4/dynconfig/dynconfig.c
+++ b/source4/dynconfig/dynconfig.c
@@ -92,4 +92,5 @@ DEFINE_DYN_CONFIG_PARAM(WINBINDD_SOCKET_DIR)
 DEFINE_DYN_CONFIG_PARAM(WINBINDD_PRIVILEGED_SOCKET_DIR)
 DEFINE_DYN_CONFIG_PARAM(NTP_SIGND_SOCKET_DIR)
 DEFINE_DYN_CONFIG_PARAM(PYTHONDIR)
+DEFINE_DYN_CONFIG_PARAM(PYTHONARCHDIR)
 DEFINE_DYN_CONFIG_PARAM(SCRIPTSBINDIR)
diff --git a/source4/dynconfig/dynconfig.h b/source4/dynconfig/dynconfig.h
index c759081..579f45b 100644
--- a/source4/dynconfig/dynconfig.h
+++ b/source4/dynconfig/dynconfig.h
@@ -56,4 +56,5 @@ DEFINE_DYN_CONFIG_PROTO(WINBINDD_SOCKET_DIR)
 DEFINE_DYN_CONFIG_PROTO(WINBINDD_PRIVILEGED_SOCKET_DIR)
 DEFINE_DYN_CONFIG_PROTO(NTP_SIGND_SOCKET_DIR)
 DEFINE_DYN_CONFIG_PROTO(PYTHONDIR)
+DEFINE_DYN_CONFIG_PROTO(PYTHONARCHDIR)
 DEFINE_DYN_CONFIG_PROTO(SCRIPTSBINDIR)
diff --git a/source4/dynconfig/wscript b/source4/dynconfig/wscript
index 375d4a1..0058047 100644
--- a/source4/dynconfig/wscript
+++ b/source4/dynconfig/wscript
@@ -32,6 +32,7 @@ dyn_cflags = {
     'NTP_SIGND_SOCKET_DIR'           : '${NTP_SIGND_SOCKET_DIR}',
     'NCALRPCDIR'                     : '${LOCALSTATEDIR}/ncalrpc',
     'PYTHONDIR'                      : '${PYTHONDIR}',
+    'PYTHONARCHDIR'                  : '${PYTHONARCHDIR}',
     'MODULESDIR'                     : '${PREFIX}/modules',
     'INCLUDEDIR'                     : '${PREFIX}/include',
     'PKGCONFIGDIR'                   : '${LIBDIR}/pkgconfig',
@@ -62,7 +63,7 @@ dyn_cflags_fhs = {
     'WINBINDD_PRIVILEGED_SOCKET_DIR' : '${LOCALSTATEDIR}/run/samba/winbindd_privileged',
     'NTP_SIGND_SOCKET_DIR'           : '${LOCALSTATEDIR}/run/samba/ntp_signd',
     'NCALRPCDIR'                     : '${LOCALSTATEDIR}/ncalrpc',
-    'PYTHONDIR'                      : '${PYTHONDIR}',
+    'PYTHONARCHDIR'                  : '${PYTHONARCHDIR}',
     'MODULESDIR'                     : '${LIBDIR}/samba',
     'LIBEXECDIR'                     : '${MODULESDIR}',
     'INCLUDEDIR'                     : '${INCLUDEDIR}/samba-4.0',
diff --git a/source4/scripting/python/modules.c b/source4/scripting/python/modules.c
index 1825375..960239e 100644
--- a/source4/scripting/python/modules.c
+++ b/source4/scripting/python/modules.c
@@ -50,6 +50,10 @@ bool py_update_path(const char *bindir)
 		return false;
 	}
 
+	if (!PySys_PathPrepend(py_path, dyn_PYTHONARCHDIR)) {
+		return false;
+	}
+
 	if (!PySys_PathPrepend(py_path, dyn_PYTHONDIR)) {
 		return false;
 	}
diff --git a/source4/wscript b/source4/wscript
index 8c1bc71..3fdeb3c 100644
--- a/source4/wscript
+++ b/source4/wscript
@@ -122,6 +122,8 @@ def configure(conf):
     # we don't want PYTHONDIR in config.h, as otherwise changing
     # --prefix causes a complete rebuild
     del(conf.env.defines['PYTHONDIR'])
+    del(conf.env.defines['PYTHONARCHDIR'])
+
     conf.SAMBA_CONFIG_H('include/config.h')
 
 


-- 
Samba Shared Repository


More information about the samba-cvs mailing list