Notes |
|
(0032631)
|
Brad King
|
2013-03-14 13:26
|
|
Our policy for find module maintenance is here:
http://www.cmake.org/Wiki/CMake:Module_Maintainers [^]
If you would like to implement the proposed pkgconfig functionality we welcome the contribution.
Of course the "C" in CMake stands for "cross-platform" and pkgconfig does not work on all Windows toolchains so if ImageMagick supports Windows there still needs to be a way to work without pkgconfig.
|
|
|
(0032652)
|
Rex Dieter
|
2013-03-16 21:31
|
|
cmake-2.8.11-rc1-IM_pkgconfig_hints.patch is a first draft if adding pkg-config hints as well as searching for new 6.<quantum> style libraries.
Probably would to conditionalize the pkgconfig support for certain platforms (wrapped in 'if (NOT WIN32)' ... ), but hopefully you get the idea. |
|
|
(0032654)
|
Brad King
|
2013-03-18 09:02
|
|
Re 0014012:0032652: Thanks, that looks like a good start. I do not think we need a platform conditional, my request in 0014012:0032631 was simply that it also work without pkgconfig.
In order to be sure the PKG_CHECK_MODULES macro is available one must first find_package(PkgConfig QUIET). See Modules/FindLibXml2.cmake for an example. |
|
|
(0032655)
|
Rex Dieter
|
2013-03-18 10:23
|
|
Great, iteration 2, cmake-2.8.11-rc1-IM_pkgconfig_hints-2.patch
adds find_package(PkgConfig QUIET) |
|
|
(0032657)
|
Brad King
|
2013-03-18 11:10
|
|
Re 0014012:0032655: Thanks. Orion, does Rex's patch work for you? Please also try it with the hard-coded name combinations commented out so you know it is pkgconfig that works. |
|
|
(0032658)
|
Orion Poplawski
|
2013-03-18 11:15
|
|
Brad - Rex is building the Fedora cmake package with this patch, so we are doing our testing there, and Rex can speak for me about whether this is fixed or not. So far so good it seems though. I'll try to do a test with the name search commented out soon. |
|
|
(0032660)
|
Orion Poplawski
|
2013-03-18 11:41
|
|
So, the pkgconfig patch really isn't doing much to help find the name for the library other than telling us *where* to look.
We'd need to somehow parse:
# pkg-config MagickCore --libs
-lm -lMagickCore-6.Q16
to extract the name to do that. Brad - any suggestions here? |
|
|
(0032661)
|
Orion Poplawski
|
2013-03-18 12:12
|
|
|
|
(0032662)
|
Brad King
|
2013-03-18 12:33
|
|
If ImageMagick is willing to become CMake-aware they could provide a package configuration file:
http://www.cmake.org/Wiki/CMake/Tutorials/Packaging [^]
even if they don't build with CMake. That would allow find_package to work even without a find module.
Qt5 does this for example. |
|
|
(0032663)
|
Brad King
|
2013-03-18 12:34
|
|
Re 0014012:0032660: I'm not particularly familiar with CMake's PkgConfig API so I don't know whether it already has something for parsing library names. |
|
|
(0032664)
|
Orion Poplawski
|
2013-03-18 12:36
|
|
I passed your CMake configuration file suggestion on in my thread as well. Good idea! |
|
|
(0032668)
|
Brad King
|
2013-03-18 16:41
|
|
|
|
(0036320)
|
Brad King
|
2014-07-07 09:54
|
|
I've split what remains of Rex's patch out as attachment "0001-FindImageMagick-Use-pkgconfig-hints-if-available-14012.patch".
According to 0015007 it looks like it may be necessary to use pkgconfig to get CFLAGS in some cases. |
|
|
(0036356)
|
broucari
|
2014-07-12 16:13
|
|
No the problem is more than cflags. You need to check arch include dir also |
|
|
(0036377)
|
Brad King
|
2014-07-14 15:05
|
|
|
|
(0036378)
|
Brad King
|
2014-07-14 15:07
|
|
The remaining issue is to use the CFLAGS, and issue 0015007 covers that, so I've resolved this issue. |
|
|
(0037584)
|
Robert Maynard
|
2015-01-05 08:39
|
|
Closing resolved issues that have not been updated in more than 4 months |
|