diff options
author | Masadow <jimmy.delas@gmail.com> | 2018-10-09 15:57:44 +0300 |
---|---|---|
committer | Masadow <jimmy.delas@gmail.com> | 2018-10-09 15:57:44 +0300 |
commit | 4be5bc8059b2e7b916a80f826ed7fb9b50a36991 (patch) | |
tree | ab8d7c18536ff83c15a467e5271072aa0a6ef926 /CMakeLists.txt | |
parent | c483646db00a6a9ac3a8e93f7c490aecb589979d (diff) |
Add support for position independant code compilation
Diffstat (limited to 'CMakeLists.txt')
-rw-r--r-- | CMakeLists.txt | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/CMakeLists.txt b/CMakeLists.txt index c40cc15..1ad9700 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -39,6 +39,9 @@ set(GENERIC_LIB_SOVERSION "6") option(BUILD_SHARED_LIBS "build as shared library" ON)
option(BUILD_TESTS "build xmltest (deprecated: Use BUILD_TESTING)" ON)
+# To allow using tinyxml in another shared library
+set(CMAKE_POSITION_INDEPENDENT_CODE ON)
+
set(CMAKE_CXX_VISIBILITY_PRESET hidden)
set(CMAKE_VISIBILITY_INLINES_HIDDEN 1)
|