-
Notifications
You must be signed in to change notification settings - Fork 172
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
The generated pkg-config files of libscap and libsinsp now makes use of pkg-config Requires and Requires.static fields, which should reduce over-linking when linking to shared libraries. * cmake/modules/BuildPkgConfigDependencies.cmake (add_pkgconfig_library): Add debug messages and fix an issue where IN_LIST had no effect. * cmake/modules/libscap.cmake: Move pkgconfig dependency computation to, pkg-config file configuration to... * userspace/libscap/CMakeLists.txt: ... here, conditionally accumulating Requires and Requires.private values. * userspace/libscap/libscap.pc.in (prefix): Set directly to CMAKE_INSTALL_PREFIX. (Requires, Requires.private): New fields. * userspace/libsinsp/CMakeLists.txt: Separate libraries into pkg-config Requires and Requires.private lists. Add the pkg-config requirements to the ignored link dependencies, since these are now recorded as Requires in the pkg-config file. * userspace/libsinsp/libsinsp.pc.in (Requires): Add @LIBSINSP_REQUIRES@. (Requires.private): New field. (Libs): Remove -lsinsp, automatically computed in SINSP_PKG_CONFIG_LIBS. Signed-off-by: Maxim Cournoyer <[email protected]>
Showing
6 changed files
with
68 additions
and
17 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,10 +1,12 @@ | ||
prefix=${pcfiledir}/../.. | ||
prefix=@CMAKE_INSTALL_PREFIX@ | ||
libdir=${prefix}/@CMAKE_INSTALL_LIBDIR@ | ||
includedir=${prefix}/@CMAKE_INSTALL_INCLUDEDIR@/@LIBS_PACKAGE_NAME@ | ||
|
||
Name: libscap | ||
Description: lib for System CAPture | ||
Version: @FALCOSECURITY_LIBS_VERSION@ | ||
|
||
Requires: @LIBSCAP_PKGCONFIG_REQUIRES@ | ||
Requires.private: @LIBSCAP_PKGCONFIG_REQUIRES_PRIVATE@ | ||
Libs: -L${libdir} @LIBSCAP_LINK_LIBDIRS_FLAGS@ @LIBSCAP_LINK_LIBRARIES_FLAGS@ | ||
Cflags: -I${includedir} -I${includedir}/libscap -I${includedir}/driver -I@UTHASH_INCLUDE@ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,11 +1,12 @@ | ||
prefix=${pcfiledir}/../.. | ||
prefix=@CMAKE_INSTALL_PREFIX@ | ||
libdir=${prefix}/@CMAKE_INSTALL_LIBDIR@ | ||
includedir=${prefix}/@CMAKE_INSTALL_INCLUDEDIR@/@LIBS_PACKAGE_NAME@ | ||
|
||
Name: libsinsp | ||
Description: lib for System INSPection | ||
Version: @FALCOSECURITY_LIBS_VERSION@ | ||
|
||
Requires: libscap | ||
Libs: -L${libdir} -lsinsp @SINSP_PKG_CONFIG_LIBDIRS@ @SINSP_PKG_CONFIG_LIBS@ | ||
Requires: libscap @LIBSINSP_REQUIRES@ | ||
Requires.private: @LIBSINSP_REQUIRES_PRIVATE@ | ||
Libs: -L${libdir} @SINSP_PKG_CONFIG_LIBDIRS@ @SINSP_PKG_CONFIG_LIBS@ | ||
Cflags: -I${includedir} -I${includedir}/libsinsp -I${includedir}/driver @SINSP_PKG_CONFIG_INCLUDES@ |