- remove CPPFLAG XP_UNIX from CMake, Scons and Irix make, checked our own code and...
authorCampbell Barton <ideasman42@gmail.com>
Thu, 19 Nov 2009 11:49:42 +0000 (11:49 +0000)
committerCampbell Barton <ideasman42@gmail.com>
Thu, 19 Nov 2009 11:49:42 +0000 (11:49 +0000)
- CMake on unix default OpenMP to enabled.
- Scons on linux default OpenMP to enabled.
- copying python is slow, for scons only copy if the directory has not been created.

CMakeLists.txt
config/irix6-config.py
config/linux2-config.py
config/linuxcross-config.py
config/sunos5-config.py
config/win32-mingw-config.py
source/blender/python/intern/bpy_rna.c
source/nan_compile.mk
tools/Blender.py

index 0dd331469a08880d22549d7d2a23875641776a7b..c7e08d7b1ba8840617fa745572971b9486106a08 100644 (file)
@@ -70,7 +70,6 @@ OPTION(WITH_PYTHON        "Enable Embedded Python API" ON)
 OPTION(WITH_SDL           "Enable SDL for sound and joystick support" ON)
 OPTION(WITH_OPENJPEG      "Enable OpenJpeg Support (http://www.openjpeg.org/)" OFF)
 OPTION(WITH_OPENAL        "Enable OpenAL Support (http://www.openal.org)" ON)
-OPTION(WITH_OPENMP        "Enable OpenMP (has to be supported by the compiler)" OFF)
 OPTION(WITH_WEBPLUGIN     "Enable Web Plugin (Unix only)" OFF)
 OPTION(WITH_FFTW3         "Enable FFTW3 support" OFF)
 OPTION(WITH_JACK          "Enable Jack Support (http://www.jackaudio.org)" OFF)
@@ -82,10 +81,17 @@ OPTION(WITH_BUILDINFO     "Include extra build details" ON)
 OPTION(WITH_INSTALL       "Install accompanying scripts and language files needed to run blender" ON)
 OPTION(WITH_OPENCOLLADA                "Enable OpenCollada Support (http://www.opencollada.org/)"      OFF)
 
+# Unix defaults to OpenMP On
+IF (UNIX)
+       OPTION(WITH_OPENMP        "Enable OpenMP (has to be supported by the compiler)" ON)
+ELSE(UNIX)
+       OPTION(WITH_OPENMP        "Enable OpenMP (has to be supported by the compiler)" OFF)
+ENDIF(UNIX)
+
 IF (APPLE)
-OPTION(WITH_COCOA        "Use Cocoa framework instead of deprecated Carbon" ON)
-OPTION(USE_QTKIT         "Use QtKit instead of Carbon quicktime (needed for having partial quicktime for 64bit)" OFF)
-OPTION(WITH_LIBS10.5     "Use 10.5 libs (needed for 64bit builds)" OFF)
+       OPTION(WITH_COCOA         "Use Cocoa framework instead of deprecated Carbon" ON)
+       OPTION(USE_QTKIT          "Use QtKit instead of Carbon quicktime (needed for having partial quicktime for 64bit)" OFF)
+       OPTION(WITH_LIBS10.5  "Use 10.5 libs (needed for 64bit builds)" OFF)
 ENDIF (APPLE)
 
 IF(NOT WITH_GAMEENGINE AND WITH_PLAYER)
@@ -237,7 +243,7 @@ IF(UNIX AND NOT APPLE)
        ENDIF(WITH_OPENMP)
 
 
-       SET(PLATFORM_CFLAGS "-pipe -fPIC -funsigned-char -fno-strict-aliasing -DXP_UNIX -Wno-char-subscripts")
+       SET(PLATFORM_CFLAGS "-pipe -fPIC -funsigned-char -fno-strict-aliasing -Wno-char-subscripts")
 
        SET(PLATFORM_LINKFLAGS "-pthread")
 
index 085d1dd1e62c05046b990c4d912f2bc6ddc2fe82..ab2ef02c977c65f0be1ef1cfe576b5e6dc653294 100644 (file)
@@ -161,7 +161,7 @@ CXX = 'CC'
 
 CCFLAGS = ['-pipe','-fPIC', '-n32']
 
-CPPFLAGS = ['-DXP_UNIX']
+CPPFLAGS = []
 CXXFLAGS = ['-pipe','-fPIC', '-n32']
 REL_CFLAGS = ['-O2']
 REL_CCFLAGS = ['-O2']
index dffc861fca8632069cfe9bb254b57c9ec506cf93..3eccb9139329a783e96ef4b0c2b967e6555f985a 100644 (file)
@@ -165,6 +165,8 @@ BF_EXPAT = '/usr'
 BF_EXPAT_LIB = 'expat'
 BF_EXPAT_LIBPATH = '/usr/lib'
 
