[cmake-developers] Self Introduction and fixes to the FindwxWidgets module

Richard Shaw hobbes1069 at gmail.com
Thu Aug 21 09:09:10 EDT 2014


Hello CMake developers!

I just recently got my arm twisted^H^H^H^H I mean volunteered to take over
maintenance of the FindwxWidgets module which I use quite frequently. I'm
not a developer strictly speaking but I've been a Fedora linux packager for
over 3 years now (where did the time go?).

My first package was OpenCOLLADA which uses CMake as it's build system and
that's where I first cut my teeth on CMake. Now I maintain dozens of
packages and whenever i have to fix something I always breath a sigh of
relief when it's cmake based rather than autotools based.

I also recently (within the last year) converted a project[1] from
autotools and manual makefiles to CMake, which was quite a learning
experience. It's actually the primary reason I'm interested in making
improvements to the wxWidgets module.

Now to my problem/question:

There are two bugs open for the module, one around path type detection
(unix or win32)[2] and one for processing of CFLAGS[3]

The solution to bug 15087 I think is settled so my question is around bug
11296.

The problem is it doesn't take into account whether you're cross-compiling
for path type detection. There is a solution that works provided in the bug
which I intend to implement but I had some other observations:
1. The 2nd if statement seems superfluous. If the path type is not win32
then it must be unix, correct? While I *think* all the platforms are
covered, the conditional logic still technically leaves the opportunity for
both conditionals to be false and then it doesn't set the path type at all.

In this case I intend to just remove the 2nd if clause.

2. The user has no manual override. I would think capability detection
would be a much better approach than platform detection but I'm not sure
how to implement it. For the meantime and to not make too disruptive of a
change to the logic that's been out there for so long I think it would be
good to provide a way for the user to override the path type.

Is there a preferred/good practices way to implement this?

Thanks,
Richard Shaw

[1] http://freedv.org
[2] http://www.cmake.org/Bug/view.php?id=11296
[3] http://www.cmake.org/Bug/view.php?id=15087
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://public.kitware.com/pipermail/cmake-developers/attachments/20140821/b7b3cb00/attachment.html>


More information about the cmake-developers mailing list