summaryrefslogtreecommitdiffstats
path: root/Modules/CMakeDefaultMakeRuleVariables.cmake
diff options
context:
space:
mode:
authorAndy Cedilnik <andy.cedilnik@kitware.com>2004-01-21 23:39:54 (GMT)
committerAndy Cedilnik <andy.cedilnik@kitware.com>2004-01-21 23:39:54 (GMT)
commit8bd124e7d0e655f6195200f83e37dbd0a24624e3 (patch)
tree46c53beb21bc1df0448f97c96d7876e42c6dba3a /Modules/CMakeDefaultMakeRuleVariables.cmake
parentf86424414f669650066c7936fd6e9b93fe2f2929 (diff)
downloadCMake-8bd124e7d0e655f6195200f83e37dbd0a24624e3.zip
CMake-8bd124e7d0e655f6195200f83e37dbd0a24624e3.tar.gz
CMake-8bd124e7d0e655f6195200f83e37dbd0a24624e3.tar.bz2
ENH: This will probably break some obscure version of gcc, but until then, everybody doing profiling will be happy
Diffstat (limited to 'Modules/CMakeDefaultMakeRuleVariables.cmake')
-rw-r--r--Modules/CMakeDefaultMakeRuleVariables.cmake4
1 files changed, 4 insertions, 0 deletions
diff --git a/Modules/CMakeDefaultMakeRuleVariables.cmake b/Modules/CMakeDefaultMakeRuleVariables.cmake
index 17893f8..a1a0aad 100644
--- a/Modules/CMakeDefaultMakeRuleVariables.cmake
+++ b/Modules/CMakeDefaultMakeRuleVariables.cmake
@@ -46,6 +46,10 @@ IF(NOT CMAKE_CXX_CREATE_SHARED_LIBRARY)
"<CMAKE_CXX_COMPILER> <CMAKE_SHARED_LIBRARY_CXX_FLAGS> <LINK_FLAGS> <CMAKE_SHARED_LIBRARY_CREATE_CXX_FLAGS> <CMAKE_SHARED_LIBRARY_SONAME_CXX_FLAG><TARGET_SONAME> -o <TARGET> <OBJECTS> <LINK_LIBRARIES>")
ENDIF(NOT CMAKE_CXX_CREATE_SHARED_LIBRARY)
+IF(CMAKE_COMPILER_IS_GNUCXX)
+ SET(CMAKE_CXX_CREATE_SHARED_LIBRARY "${CMAKE_CXX_CREATE_SHARED_LIBRARY} -lgcc")
+ENDIF(CMAKE_COMPILER_IS_GNUCXX)
+
# create a c++ shared module copy the shared library rule by default
IF(NOT CMAKE_CXX_CREATE_SHARED_MODULE)
SET(CMAKE_CXX_CREATE_SHARED_MODULE ${CMAKE_CXX_CREATE_SHARED_LIBRARY})