debug prints are too much on my system it hangs ddd.
[blender.git] / source / nan_link.mk
index 42b17b425b31018cd8f96b1fff47f1cf71acd474..54021ab016f2cd7005fbdfab33cd6225a2cb75b5 100644 (file)
@@ -36,7 +36,7 @@ ifdef NAN_DEBUG
     LDFLAGS += $(NAN_DEBUG)
 endif
 
-DBG_LDFLAGS    += -g
+DBG_LDFLAGS += -g
 
 ifneq (x$(DEBUG_DIR), x)
     LDFLAGS+=$(DBG_LDFLAGS)
@@ -49,20 +49,29 @@ endif
 # default (overriden by windows)
 SOEXT = .so
 
-ifeq ($(OS),beos)
-    LLIBS = -L/boot/develop/lib/x86/ -lGL -lbe -L/boot/home/config/lib/
-endif
-
 ifeq ($(OS),darwin)
     LLIBS    += -lGLU -lGL
     LLIBS    += -lz -lstdc++
     ifdef USE_OSX10.4STUBS
        LLIBS    +=-lSystemStubs
-    endif 
-    LLIBS    += -framework Carbon -framework AGL -framework OpenGL
-    LLIBS    += -framework QuickTime -framework CoreAudio
-    LLIBS    += -framework AudioUnit -framework AudioToolbox
+    endif
+    ifeq ($(WITH_COCOA), true)
+        LLIBS += -framework Cocoa
+    endif
+    LLIBS += -framework Carbon -framework AGL -framework OpenGL
+    ifeq ($(WITH_QUICKTIME), true)
+        ifeq ($(USE_QTKIT), true)
+            LLIBS += -framework QTKit
+        else
+            LLIBS  += -framework QuickTime
+        endif
+    endif
+    LLIBS += -framework CoreAudio
+    LLIBS += -framework AudioUnit -framework AudioToolbox
     LDFLAGS += -L/System/Library/Frameworks/OpenGL.framework/Libraries
+    # useful for crosscompiling
+    LDFLAGS += -arch $(MACOSX_ARCHITECTURE) #-isysroot $(MACOSX_SDK) -mmacosx-version-min=$(MACOSX_MIN_VERS)
+    
     DBG_LDFLAGS += -L/System/Library/Frameworks/OpenGL.framework/Libraries
 endif
 
@@ -101,7 +110,7 @@ ifeq ($(OS),linux)
     COMMENT = "MESA 3.1"
     LLIBS = -L$(NAN_MESA)/lib -L/usr/X11R6/lib -lXmu -lXext -lX11 -lXi
     LLIBS += -lutil -lc -lm -ldl -lpthread
-#    LLIBS += -L$(NAN_ODE)/lib -lode
+    LLIBS += -L$(NAN_PYTHON)/lib -Wl,-rpath -Wl,$(NAN_PYTHON)/lib -lpython$(NAN_PYTHON_VERSION)
     LOPTS = -export-dynamic
     DADD = -lGL -lGLU
     SADD = $(NAN_MESA)/lib/libGL.a $(NAN_MESA)/lib/libGLU.a
@@ -124,34 +133,34 @@ ifeq ($(OS),solaris)
         LLIBS += -L$(NAN_MESA)/lib
     endif
     
-    LLIBS += -lGLU -lGL -lXmu -lXext -lXi -lX11 -lc -lm -ldl -lsocket -lnsl 
+    LLIBS += $(NAN_ZLIB)/lib/libz.a -lGLU -lGL -lXmu -lXext -lXi -lX11 -lc -lm -ldl -lsocket -lnsl 
     DYNLDFLAGS = -shared $(LDFLAGS)
 endif
 
 ifeq ($(OS),windows)
     EXT = .exe
-       SOEXT = .dll
-       ifeq ($(FREE_WINDOWS),true)
-               MINGWLIB = /usr/lib/w32api
-               LDFLAGS += -mwindows -mno-cygwin -mconsole
-               DADD += -L/usr/lib/w32api -lnetapi32 -lopengl32 -lglu32 -lshfolder
-               DADD += -L/usr/lib/w32api -lwinmm -lwsock32
+    SOEXT = .dll
+    ifeq ($(FREE_WINDOWS),true)
+        MINGWLIB = /usr/lib/w32api
+        LDFLAGS += -mwindows -mno-cygwin -mconsole
+        DADD += -L/usr/lib/w32api -lnetapi32 -lopengl32 -lglu32 -lshfolder
+        DADD += -L/usr/lib/w32api -lwinmm -lwsock32
     else
-           DADD = kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib
-               DADD += advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib
-           DADD += vfw32.lib winmm.lib opengl32.lib glu32.lib largeint.lib dxguid.lib
-               DADD += libcmt.lib
-               LOPTS = /link
-               LOPTS += /NODEFAULTLIB:"libc" 
-               LOPTS += /NODEFAULTLIB:"libcd" 
-               LOPTS += /NODEFAULTLIB:"libcp" 
-               LOPTS += /NODEFAULTLIB:"libcpd" 
-               LOPTS += /NODEFAULTLIB:"python20" 
-               LOPTS += /NODEFAULTLIB:"msvcrt" 
-               LOPTS += /SUBSYSTEM:CONSOLE
-               LDFLAGS += /MT
-               DYNLDFLAGS = /LD
-       endif
+        DADD = kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib
+        DADD += advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib
+        DADD += vfw32.lib winmm.lib opengl32.lib glu32.lib largeint.lib dxguid.lib
+        DADD += libcmt.lib
+        LOPTS = /link
+        LOPTS += /NODEFAULTLIB:"libc" 
+        LOPTS += /NODEFAULTLIB:"libcd" 
+        LOPTS += /NODEFAULTLIB:"libcp" 
+        LOPTS += /NODEFAULTLIB:"libcpd" 
+        LOPTS += /NODEFAULTLIB:"python20" 
+        LOPTS += /NODEFAULTLIB:"msvcrt" 
+        LOPTS += /SUBSYSTEM:CONSOLE
+        LDFLAGS += /MT
+        DYNLDFLAGS = /LD
+    endif
 endif
 
 ifneq ($(OS), irix)
@@ -174,4 +183,12 @@ ifeq ($(WITH_BF_OPENMP),true)
    LLIBS += -lgomp
 endif
 
+ifeq ($(WITH_FFTW3),true)
+    LLIBS += $(BF_FFTW3_LIBS)
+endif
+
+ifeq ($(WITH_OPENCOLLADA),true)
+    LLIBS += $(BF_OPENCOLLADA_LIBS)
+endif
+
 LLIBS += $(NAN_PYTHON_LIB)