Make blenderplayer link to binreloc on linux.
authorChris Want <cwant@ualberta.ca>
Fri, 11 Apr 2008 19:58:54 +0000 (19:58 +0000)
committerChris Want <cwant@ualberta.ca>
Fri, 11 Apr 2008 19:58:54 +0000 (19:58 +0000)
blenderplayer/CMakeLists.txt

index 4a2fc330077ebf61ffe7b0b3bee65c43514e4a6a..df776dc345792072b035dbf7c3a09e517dead521 100644 (file)
@@ -35,6 +35,11 @@ IF(WITH_QUICKTIME)
   ADD_DEFINITIONS(-DWITH_QUICKTIME)
 ENDIF(WITH_QUICKTIME)
 
+IF(LINUX)
+  ADD_DEFINITIONS(-DWITH_BINRELOC)
+  INCLUDE_DIRECTORIES(${BINRELOC_INC})
+endif(LINUX)
+
 ADD_CUSTOM_COMMAND(
   OUTPUT ${CMAKE_CURRENT_BINARY_DIR}/dna.c
   COMMAND ${CMAKE_BINARY_DIR}/bin/${CMAKE_CFG_INTDIR}/makesdna ${CMAKE_CURRENT_BINARY_DIR}/dna.c ${CMAKE_SOURCE_DIR}/source/blender/makesdna/
@@ -53,6 +58,10 @@ FILE(READ ${CMAKE_BINARY_DIR}/cmake_blender_libs.txt BLENDER_LINK_LIBS)
 
 SET(BLENDER_LINK_LIBS ${BLENDER_LINK_LIBS} gp_common gp_ghost blenkernel_blc)
 
+IF(CMAKE_SYSTEM_NAME MATCHES "Linux")
+  SET(BLENDER_LINK_LIBS ${BLENDER_LINK_LIBS} extern_binreloc)
+ENDIF(CMAKE_SYSTEM_NAME MATCHES "Linux")
+
 IF(UNIX)
   # Sort libraries
   SET(BLENDER_SORTED_LIBS
@@ -101,6 +110,7 @@ IF(UNIX)
     bf_readblenfile 
     blenkernel_blc
     bf_quicktime
+    extern_binreloc
   ) 
 
   FOREACH(SORTLIB ${BLENDER_SORTED_LIBS})