Build the static library as position independent
This allows it to be compiled into other shared libraries (like the Python bindings) on x86_64 Linux systems.
This commit is contained in:
@ -31,6 +31,9 @@ LINK_DIRECTORIES(${PolyVoxCore_BINARY_DIR}/debug ${PolyVoxCore_BINARY_DIR}/relea
|
||||
#Build
|
||||
IF(LIBRARY_TYPE STREQUAL "STATIC")
|
||||
ADD_LIBRARY(PolyVoxUtil STATIC ${UTIL_SRC_FILES} ${UTIL_INC_FILES})
|
||||
IF(UNIX)
|
||||
SET_TARGET_PROPERTIES(PolyVoxCore PROPERTIES COMPILE_FLAGS -fPIC)
|
||||
ENDIF()
|
||||
ENDIF()
|
||||
IF(LIBRARY_TYPE STREQUAL "DYNAMIC")
|
||||
ADD_LIBRARY(PolyVoxUtil SHARED ${UTIL_SRC_FILES} ${UTIL_INC_FILES})
|
||||
|
Reference in New Issue
Block a user