[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [24429] trunk/blender: Add FFTW3 support to Makefiles, make OpenJpeg use OS lib for Linux.

gsr b3d gsr.b3d at infernal-iceberg.com
Mon Nov 9 21:08:19 CET 2009


Revision: 24429
          http://projects.blender.org/plugins/scmsvn/viewcvs.php?view=rev&root=bf-blender&revision=24429
Author:   gsrb3d
Date:     2009-11-09 21:08:19 +0100 (Mon, 09 Nov 2009)

Log Message:
-----------
Add FFTW3 support to Makefiles, make OpenJpeg use OS lib for Linux.
And handful of whitespace clean ups.

Modified Paths:
--------------
    trunk/blender/extern/Makefile
    trunk/blender/intern/smoke/intern/Makefile
    trunk/blender/source/Makefile
    trunk/blender/source/blender/imbuf/intern/Makefile
    trunk/blender/source/nan_definitions.mk
    trunk/blender/source/nan_link.mk

Modified: trunk/blender/extern/Makefile
===================================================================
--- trunk/blender/extern/Makefile	2009-11-09 20:03:59 UTC (rev 24428)
+++ trunk/blender/extern/Makefile	2009-11-09 20:08:19 UTC (rev 24429)
@@ -34,7 +34,7 @@
 
 # Cloth requires it
 ifeq ($(NAN_USE_BULLET), true)
-	DIRS += bullet2
+    DIRS += bullet2
 endif
 
 ifeq ($(WITH_BINRELOC), true)
@@ -42,7 +42,9 @@
 endif
 
 ifeq ($(WITH_OPENJPEG), true)
-    DIRS += libopenjpeg
+    ifndef BF_OPENJPEG
+        DIRS += libopenjpeg
+    endif
 endif
 
 ifeq ($(WITH_LZO), true)

Modified: trunk/blender/intern/smoke/intern/Makefile
===================================================================
--- trunk/blender/intern/smoke/intern/Makefile	2009-11-09 20:03:59 UTC (rev 24428)
+++ trunk/blender/intern/smoke/intern/Makefile	2009-11-09 20:08:19 UTC (rev 24429)
@@ -41,6 +41,11 @@
    CPPFLAGS += -DPARALLEL
 endif
 
+ifeq ($(WITH_FFTW3),true)
+    CPPFLAGS += -DFFTW3=1
+    CPPFLAGS += $(BF_FFTW3_INC)
+endif
+
 CPPFLAGS += -I.
 CPPFLAGS += -I../extern
 CPPFLAGS += -I$(NAN_PNG)/include

Modified: trunk/blender/source/Makefile
===================================================================
--- trunk/blender/source/Makefile	2009-11-09 20:03:59 UTC (rev 24428)
+++ trunk/blender/source/Makefile	2009-11-09 20:08:19 UTC (rev 24429)
@@ -188,7 +188,11 @@
 endif
 
 ifeq ($(WITH_OPENJPEG), true)
-    COMLIB += $(OCGDIR)/extern/openjpeg/$(DEBUG_DIR)libopenjpeg.a
+    ifndef BF_OPENJPEG_LIBS
+        COMLIB += $(OCGDIR)/extern/openjpeg/$(DEBUG_DIR)libopenjpeg.a
+    else
+        COMLIB += $(BF_OPENJPEG_LIBS)
+    endif
 endif
 
 COMLIB += $(OCGDIR)/blender/imbuf/cineon/$(DEBUG_DIR)libcineon.a

Modified: trunk/blender/source/blender/imbuf/intern/Makefile
===================================================================
--- trunk/blender/source/blender/imbuf/intern/Makefile	2009-11-09 20:03:59 UTC (rev 24428)
+++ trunk/blender/source/blender/imbuf/intern/Makefile	2009-11-09 20:08:19 UTC (rev 24429)
@@ -39,7 +39,7 @@
 DIRS = cineon
 
 ifeq ($(WITH_OPENEXR), true)
-    DIRS += openexr 
+    DIRS += openexr
     CFLAGS += -DWITH_OPENEXR
 endif
 
@@ -49,7 +49,11 @@
 endif
 
 ifeq ($(WITH_OPENJPEG), true)
-    CFLAGS += -DWITH_OPENJPEG -I../../../../extern/libopenjpeg
+    ifndef BF_OPENJPEG_INC
+        CFLAGS += -DWITH_OPENJPEG -I../../../../extern/libopenjpeg
+    else
+        CFLAGS += -DWITH_OPENJPEG -I$(BF_OPENJPEG_INC)
+    endif
 endif
 
 CFLAGS += $(LEVEL_1_C_WARNINGS)

Modified: trunk/blender/source/nan_definitions.mk
===================================================================
--- trunk/blender/source/nan_definitions.mk	2009-11-09 20:03:59 UTC (rev 24428)
+++ trunk/blender/source/nan_definitions.mk	2009-11-09 20:08:19 UTC (rev 24429)
@@ -81,8 +81,8 @@
     endif
 
     export NAN_MOTO ?= $(LCGDIR)/moto
-	export NAN_ITASC ?= $(LCGDIR)/itasc
-	
+    export NAN_ITASC ?= $(LCGDIR)/itasc
+
     export BF_PROFILE ?= false
     export NAN_USE_BULLET ?= true
     export NAN_BULLET2 ?= $(LCGDIR)/bullet2
@@ -122,6 +122,7 @@
     export WITH_OPENAL ?= false
     export WITH_JACK ?= false
     export WITH_SNDFILE ?= false
+    export WITH_FFTW3 ?= false
 
   ifeq ($(WITH_OPENAL), true)
     export NAN_OPENAL ?= /usr
@@ -195,7 +196,7 @@
     export NAN_OPENEXR ?= $(LCGDIR)/openexr
     export NAN_OPENEXR_INC ?= -I$(NAN_OPENEXR)/include -I$(NAN_OPENEXR)/include/OpenEXR
     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)
@@ -350,6 +351,18 @@
       export NAN_OPENEXR_LIBS ?= $(addprefix ${NAN_OPENEXR}/lib/lib,$(addsuffix .a,$(shell pkg-config --libs-only-l OpenEXR | sed -s "s/-l//g" )))
     endif
 
+    ifeq ($(WITH_FFTW3), true)
+      export BF_FFTW3 ?= $(shell pkg-config --variable=prefix fftw3 )
+      export BF_FFTW3_INC ?= $(shell pkg-config --variable=includedir fftw3 )
+      export BF_FFTW3_LIBS ?= $(shell pkg-config --libs fftw3 )
+    endif
+
+    ifeq ($(WITH_OPENJPEG), true)
+      export BF_OPENJPEG ?= /usr
+      export BF_OPENJPEG_INC ?= /usr/include
+      export BF_OPENJPEG_LIBS ?= -lopenjpeg
+    endif
+
     # Uncomment the following line to use Mozilla inplace of netscape
 
     # Location of MOZILLA/Netscape header files...

Modified: trunk/blender/source/nan_link.mk
===================================================================
--- trunk/blender/source/nan_link.mk	2009-11-09 20:03:59 UTC (rev 24428)
+++ trunk/blender/source/nan_link.mk	2009-11-09 20:08:19 UTC (rev 24429)
@@ -170,4 +170,8 @@
    LLIBS += -lgomp
 endif
 
+ifeq ($(WITH_FFTW3),true)
+    LLIBS += $(BF_FFTW3_LIBS)
+endif
+
 LLIBS += $(NAN_PYTHON_LIB)





More information about the Bf-blender-cvs mailing list