[PATCH 2/3] Do not add some unneeded linker flags when on BSD.

Raphael Kubo da Costa rakuco at FreeBSD.org
Mon Jul 23 13:38:04 UTC 2012


It is not clear why -lc needed to be passed. It seems to have come
with commit 4d1789f40ed1cc6e34e55b9edc119ee6389e1368, but things seem
to work just fine without that on FreeBSD.

Also remove the _GNU_SOURCE definition, as that is only needed by
glibc (see feature_test_macros(7) on Linux).
---
 cmake/modules/FindKDE4Internal.cmake | 6 ------
 1 file changed, 6 deletions(-)

diff --git a/cmake/modules/FindKDE4Internal.cmake b/cmake/modules/FindKDE4Internal.cmake
index 0a1a3e8..6822b02 100644
--- a/cmake/modules/FindKDE4Internal.cmake
+++ b/cmake/modules/FindKDE4Internal.cmake
@@ -1135,12 +1135,6 @@ if (UNIX)
    endif (NOT _OFFT_IS_64BIT)
 endif (UNIX)
 
-if (CMAKE_SYSTEM_NAME MATCHES BSD)
-   set ( _KDE4_PLATFORM_DEFINITIONS -D_GNU_SOURCE )
-   set ( CMAKE_SHARED_LINKER_FLAGS "${CMAKE_SHARED_LINKER_FLAGS} -lc")
-   set ( CMAKE_MODULE_LINKER_FLAGS "${CMAKE_MODULE_LINKER_FLAGS} -lc")
-endif (CMAKE_SYSTEM_NAME MATCHES BSD)
-
 
 ############################################################
 # compiler specific settings
-- 
1.7.11.2



More information about the Kde-buildsystem mailing list