mirror of
https://port.numenaute.org/aleajactaest/khanat-opennel-code.git
synced 2024-11-20 06:06:13 +00:00
Change: Apply shared libraries properties also for modules
This commit is contained in:
parent
c6e75f3c82
commit
6da1c7dbd8
2 changed files with 14 additions and 14 deletions
|
@ -44,9 +44,9 @@ MACRO(_PCH_GET_COMPILE_FLAGS _out_compile_flags)
|
|||
IF(CMAKE_COMPILER_IS_GNUCXX)
|
||||
|
||||
GET_TARGET_PROPERTY(_targetType ${_PCH_current_target} TYPE)
|
||||
IF(${_targetType} STREQUAL SHARED_LIBRARY AND NOT WIN32)
|
||||
IF((${_targetType} STREQUAL SHARED_LIBRARY) OR (${_targetType} STREQUAL MODULE_LIBRARY))
|
||||
LIST(APPEND ${_out_compile_flags} "-fPIC")
|
||||
ENDIF(${_targetType} STREQUAL SHARED_LIBRARY AND NOT WIN32)
|
||||
ENDIF((${_targetType} STREQUAL SHARED_LIBRARY) OR (${_targetType} STREQUAL MODULE_LIBRARY))
|
||||
|
||||
ELSE(CMAKE_COMPILER_IS_GNUCXX)
|
||||
## TODO ... ? or does it work out of the box
|
||||
|
|
|
@ -38,10 +38,10 @@ ENDMACRO(NL_TARGET_DRIVER)
|
|||
###
|
||||
MACRO(NL_DEFAULT_PROPS name label)
|
||||
GET_TARGET_PROPERTY(type ${name} TYPE)
|
||||
IF(${type} STREQUAL SHARED_LIBRARY)
|
||||
# Set versions only if target is a shared library
|
||||
IF((${type} STREQUAL SHARED_LIBRARY) OR (${type} STREQUAL MODULE_LIBRARY))
|
||||
# Set versions only if target is a shared library or a module
|
||||
SET(versions VERSION ${NL_VERSION} SOVERSION ${NL_VERSION_MAJOR})
|
||||
ENDIF(${type} STREQUAL SHARED_LIBRARY)
|
||||
ENDIF((${type} STREQUAL SHARED_LIBRARY) OR (${type} STREQUAL MODULE_LIBRARY))
|
||||
SET_TARGET_PROPERTIES(${name} PROPERTIES
|
||||
${versions}
|
||||
PROJECT_LABEL ${label})
|
||||
|
|
Loading…
Reference in a new issue