Hi all,

In Natty, there was a recent change to the packaging of libuuid.so - it's no 
longer in /usr/lib, it's now in /usr/lib/i386-linux-gnu

The package includes a pkgconfig file, and pkg-config --libs uuid gives the 
right result. I updated FindUUID.cmake to use pkgconfig - here's the patch. Can 
someone review & commit, please?

Thanks,
Dave.

diff -r efcdf3baccfe owbuild/FindUUID.cmake
--- a/owbuild/FindUUID.cmake        Thu Mar 24 19:41:54 2011 +0100
+++ b/owbuild/FindUUID.cmake        Thu Mar 31 11:24:03 2011 +0200
@@ -4,6 +4,7 @@
 #  UUID_FOUND - system has UUID
 #  UUID_INCLUDE_DIRS - the UUID include directory
 #  UUID_LIBRARIES - Link these to use UUID
+#  UUID_PUBLIC_LINK_FLAGS - ldflags for UUID
 #  UUID_DEFINITIONS - Compiler switches required for using UUID
 #
 #  Copyright (c) 2006 Andreas Schneider <m...@cynapses.org>
@@ -13,15 +14,19 @@
 #  For details see the accompanying COPYING-CMAKE-SCRIPTS file.
 #
 
-
 if (UUID_LIBRARIES AND UUID_INCLUDE_DIRS)
   # in cache already
   set(UUID_FOUND TRUE)
 else (UUID_LIBRARIES AND UUID_INCLUDE_DIRS)
+  include(UsePkgConfig)
+
+  pkgconfig(uuid _UUIDIncDir _UUIDLinkDir _UUIDLinkFlags _UUIDCflags)
+
   find_path(UUID_INCLUDE_DIR
     NAMES
       uuid/uuid.h
     PATHS
+      ${_UUIDIncDir}
       /usr/include
       /usr/local/include
       /opt/local/include
@@ -32,6 +37,7 @@
     NAMES
       uuid
     PATHS
+      ${_UUIDLinkDir}
       /usr/lib
       /usr/local/lib
       /opt/local/lib
@@ -45,6 +51,12 @@
     ${UUID_LIBRARY}
   )
 
+  set(UUID_DEFINITIONS ${_UUIDCflags})
+
+  set(UUID_PUBLIC_LINK_FLAGS
+    ${_UUIDLinkFlags}
+  )
+    
   if (UUID_INCLUDE_DIRS AND UUID_LIBRARIES)
     set(UUID_FOUND TRUE)
   endif (UUID_INCLUDE_DIRS AND UUID_LIBRARIES)


-- 
Dave Neary
dne...@free.fr
Lyon, France
+33 9 51 13 46 45
_______________________________________________
QuteCom-dev mailing list
QuteCom-dev@lists.qutecom.org
http://lists.qutecom.org/mailman/listinfo/qutecom-dev

Reply via email to