diff options
author | Alexander Neundorf <neundorf@kde.org> | 2007-07-17 12:41:20 (GMT) |
---|---|---|
committer | Alexander Neundorf <neundorf@kde.org> | 2007-07-17 12:41:20 (GMT) |
commit | 7eb86d1e3cd69d8e23709b1bfd17f7a3f1ba6166 (patch) | |
tree | ebe6a840c8f8977b1432cbc8e34bd0583c2d38f8 | |
parent | e69958c3cf6974009fd26785b4938003d70f8450 (diff) | |
download | CMake-7eb86d1e3cd69d8e23709b1bfd17f7a3f1ba6166.zip CMake-7eb86d1e3cd69d8e23709b1bfd17f7a3f1ba6166.tar.gz CMake-7eb86d1e3cd69d8e23709b1bfd17f7a3f1ba6166.tar.bz2 |
ENH: don't hardcode the /lib/kde3/ directory for the libtool files, but make
it adjustable and detect if libkdecore.so is a 64bit library
Alex
-rw-r--r-- | Modules/FindKDE3.cmake | 12 | ||||
-rw-r--r-- | Modules/KDE3Macros.cmake | 2 |
2 files changed, 11 insertions, 3 deletions
diff --git a/Modules/FindKDE3.cmake b/Modules/FindKDE3.cmake index bca71de..d8ef875 100644 --- a/Modules/FindKDE3.cmake +++ b/Modules/FindKDE3.cmake @@ -76,8 +76,6 @@ FIND_PACKAGE(Qt3 REQUIRED) FIND_PACKAGE(X11 REQUIRED) -SET(QT_AND_KDECORE_LIBS ${QT_LIBRARIES} kdecore) - #add some KDE specific stuff SET(KDE3_DEFINITIONS -DQT_CLEAN_NAMESPACE -D_GNU_SOURCE) @@ -168,8 +166,18 @@ FIND_LIBRARY(KDE3_KDECORE_LIBRARY NAMES kdecore FIND_LIBRARY(KDE3_KDECORE_LIBRARY NAMES kdecore) +SET(QT_AND_KDECORE_LIBS ${QT_LIBRARIES} ${KDE3_KDECORE_LIBRARY}) + GET_FILENAME_COMPONENT(KDE3_LIB_DIR ${KDE3_KDECORE_LIBRARY} PATH ) +IF(NOT KDE3_LIBTOOL_DIR) + IF(KDE3_KDECORE_LIBRARY MATCHES lib64) + SET(KDE3_LIBTOOL_DIR /lib64/kde3) + ELSE(KDE3_KDECORE_LIBRARY MATCHES lib64) + SET(KDE3_LIBTOOL_DIR /lib/kde3) + ENDIF(KDE3_KDECORE_LIBRARY MATCHES lib64) +ENDIF(NOT KDE3_LIBTOOL_DIR) + #now search for the dcop utilities FIND_PROGRAM(KDE3_DCOPIDL_EXECUTABLE NAMES dcopidl PATHS $ENV{KDEDIR}/bin diff --git a/Modules/KDE3Macros.cmake b/Modules/KDE3Macros.cmake index 722e299..86cfd57 100644 --- a/Modules/KDE3Macros.cmake +++ b/Modules/KDE3Macros.cmake @@ -321,7 +321,7 @@ MACRO(KDE3_INSTALL_LIBTOOL_FILE _target) FILE(APPEND ${_laname} "# Directory that this library needs to be installed in:\n") FILE(APPEND ${_laname} "libdir='${CMAKE_INSTALL_PREFIX}/lib/kde3'\n") - INSTALL_FILES(/lib/kde3 FILES ${_laname}) + INSTALL_FILES(${KDE3_LIBTOOL_DIR} FILES ${_laname}) ENDMACRO(KDE3_INSTALL_LIBTOOL_FILE) |