[CMake] Managing a local installation of cmake-built open source packages

Elizabeth A. Fischer elizabeth.fischer at columbia.edu
Wed Jan 18 18:25:28 EST 2017


Ardi,

What you describe is pretty much what Spack does.  I would take a look at
it, see if it meets your needs.  Chances are, at least some of the packages
you need are already included in Spack:

https://github.com/llnl/spack

-- Elizabeth

On Wed, Jan 18, 2017 at 12:39 PM, ardi <ardillasdelmonte at gmail.com> wrote:

> Hi,
>
> I want to install (on UNIX-like systems) a collection of open source
> packages which use cmake as the build tool, but I need the
> installation to be performed in a local directory (inside my home
> directory), and I wish convenient updating to new versions of the
> packages.
>
> I didn't arrive to a convincing solution, so any advice will be welcome.
>
> Here are my thoughts:
>
> The trivial solution is of course to directly install to a non-root
> prefix when invoking cmake, but, however, this isn't well suited for
> updating a previous installation of the packages (building and
> installing a new version will only overwrite files that have the same
> name, but it will keep old files that no longer exist in the new
> version, cluttering the local installation directory with no longer
> needed and mismatched files).
>
> A possibility would be to keep a copy of install_manifest.txt whenever
> I install a package, and remembering to always run 'xargs rm <
> install_manifest.txt' before installing a different version of a
> previously installed package.
>
> But keeping the install_manifest.txt of each installed package (and
> using it before updating a package) looks like a too-manual task,
> candidate to some kind of automation.
>
> Another (perhaps wiser) possibility would be to use cpack for creating
> either a RPM or DEB, and then use the corresponding package manager to
> install the package. But this has problems too: most package managers
> assume a / root installation directory. Also, I use several OSs: OSX,
> Linux, and some BSDs, and I'm not sure that either the RPM nor the DEB
> pkg managers will work flawlessly across all the OSs I use.
>
> What would you recommend here?
>
> Thanks a lot!
> --
>
> Powered by www.kitware.com
>
> Please keep messages on-topic and check the CMake FAQ at:
> http://www.cmake.org/Wiki/CMake_FAQ
>
> Kitware offers various services to support the CMake community. For more
> information on each offering, please visit:
>
> CMake Support: http://cmake.org/cmake/help/support.html
> CMake Consulting: http://cmake.org/cmake/help/consulting.html
> CMake Training Courses: http://cmake.org/cmake/help/training.html
>
> Visit other Kitware open-source projects at http://www.kitware.com/
> opensource/opensource.html
>
> Follow this link to subscribe/unsubscribe:
> http://public.kitware.com/mailman/listinfo/cmake
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://public.kitware.com/pipermail/cmake/attachments/20170118/97ebba5e/attachment-0001.html>


More information about the CMake mailing list