NaN makefiles now support and build with precompiled Python 3.1 by default on Mac
authorMatt Ebb <matt@mke3.net>
Sun, 2 Aug 2009 06:22:53 +0000 (06:22 +0000)
committerMatt Ebb <matt@mke3.net>
Sun, 2 Aug 2009 06:22:53 +0000 (06:22 +0000)
source/darwin/Makefile
source/nan_definitions.mk

index 35ecc6de8f1502f87473f9ebfb405b1c9551442c..35842b43eae48cd651c16009060ca47aec41a484 100644 (file)
@@ -51,8 +51,11 @@ ifeq ($(APPLICATION), blender)
        @cp -R $(NANBLENDERHOME)/release/scripts $(DIR)/bin/$(APPLICATION).app/Contents/MacOS/.blender/
        @echo "---> copying ui scripts"
        @cp -R $(NANBLENDERHOME)/release/ui $(DIR)/bin/$(APPLICATION).app/Contents/MacOS/.blender/
+       @echo "---> copying python modules"
+       @mkdir $(DIR)/bin/$(APPLICATION).app/Contents/MacOS/.blender/python
+       @unzip -q $(LCGDIR)/release/python.zip -d $(DIR)/bin/$(APPLICATION).app/Contents/MacOS/.blender/python/ 
 endif
-       @echo "---> removing SNV directories and Mac hidden files from distribution"
+       @echo "---> removing SVN directories and Mac hidden files from distribution"
        @find $(DIR)/bin/$(APPLICATION).app -name CVS -prune -exec rm -rf {} \;
        @find $(DIR)/bin/$(APPLICATION).app -name .DS_Store -exec rm -f {} \;
        @find $(DIR)/bin/$(APPLICATION).app -name .svn -prune -exec rm -rf {} \;
index 4724c740ffcd5d56c007317db9c5da141487ba71..a70bd057d388b546fa5377ebafb40c54de5b126b 100644 (file)
@@ -136,18 +136,24 @@ endif
     export ID = $(shell whoami)
     export HOST = $(shell hostname -s)
 
-    export PY_FRAMEWORK ?= 1
+    export NAN_PYTHON_VERSION = 3.1
 
-    ifdef PY_FRAMEWORK
-       export NAN_PYTHON ?= /System/Library/Frameworks/Python.framework/Versions/2.3
-       export NAN_PYTHON_VERSION ?= 2.3
-       export NAN_PYTHON_BINARY ?= $(NAN_PYTHON)/bin/python$(NAN_PYTHON_VERSION)
-       export NAN_PYTHON_LIB ?= -framework Python
+    ifeq ($(NAN_PYTHON_VERSION),3.1)
+      export PY_FRAMEWORK ?= 0
+         export NAN_PYTHON ?= $(LCGDIR)/python
+      export NAN_PYTHON_LIB ?= $(NAN_PYTHON)/lib/python$(NAN_PYTHON_VERSION)/libpython$(NAN_PYTHON_VERSION).a
     else
-       export NAN_PYTHON ?= /sw
-       export NAN_PYTHON_VERSION ?= 2.3
-       export NAN_PYTHON_BINARY ?= $(NAN_PYTHON)/bin/python$(NAN_PYTHON_VERSION)
-       export NAN_PYTHON_LIB ?= $(NAN_PYTHON)/lib/python$(NAN_PYTHON_VERSION)/config/libpython$(NAN_PYTHON_VERSION).a
+      export PY_FRAMEWORK ?= 1
+      ifdef PY_FRAMEWORK
+        export NAN_PYTHON ?= /System/Library/Frameworks/Python.framework/Versions/2.5
+        export NAN_PYTHON_VERSION ?= 2.5
+        export NAN_PYTHON_BINARY ?= $(NAN_PYTHON)/bin/python$(NAN_PYTHON_VERSION)
+        export NAN_PYTHON_LIB ?= -framework Python
+      else
+        export NAN_PYTHON ?= /sw
+        export NAN_PYTHON_BINARY ?= $(NAN_PYTHON)/bin/python$(NAN_PYTHON_VERSION)
+        export NAN_PYTHON_LIB ?= $(NAN_PYTHON)/lib/python$(NAN_PYTHON_VERSION)/config/libpython$(NAN_PYTHON_VERSION).a
+      endif
     endif
 
     export NAN_OPENAL ?= $(LCGDIR)/openal
@@ -171,13 +177,9 @@ endif
 
     export NAN_OPENEXR ?= $(LCGDIR)/openexr
     export NAN_OPENEXR_INC ?= -I$(NAN_OPENEXR)/include -I$(NAN_OPENEXR)/include/OpenEXR
-    ifeq ($(CPU),powerpc)
-      export NAN_OPENEXR_LIBS ?= $(NAN_OPENEXR)/lib/libIlmImf.a $(NAN_OPENEXR)/lib/libHalf.a $(NAN_OPENEXR)/lib/libIex.a
-    else
-      export NAN_OPENEXR_LIBS ?= $(NAN_OPENEXR)/lib/libIlmImf.a $(NAN_OPENEXR)/lib/libHalf.a $(NAN_OPENEXR)/lib/libIex.a $(NAN_OPENEXR)/lib/libIlmThread.a
-    endif
-
-    # export NAN_NO_KETSJI=true
+    export NAN_OPENEXR_LIBS ?= $(NAN_OPENEXR)/lib/libIlmImf.a $(NAN_OPENEXR)/lib/libHalf.a $(NAN_OPENEXR)/lib/libIex.a $(NAN_OPENEXR)/lib/libIlmThread.a
+    
+    export NAN_NO_KETSJI=false
 
     ifeq ($(CPU), i386)
       export NAN_NO_OPENAL=true