Problem with cmake module FindGTK2.cmake in Ubuntu >= 11.04 (Natty Narwhal)
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
cmake (Ubuntu) |
Fix Released
|
Medium
|
Unassigned |
Bug Description
Binary package hint: libglib2.0-dev
Hi,
I compared:
http://
http://
Why you still move file:
/usr/lib/
to directories:
/usr/lib/
/usr/lib/
?
It is broke compilation of some programs which use cmake.
There is only warning on configuration stage:
"-- Some or all of the gtk libraries were not found. (missing: GTK2_GLIBCONFIG
But compilation fails...
See string #426 in /usr/share/
"_GTK2_
Next I found in changelog file that glibconfig.h was moved in glib2.0 version 2.25.12-2 in Debian Experimental
http://
http://
But it was long time ago...
Now this problem affects only libglib2.0-dev (2.28.5-0ubuntu1) in Ubuntu Natty.
The package libglib2.0-dev (2.28.4-1) in Debian Sid is correct:
http://
http://
Temporary I solved this problem in our project with following patch:
--- a/cmake/
+++ b/cmake/
@@ -185,6 +185,10 @@ function(
find_
PATHS
+ # fix for Ubuntu >= 11.04 (Natty Narwhal)
+ /usr/lib/
+ /usr/lib/
+ # end fix for Ubuntu >= 11.04 (Natty Narwhal)
But this is bad idea to push such patch in cmake upstream or to modify cmake-data package in Ubuntu.
So problem must be fixed in this package I think.
Regards,
Boris
summary: |
- Problems with cmake in Ubuntu Ubuntu >= 11.04 (Natty Narwhal) + Problem with cmake in Ubuntu >= 11.04 (Natty Narwhal) |
summary: |
- Problem with cmake in Ubuntu >= 11.04 (Natty Narwhal) + Problem with cmake module FindGTK2.cmake in Ubuntu >= 11.04 (Natty + Narwhal) |
affects: | cmake (Ubuntu) → glib2.0 (Ubuntu) |
This is a buggy assumption on the part of cmake. The standard interface that glib provides for consumers to query its library paths and cflags is pkg-config. On natty:
$ pkg-config --cflags glib-2.0 include/ glib-2. 0 -I/usr/ lib/x86_ 64-linux- gnu/glib- 2.0/include
-I/usr/
$
cmake should use pkg-config in FindGTK2.cmake. If there's a need to search additional paths, this should be done by permuting the *pkg-config* search path, using the PKG_CONFIG_PATH env var.