Commit be320340 by Miguel Arroz

Introduced `LINK_WITH_STATIC_LIBRARIES` per PR comments.

parent 7c9f77b4
...@@ -301,6 +301,8 @@ compiler and linker. These flags are rarely used but can be useful for ...@@ -301,6 +301,8 @@ compiler and linker. These flags are rarely used but can be useful for
- `CMAKE_FIND_ROOT_PATH`: Override the search path for libraries - `CMAKE_FIND_ROOT_PATH`: Override the search path for libraries
- `ZLIB_LIBRARY`, `OPENSSL_SSL_LIBRARY` AND `OPENSSL_CRYPTO_LIBRARY`: - `ZLIB_LIBRARY`, `OPENSSL_SSL_LIBRARY` AND `OPENSSL_CRYPTO_LIBRARY`:
Tell CMake where to find those specific libraries Tell CMake where to find those specific libraries
- `LINK_WITH_STATIC_LIBRARIES`: Link only with static versions of
system libraries
MacOS X MacOS X
------- -------
......
...@@ -92,7 +92,7 @@ else() ...@@ -92,7 +92,7 @@ else()
set(CMAKE_C_ARCHIVE_FINISH "<CMAKE_RANLIB> -D <TARGET>") set(CMAKE_C_ARCHIVE_FINISH "<CMAKE_RANLIB> -D <TARGET>")
endif() endif()
if(NOT APPLE AND NOT BUILD_SHARED_LIBS) if(NOT BUILD_SHARED_LIBS AND LINK_WITH_STATIC_LIBRARIES)
set(CMAKE_FIND_LIBRARY_SUFFIXES ".a") set(CMAKE_FIND_LIBRARY_SUFFIXES ".a")
endif() endif()
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment