summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorBrad King <brad.king@kitware.com>2007-04-18 03:41:51 (GMT)
committerBrad King <brad.king@kitware.com>2007-04-18 03:41:51 (GMT)
commit66d1930f5674f08e09f455b3f0777f2de3e0717e (patch)
treee2550e18054ba07d7e1ecfb4bb8837eb091a73f8
parent721ff3692430c8436a5d24fe8a83a20e9012b6bf (diff)
downloadCMake-66d1930f5674f08e09f455b3f0777f2de3e0717e.zip
CMake-66d1930f5674f08e09f455b3f0777f2de3e0717e.tar.gz
CMake-66d1930f5674f08e09f455b3f0777f2de3e0717e.tar.bz2
ENH: Added CMAKE_EXE_EXPORTS_C_FLAG and CMAKE_EXE_EXPORTS_CXX_FLAG to support executables that export symbols.
-rw-r--r--Modules/Platform/FreeBSD.cmake2
-rw-r--r--Modules/Platform/Linux.cmake2
2 files changed, 4 insertions, 0 deletions
diff --git a/Modules/Platform/FreeBSD.cmake b/Modules/Platform/FreeBSD.cmake
index 3970acf..fcfa121 100644
--- a/Modules/Platform/FreeBSD.cmake
+++ b/Modules/Platform/FreeBSD.cmake
@@ -7,6 +7,8 @@ IF(EXISTS /usr/include/dlfcn.h)
SET(CMAKE_SHARED_LIBRARY_RUNTIME_C_FLAG_SEP ":") # : or empty
SET(CMAKE_SHARED_LIBRARY_SONAME_C_FLAG "-Wl,-soname,")
SET(CMAKE_SHARED_LIBRARY_SONAME_CXX_FLAG "-Wl,-soname,")
+ SET(CMAKE_EXE_EXPORTS_C_FLAG "-Wl,--export-dynamic")
+ SET(CMAKE_EXE_EXPORTS_CXX_FLAG "-Wl,--export-dynamic")
ENDIF(EXISTS /usr/include/dlfcn.h)
# Initialize C link type selection flags. These flags are used when
diff --git a/Modules/Platform/Linux.cmake b/Modules/Platform/Linux.cmake
index 1831866..f441f31 100644
--- a/Modules/Platform/Linux.cmake
+++ b/Modules/Platform/Linux.cmake
@@ -8,6 +8,8 @@ SET(CMAKE_SHARED_LIBRARY_RUNTIME_C_FLAG_SEP ":")
SET(CMAKE_SHARED_LIBRARY_SONAME_C_FLAG "-Wl,-soname,")
SET(CMAKE_SHARED_LIBRARY_SONAME_CXX_FLAG "-Wl,-soname,")
SET(CMAKE_SHARED_LIBRARY_SONAME_Fortran_FLAG "-Wl,-soname,")
+SET(CMAKE_EXE_EXPORTS_C_FLAG "-Wl,--export-dynamic")
+SET(CMAKE_EXE_EXPORTS_CXX_FLAG "-Wl,--export-dynamic")
# Initialize C link type selection flags. These flags are used when
# building a shared library, shared module, or executable that links