+WITH_BF_OPENMP = True
+
 ##
 CC = 'gcc'
 CXX = 'g++'
@@ -173,7 +175,7 @@ CXX = 'g++'
 
 CCFLAGS = ['-pipe','-fPIC','-funsigned-char','-fno-strict-aliasing']
 
-CPPFLAGS = ['-DXP_UNIX']
+CPPFLAGS = []
 CXXFLAGS = ['-pipe','-fPIC','-funsigned-char','-fno-strict-aliasing']
 REL_CFLAGS = ['-O2']
 REL_CCFLAGS = ['-O2']
index a5c83dc35039f9fe1c45d97a4923903a57f5d4a8..3cfa11587004915ae8e22c0464dc8b32a8cc9a6b 100644 (file)
@@ -119,7 +119,7 @@ CXX = 'i586-mingw32msvc-g++'
 
 CCFLAGS = [ '-pipe', '-funsigned-char', '-fno-strict-aliasing' ]
 
-CPPFLAGS = [ '-DXP_UNIX', '-DWIN32', '-DFREE_WINDOWS' ]
+CPPFLAGS = ['-DWIN32', '-DFREE_WINDOWS']
 CXXFLAGS = ['-pipe', '-mwindows', '-funsigned-char', '-fno-strict-aliasing' ]
 REL_CFLAGS = [ '-O2' ]
 REL_CCFLAGS = [ '-O2' ]
index 8e4c53b5bc402941edb1194c34ceb2179dfaaa70..88dce927db4f9240b1a40f8ca4b54774eb1af341 100644 (file)
@@ -136,7 +136,7 @@ CXX = 'g++'
 
 CCFLAGS = ['-pipe','-fPIC','-funsigned-char','-fno-strict-aliasing']
 
-CPPFLAGS = ['-DXP_UNIX', '-DSUN_OGL_NO_VERTEX_MACROS']
+CPPFLAGS = ['-DSUN_OGL_NO_VERTEX_MACROS']
 CXXFLAGS = ['-pipe','-fPIC','-funsigned-char','-fno-strict-aliasing']
 REL_CFLAGS = ['-O2']
 REL_CCFLAGS = ['-O2']
index b519aa95ca7d50aa3b8e5b8d9369baa2c8ba41da..709261ec1cac7ae3b51c3ee79034d0779a7d0780 100644 (file)
@@ -136,7 +136,7 @@ CXX = 'g++'
 
 CCFLAGS = [ '-pipe', '-funsigned-char', '-fno-strict-aliasing' ]
 
-CPPFLAGS = [ '-DXP_UNIX', '-DWIN32', '-DFREE_WINDOWS' ]
+CPPFLAGS = ['-DWIN32', '-DFREE_WINDOWS']
 CXXFLAGS = ['-pipe', '-mwindows', '-funsigned-char', '-fno-strict-aliasing' ]
 REL_CFLAGS = [ '-O2' ]
 REL_CCFLAGS = [ '-O2' ]
index d12de5f2e466f020134d9abf5de217887d491dad..1ab50cdc864887549d419eb59ad27e0ac8257185 100644 (file)
@@ -1,3 +1,4 @@
+
 /**
  * $Id$
  *
index 6a1263e286cf8ffb2744c65491bb4ee351a565a2..258d06c07b90da468074c21c8de3fd86dc961372 100644 (file)
@@ -116,8 +116,7 @@ ifeq ($(OS),irix)
         CFLAGS += -fPIC -funsigned-char -fno-strict-aliasing -mabi=n32 -mips4
         CCFLAGS += -fPIC -fpermissive -funsigned-char -fno-strict-aliasing -mabi=n32 -mips4
         REL_CFLAGS += -O2
-        REL_CCFLAGS += -O2
-        CPPFLAGS += -DXP_UNIX
+        REL_CCFLAGS += -O2 
         DBG_CFLAGS += -g3 -gdwarf-2 -ggdb
         DBG_CCFLAGS += -g3 -gdwarf-2 -ggdb
     else
index 94ad485e17606cd408a0ad997b55b489d0fd9469..4dad70bbef5ea4d12dd9f2bfed933bcd11529d71 100644 (file)
@@ -545,6 +545,14 @@ 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/lib/python'+env['BF_PYTHON_VERSION'] )
        
+       # This is a bit weak, but dont install if its been installed before, makes rebuilds quite slow.
+       if os.path.exists(py_target):
+               print 'Using existing python from:'
+               print '\t"%s"' %                        py_target
+               print '\t(skipping copy)\n'
+               return
+               
+       
        # Copied from source/creator/CMakeLists.txt, keep in sync.
        print 'Install python from:'
        print '\t"%s" into...' %        py_src