Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Hunterize] Add support for installs, with a project config #380

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

bkotzz
Copy link

@bkotzz bkotzz commented Mar 26, 2019

This change enhances the CMake script to support installing the package so that other projects can use it.

  • This adds support for a config file. This is the conventional way for a cmake project to support use by other projects via cmake find_package. See https://gitlab.kitware.com/cmake/community/wikis/doc/tutorials/How-to-create-a-ProjectConfig.cmake-file for more information.
  • This adds support for an install target. You can then run make install, and it will install the static library and headers for other projects to consume, the generated config files, and the binaries for all of the apps in the project. The install locations are conventional (/usr/local/{include|bin|lib}) but can be overriden by the consuming package, or a package manager.

I've tested the basic ability to build against the include directory and link against the static library, and be able to use the library from another project.

This is also sufficient for use with package managers like https://docs.hunter.sh/en/latest/index.html.

PTAL @barbibulle

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants