buildtools: Don't configure Python more than once
authorPetr Viktorin <pviktori@redhat.com>
Mon, 8 Jun 2015 17:02:03 +0000 (19:02 +0200)
committerAndreas Schneider <asn@cryptomilk.org>
Tue, 21 Jul 2015 17:04:14 +0000 (19:04 +0200)
Signed-off-by: Petr Viktorin <pviktori@redhat.com>
Reviewed-by: Andrew Bartlett <abartlet@samba.org>
Reviewed-by: Stefan Metzmacher <metze@samba.org>
buildtools/wafsamba/samba_python.py

index 7546bbd6d2e7c28aad06c42e8e9068e473e52941..aa3ceb02b575231cbe7d89e54e4f1a29d4ba938c 100644 (file)
@@ -9,6 +9,10 @@ from Configure import conf
 @conf
 def SAMBA_CHECK_PYTHON(conf, mandatory=True, version=(2,4,2)):
     # enable tool to build python extensions
+    if conf.env.HAVE_PYTHON_H:
+        conf.check_python_version(version)
+        return
+
     interpreters = []
 
     if conf.env['EXTRA_PYTHON']: