[Bf-blender-cvs] [ddb1a06] master: SCons: install Python executable when its bundled
Campbell Barton
noreply at git.blender.org
Tue May 19 08:45:32 CEST 2015
Commit: ddb1a068e99c7abf086202d01a3114d8147cb3a9
Author: Campbell Barton
Date: Tue May 19 16:17:49 2015 +1000
Branches: master
https://developer.blender.org/rBddb1a068e99c7abf086202d01a3114d8147cb3a9
SCons: install Python executable when its bundled
===================================================================
M build_files/scons/tools/Blender.py
===================================================================
diff --git a/build_files/scons/tools/Blender.py b/build_files/scons/tools/Blender.py
index ecf3475..16bb19b 100644
--- a/build_files/scons/tools/Blender.py
+++ b/build_files/scons/tools/Blender.py
@@ -843,6 +843,7 @@ def UnixPyBundle(target=None, source=None, env=None):
py_src = env.subst( env['BF_PYTHON_LIBPATH'] + '/python'+env['BF_PYTHON_VERSION'] )
py_target = env.subst( dir + '/python/' + target_lib + '/python'+env['BF_PYTHON_VERSION'] )
+ py_target_bin = env.subst(dir + '/python/bin')
# This is a bit weak, but dont install if its been installed before, makes rebuilds quite slow.
if os.path.exists(py_target):
@@ -862,6 +863,11 @@ def UnixPyBundle(target=None, source=None, env=None):
except:
pass
+ # install the executable
+ run("rm -rf '%s'" % py_target_bin)
+ os.makedirs(py_target_bin)
+ run("cp '%s' '%s'" % (env.subst(env['BF_PYTHON_BINARY']), py_target_bin))
+
run("cp -R '%s' '%s'" % (py_src, os.path.dirname(py_target)))
run("rm -rf '%s/distutils'" % py_target)
run("rm -rf '%s/lib2to3'" % py_target)
More information about the Bf-blender-cvs
mailing list