ChaiScript/contrib/pkgconfig/chaiscript.pc.in
leftibot 21c815d676 Fix #631: Respect CMAKE_INSTALL_PREFIX and use GNUInstallDirs for install paths
The CMakeLists.txt used CMAKE_INSTALL_LIBDIR in install destinations without
including the GNUInstallDirs module, leaving the variable empty. This caused
libraries to install to absolute paths like /chaiscript instead of lib/chaiscript,
and the pkg-config file to install to /pkgconfig instead of lib/pkgconfig. The
chaiscript.pc.in template also hardcoded "lib" and "include" instead of using
the CMake variables. Added include(GNUInstallDirs) and updated the .pc.in
template to use @CMAKE_INSTALL_LIBDIR@ and @CMAKE_INSTALL_INCLUDEDIR@.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-04-11 11:41:50 -06:00

13 lines
635 B
PkgConfig

prefix=@CMAKE_INSTALL_PREFIX@
exec_prefix=${prefix}
libdir=${exec_prefix}/@CMAKE_INSTALL_LIBDIR@
includedir=${prefix}/@CMAKE_INSTALL_INCLUDEDIR@
Name: chaiscript
Description: ChaiScript is a scripting language that easily embeds into your existing C++ applications. It's built to be flexible and dynamic, yet still maintain the type-safety you expect as a C++ user. It can natively use classes, methods, and attributes, even if the class inherits functionality from a parent class.
Version: @CPACK_PACKAGE_VERSION_MAJOR@.@CPACK_PACKAGE_VERSION_MINOR@.@CPACK_PACKAGE_VERSION_PATCH@
Requires:
Conflicts:
Libs:
Cflags: -I${includedir}