[CMake] Some minor issues for 2.6.0-RC-8
Alan W. Irwin
irwin at beluga.phys.uvic.ca
Wed Apr 23 12:29:23 EDT 2008
On 2008-04-23 09:28-0400 Miguel A. Figueroa-Villanueva wrote:
>> Actually, the Module should be fixed instead to do the documented thing.
>> Like pkg-config, the wx-config output should be properly post-processed.
>>
>> HS
>
> I guess there are always some unhappy customers ;)
>
> Actually, I guess this is the right thing to do... However, I think
> that the redundancy should be exploited. That is, I'm willing to use
> the FindPkgConfig macros/functions to post-process (even gather) the
> wx-config output.
>
> However, I'll need some time before I can implement/test all this.
> Also, what does the pkg-config module do with the options: -framework,
> -isysroot, -arch, etc.
I have confirmed there is an undocumented (at least for Debian testing)
pkg-config flag called --libs-only-other which delivers all non-L and non-l
flags linker flags. This corresponds to what is delivered by
<XPREFIX>_LDFLAGS_OTHER by FindPkgConfig.cmake.
On the other hand, the man page for wx-config
states
--libs Output link flags required for a wxWidgets application.
which is equivalent to the pkg-config --libs option, but unlike pkg-config
there doesn't appear to be any other linker flag options for wx-config.
However, I suggest you use the appropriate CMake logic to transform the
contents of what is delivered by --libs into the equivalent of the results
returned by FindPkgConfig.cmake such as
# wxWidgets_LIBRARIES ... only the libraries (w/o the '-l')
# wxWidgets_LIBRARY_DIRS ... the paths of the libraries (w/o the '-L')
# wxWidgets_LDFLAGS ... all required linker flags
# wxWidgets_LDFLAGS_OTHER ... all other linker flags
> What is the correct thing to do with these
> parameters in CMake? I would need to check this too, I suppose.
Users would be advised to use the LINK_FLAGS and/or LINK_FLAGS_<CONFIG>
property set by SET_TARGET_PROPERTIES to pass the separated out (by e.g.,
wxWidgets_LDFLAGS_OTHER) -framework, -isysroot, -arch, -pthread options to
the linker.
Alan
__________________________
Alan W. Irwin
Astronomical research affiliation with Department of Physics and Astronomy,
University of Victoria (astrowww.phys.uvic.ca).
Programming affiliations with the FreeEOS equation-of-state implementation
for stellar interiors (freeeos.sf.net); PLplot scientific plotting software
package (plplot.org); the libLASi project (unifont.org/lasi); the Loads of
Linux Links project (loll.sf.net); and the Linux Brochure Project
(lbproject.sf.net).
__________________________
Linux-powered Science
__________________________
More information about the CMake
mailing list