diff --git a/Modules/FindKDE3.cmake b/Modules/FindKDE3.cmake index bca71dec2..d8ef875c9 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 722e299de..86cfd5725 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)