[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [20087] trunk/blender/config/linux2-config .py: use the python version scons is running with by default on linux, will make it easier for people with new distros that only come with python 2 .6

Campbell Barton ideasman42 at gmail.com
Wed May 6 23:41:14 CEST 2009


Revision: 20087
          http://projects.blender.org/plugins/scmsvn/viewcvs.php?view=rev&root=bf-blender&revision=20087
Author:   campbellbarton
Date:     2009-05-06 23:41:14 +0200 (Wed, 06 May 2009)

Log Message:
-----------
use the python version scons is running with by default on linux, will make it easier for people with new distros that only come with python 2.6

Modified Paths:
--------------
    trunk/blender/config/linux2-config.py

Modified: trunk/blender/config/linux2-config.py
===================================================================
--- trunk/blender/config/linux2-config.py	2009-05-06 18:51:58 UTC (rev 20086)
+++ trunk/blender/config/linux2-config.py	2009-05-06 21:41:14 UTC (rev 20087)
@@ -4,8 +4,16 @@
 WITH_BF_VERSE = False
 BF_VERSE_INCLUDE = "#extern/verse/dist"
 
+def py_version_string():
+	'''
+	returns py version - "2.5", "2.6" etc
+	'''
+	import platform
+	ver = platform.python_version_tuple()
+	return '%d.%d' % (ver[0], ver[1])
+
 BF_PYTHON = '/usr'
-BF_PYTHON_VERSION = '2.5'
+BF_PYTHON_VERSION = get_py_version_string()
 WITH_BF_STATICPYTHON = False
 BF_PYTHON_INC = '${BF_PYTHON}/include/python${BF_PYTHON_VERSION}'
 BF_PYTHON_BINARY = '${BF_PYTHON}/bin/python${BF_PYTHON_VERSION}'





More information about the Bf-blender-cvs mailing list