Created
January 26, 2013 20:20
-
-
Save ntmoe/4644392 to your computer and use it in GitHub Desktop.
Patch for freesteam-2.1 (from SVN trunk) to run on OS X 10.8.2 so that it skips installing Python bindings, which do not work at the moment on this OS. For SVN revision 677.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
--- SConstruct_old 2012-09-25 19:57:24.000000000 -0500 | |
+++ SConstruct 2013-01-26 14:13:48.000000000 -0600 | |
@@ -166,6 +166,15 @@ | |
, toolpath = ['scons'] | |
, tools = ['mingw']+tools | |
) | |
+if platform.system()=="Darwin": | |
+ os.environ['PATH'] += ':/Applications/ASCEND.app/Contents' | |
+ env = Environment( | |
+ ENV={"PATH":os.environ['PATH'], | |
+ "PKG_CONFIG_PATH":'/usr/X11/lib/pkgconfig'} | |
+ , GSL_STATIC = default_gsl_static | |
+ , toolpath=['scons'] | |
+ , tools=['default']+tools | |
+ ) | |
else: | |
env = Environment( | |
ENV={"PATH":os.environ['PATH']} | |
@@ -276,6 +285,8 @@ | |
Exit(1) | |
without_python_reason = "Python header 'Python.h' not found" | |
+without_python_reason_darwin = "They do not work on \ | |
+OS X at the moment. You may change this behavior in SConstruct." | |
env['HAVE_PYTHON'] = False | |
pyinc = os.path.join(distutils.sysconfig.get_python_inc(),"Python.h") | |
#print "PYINC =",pyinc | |
@@ -295,8 +306,14 @@ | |
if not env.get('HAVE_ASCEND'): | |
print "WARNING: ASCEND was not found... freesteam will be built without ASCEND bindings." | |
-if not env['HAVE_PYTHON']: | |
- print "WARNING: Freesteam will be built without Python bindings.", without_python_reason | |
+without_python_warning = "WARNING: Freesteam will be built without Python bindings." | |
+ | |
+# Change Darwin behavior here re Python bindings | |
+if platform.system()=="Darwin": | |
+ env['HAVE_PYTHON'] = False | |
+ print without_python_warning, without_python_reason_darwin | |
+elif not env['HAVE_PYTHON']: | |
+ print without_python_warning, without_python_reason | |
# Flags to give some more warning output from the GCC compiler |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment