This merge request adds a pkg-config template (
CMake/openvds.pc.in) and extends the CMake configuration such that the file is populated with appropriate information like the installation prefix and the OpenVDS version number. The configuration resulting file (
openvds.pc is installed into
$CMAKE_INSTALL_PREFIX/lib/pkgconfig/. Depending on the installation prefix one might have to extend the environment variable
PKG_CONFIG_PATH to include
$CMAKE_INSTALL_PREFIX/lib/pkgconfig/ such that pkg-config file can be found by the system.
This make ingestion of OpenVDS easier for projects that do not use CMake as build system and have pkg-config available for obtaining build flags. One example would be projects using Go and its build system. Go has explicit support for pkg-config in the CGO package to obtain the needed flags for compiling and linking of applications to other packages. Would this be something one could add?
I did test this on my machine (Arm64, Mac OSX 12) and it worked nicely.
- Can the
configure_filecommand stay at this location in the
- Should we document this feature somewhere (README, somewhere else, changelog)?
Closes #150 (closed)