Merge topic 'fix-hpux-link-search-shared-flags'
dc64d825
HP-UX: Fix linker search type flags for C shared libs on HP-UX
This commit is contained in:
commit
7a7922e020
|
@ -33,18 +33,11 @@ list(APPEND CMAKE_PLATFORM_IMPLICIT_LINK_DIRECTORIES
|
||||||
# Initialize C and CXX link type selection flags. These flags are
|
# Initialize C and CXX link type selection flags. These flags are
|
||||||
# used when building a shared library, shared module, or executable
|
# used when building a shared library, shared module, or executable
|
||||||
# that links to other libraries to select whether to use the static or
|
# that links to other libraries to select whether to use the static or
|
||||||
# shared versions of the libraries. Note that C modules and shared
|
# shared versions of the libraries.
|
||||||
# libs are built using ld directly so we leave off the "-Wl," portion.
|
|
||||||
foreach(type SHARED_LIBRARY SHARED_MODULE)
|
|
||||||
set(CMAKE_${type}_LINK_STATIC_C_FLAGS "-a archive")
|
|
||||||
set(CMAKE_${type}_LINK_DYNAMIC_C_FLAGS "-a default")
|
|
||||||
endforeach()
|
|
||||||
foreach(type EXE)
|
|
||||||
set(CMAKE_${type}_LINK_STATIC_C_FLAGS "-Wl,-a,archive")
|
|
||||||
set(CMAKE_${type}_LINK_DYNAMIC_C_FLAGS "-Wl,-a,default")
|
|
||||||
endforeach()
|
|
||||||
foreach(type SHARED_LIBRARY SHARED_MODULE EXE)
|
foreach(type SHARED_LIBRARY SHARED_MODULE EXE)
|
||||||
set(CMAKE_${type}_LINK_STATIC_CXX_FLAGS "-Wl,-a,archive")
|
foreach(lang C CXX)
|
||||||
set(CMAKE_${type}_LINK_DYNAMIC_CXX_FLAGS "-Wl,-a,default")
|
set(CMAKE_${type}_LINK_STATIC_${lang}_FLAGS "-Wl,-a,archive")
|
||||||
|
set(CMAKE_${type}_LINK_DYNAMIC_${lang}_FLAGS "-Wl,-a,default")
|
||||||
|
endforeach()
|
||||||
endforeach()
|
endforeach()
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue