diff options
author | Alexander Neundorf <neundorf@kde.org> | 2006-02-18 09:20:03 +0000 |
---|---|---|
committer | Alexander Neundorf <neundorf@kde.org> | 2006-02-18 09:20:03 +0000 |
commit | 877e4bdedab9045e55cd182a9442c348ac8769ee (patch) | |
tree | 94debf34eaf56da67ace8b2a11a9d2e8a4712e64 /modules/FindKDE3.cmake | |
parent | 590106d0c8ee50cec2b570e1c10e49275f081f16 (diff) | |
download | extra-cmake-modules-877e4bdedab9045e55cd182a9442c348ac8769ee.tar.gz extra-cmake-modules-877e4bdedab9045e55cd182a9442c348ac8769ee.tar.bz2 |
-apply patch from Andreas Beckermann
-rename KDE3_CREATE_LIBTOOL_FILE to KDE3_INSTALL_LIBTOOL_FILE
-require cmake 2.3.3: http://www.cmake.org/files/v2.3/cmake-2.3.3-20060210.tar.gz
-use GET_FILENAME_COMPONENT(...ABSOLUTE )
-the Macro*.cmake files are now required too
Alex
If you use these files, please test that they work for you.
CCMAIL: b_mann@gmx.de
CCMAIL: christian.loose@hamburg.de
svn path=/trunk/KDE/kdelibs/; revision=510821
Diffstat (limited to 'modules/FindKDE3.cmake')
-rw-r--r-- | modules/FindKDE3.cmake | 19 |
1 files changed, 14 insertions, 5 deletions
diff --git a/modules/FindKDE3.cmake b/modules/FindKDE3.cmake index 828ca056..d6945cdb 100644 --- a/modules/FindKDE3.cmake +++ b/modules/FindKDE3.cmake @@ -18,14 +18,14 @@ # KDE3_ADD_KCFG_FILES # KDE3_AUTOMOC # KDE3_PLACEHOLDER -# KDE3_CREATE_LIBTOOL_FILE +# KDE3_INSTALL_LIBTOOL_FILE # KDE3_CREATE_FINAL_FILE # KDE3_ADD_KPART # KDE3_ADD_KLM # KDE3_ADD_EXECUTABLE -CMAKE_MINIMUM_REQUIRED(VERSION 2.2) +CMAKE_MINIMUM_REQUIRED(VERSION "2.3.3") set(QT_MT_REQUIRED TRUE) #set(QT_MIN_VERSION "3.0.0") @@ -40,13 +40,21 @@ FIND_PACKAGE(X11 REQUIRED) set(QT_AND_KDECORE_LIBS ${QT_LIBRARIES} kdecore) #add some KDE specific stuff -set(KDE3_DEFINITIONS -DQT_CLEAN_NAMESPACE -Wnon-virtual-dtor -Wno-long-long -Wundef -ansi -Wcast-align -Wconversion -Wchar-subscripts -Wall -W -Wpointer-arith -Wwrite-strings -O2 -Wformat-security -Wmissing-format-attribute -fno-exceptions -fno-check-new -fno-common) +set(KDE3_DEFINITIONS -DQT_CLEAN_NAMESPACE -D_GNU_SOURCE) #only on linux, but NOT e.g. on FreeBSD: if(CMAKE_SYSTEM_NAME MATCHES "Linux") - set(KDE3_DEFINITIONS ${KDE3_DEFINITIONS} -D_XOPEN_SOURCE=500 -D_BSD_SOURCE -D_GNU_SOURCE) + set (KDE3_DEFINITIONS ${KDE3_DEFINITIONS} -D_XOPEN_SOURCE=500 -D_BSD_SOURCE) + set ( CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -Wno-long-long -ansi -Wundef -Wcast-align -Wconversion -Wchar-subscripts -Wall -W -Wpointer-arith -Wwrite-strings -O2 -Wformat-security -Wmissing-format-attribute -fno-common") + set ( CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wnon-virtual-dtor -Wno-long-long -ansi -Wundef -Wcast-align -Wconversion -Wchar-subscripts -Wall -W -Wpointer-arith -Wwrite-strings -O2 -Wformat-security -fno-exceptions -fno-check-new -fno-common") endif(CMAKE_SYSTEM_NAME MATCHES "Linux") +# works on FreeBSD, NOT tested on NetBSD and OpenBSD +if (CMAKE_SYSTEM_NAME MATCHES BSD) + set ( CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -Wno-long-long -ansi -Wundef -Wcast-align -Wconversion -Wchar-subscripts -Wall -W -Wpointer-arith -Wwrite-strings -O2 -Wformat-security -Wmissing-format-attribute -fno-common") + set ( CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wnon-virtual-dtor -Wno-long-long -Wundef -Wcast-align -Wconversion -Wchar-subscripts -Wall -W -Wpointer-arith -Wwrite-strings -O2 -Wformat-security -Wmissing-format-attribute -fno-exceptions -fno-check-new -fno-common") +endif (CMAKE_SYSTEM_NAME MATCHES BSD) + #set(CMAKE_SHARED_LINKER_FLAGS "-avoid-version -module -Wl,--no-undefined -Wl,--allow-shlib-undefined") #set(CMAKE_SHARED_LINKER_FLAGS "-Wl,--fatal-warnings -avoid-version -Wl,--no-undefined -lc") @@ -55,7 +63,8 @@ endif(CMAKE_SYSTEM_NAME MATCHES "Linux") #now try to find some kde stuff #at first the KDE include direcory -FIND_PATH(KDE3_INCLUDE_DIR kurl.h +# kpassdlg.h comes from kdeui and doesn't exist in KDE4 anymore +FIND_PATH(KDE3_INCLUDE_DIR kpassdlg.h $ENV{KDEDIR}/include /opt/kde/include /opt/kde3/include |