[CMake] hear hear

Johannes Zarl johannes.zarl at jku.at
Mon Dec 12 05:01:42 EST 2011


On Tuesday, 6. December 2011, 17:27:47, Daniel Dekkers wrote:
> On Dec 4, 2011, at 11:59 AM, Michael Jackson wrote:
> > I think if the CMake community took a vote we could probably come up with
> > an "Exemplar" Find*.cmake file that is good for someone trying to
> > develop a new one.
> 
> Yes please.
> And I think in general that is true. Of course it is more interesting and
> often more urgent to spend time on "exotic" problems. But there are these
> basics that are missing in the documentation. Like,.. this works in 99% of
> the cases, we, CMake, advise you to do this. If you don't, you are making
> life hard on yourself and you are more or less on your own. Something
> like:
> 1) a single executable
> 2) a single executable linked to a lib built from source
> 3) different executables using the same lib built from source
> 4) a single executable linked to a binary lib (with the aid of a find
> module) ...
> n) multiple executables linked to multiple libraries (linked to third-party
> libraries), some static, some dynamic, some with their own CMake builds,
> some without, on different platforms. Auch. n+1) making anything work with
> Xcode

I would like that, too.

Also, it would be nice if the example would include a *Config.cmake (and 
*Version.cmake) file. What I notice with several projects is that the 
*config.cmake mechanism for finding out about a package is still largely ignored 
and each projects rolls out its own Find*.cmake file instead, which dependent 
projects than copy into their source tree.

Raising the awareness for the *Config.cmake style of making your package easy 
to find would certainly be a good thing. 

Cheers,
  Johannes


More information about the CMake mailing list