On Monday 10 August 2009, Andreas Pakulat wrote:
> On 10.08.09 12:31:23, Allan Sandfeld Jensen wrote:
> >
> > What goes wrong is that, find_path and find_library search the default
> > system paths BEFORE searching the paths that you have asked it to search
> > in.
>
> Thats obviously wrong, but your patch is wrong too. What should be done is
> using the HINTS keyword instead of PATHS for the paths we receive from
> pkg-config.
>
> Also this discussion should be held on kde-buildsystem (cc'ed now), not
> kde-core-devel
>
Thanks. I somehow missed the HINTS argument to the functions. Here is the
updated cmake modules for polkitqt and qimageblitz. I am afraid however this
might be a common mistake/copy-paste spread bug.
`Allan
Index: cmake/modules/FindQImageBlitz.cmake
===================================================================
--- cmake/modules/FindQImageBlitz.cmake (revision 1006759)
+++ cmake/modules/FindQImageBlitz.cmake (working copy)
@@ -27,10 +27,10 @@
NAMES
qimageblitz.h
PATH_SUFFIXES qimageblitz
- PATHS
+ HINTS
$ENV{QIMAGEBLITZDIR}/include
${PC_QIMAGEBLITZ_INCLUDEDIR}
- ${PC_QIMAGEBLITZ_INCLUDE_DIRS}
+ PATHS
${KDE4_INCLUDE_DIR}
${INCLUDE_INSTALL_DIR}
)
@@ -38,10 +38,10 @@
find_library_with_debug(QIMAGEBLITZ_LIBRARIES
WIN32_DEBUG_POSTFIX d
qimageblitz
- PATHS
+ HINTS
$ENV{QIMAGEBLITZDIR}/lib
${PC_QIMAGEBLITZ_LIBDIR}
- ${PC_QIMAGEBLITZ_LIBRARY_DIRS}
+ PATHS
${KDE4_LIB_DIR}
${LIB_INSTALL_DIR}
)
Index: workspace/cmake/modules/FindPolkitQt.cmake
===================================================================
--- workspace/cmake/modules/FindPolkitQt.cmake (revision 1009520)
+++ workspace/cmake/modules/FindPolkitQt.cmake (working copy)
@@ -44,10 +44,19 @@
# find_path( POLKITQT_INCLUDE_DIR PolicyKit/policykit-qt/Polkit-qt )
-find_path( POLKITQT_INCLUDE_DIR PolicyKit/polkit-qt/ )
+find_path( POLKITQT_INCLUDE_DIR
+ NAMES PolicyKit/polkit-qt/
+ HINTS ${POLKITQT_INCLUDEDIR}
+)
-find_library( POLKITQT_CORE_LIBRARY NAMES polkit-qt-core )
-find_library( POLKITQT_GUI_LIBRARY NAMES polkit-qt-gui )
+find_library( POLKITQT_CORE_LIBRARY
+ NAMES polkit-qt-core
+ HINTS ${POLKITQT_LIBDIR}
+)
+find_library( POLKITQT_GUI_LIBRARY
+ NAMES polkit-qt-gui
+ HINTS ${POLKITQT_LIBDIR}
+)
if (POLKITQT_INCLUDE_DIR AND POLKITQT_CORE_LIBRARY AND POLKITQT_GUI_LIBRARY)
set(POLKITQT_FOUND TRUE)
_______________________________________________
Kde-buildsystem mailing list
[email protected]
https://mail.kde.org/mailman/listinfo/kde-buildsystem