[CMake] Packaging Best Practices for Linux
Alexander Neundorf
a.neundorf-work at gmx.net
Sun May 20 07:13:17 EDT 2012
On Wednesday 16 May 2012, Michael Jackson wrote:
...
> That was VERY informative. This is what I was afraid of. With Windows and
> OS X even though there are 3 or 4 versions if you build for the earliest
> one (XP or 10.5) the binary has a really good chance of still running on
> the latest (Win7 or Lion). With Linux and so many distributions I don't
> have time to create that many different virtual machines to compile on
> each and every one. I am a single developer. I think I am going to go the
> source route and make sure that my software just compiles with the
> standard packages from each of the distros (Qt 4, HDF5 1.8, Boost and
> Qwt). The only issue might be Qwt as I still use Version 5 and I think
> there is a newer version out that I doubt I am compatible with. All else
> fails I have my own repo for Qwt that is public for anyone to pull from. I
> very much want to support Linux in the best way possible. I was hoping for
> some thing easier but I guess this is just the way it is.
Well, e.g. Kitware releases a binary cmake package for Linux for every
release, so it is possible.
You should use a relatively old distribution to build that binary package.
Relying on Qt from the distro should be ok (... which means it kind of
contradicts with "use an old distro").
Linking statically against Qwt and HDF5 would make things a bit easier.
Otherwise you can link dynamically and set RPATH to $ORIGIN/../lib/ or
something like this for your executable(s).
The others are right that for a "first-class citizen" the package should get
into the distro repository.
Alex
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.cmake.org/pipermail/cmake/attachments/20120520/eb75710a/attachment-0001.htm>
More information about the CMake
mailing list