mirror of
https://gitlab.com/apparmor/apparmor.git
synced 2025-03-04 08:24:42 +01:00
Subject: libapparmor - add pkgconfig support
Merge from trunk commit 2079 Original message: Given that we want to do more apparmor things in user space (dbus mediation, file picker, etc.), making it easier for other source bases to detect the presence of libapparmor would be beneficial. This patch adds pkg-config support to the build infrastructure for libapparmor. Signed-off-by: Steve Beattie <sbeattie@ubuntu.com> Acked-by: Kees Cook <kees@ubuntu.com> Nominated-by: Steve Beattie <sbeattie@ubuntu.com> Acked-by: John Johansen <john.johansen@canonical.com>
This commit is contained in:
parent
6654dfe251
commit
84e7cdb5ee
3 changed files with 22 additions and 1 deletions
|
@ -10,6 +10,7 @@ AM_INIT_AUTOMAKE(libapparmor1, apparmor_version)
|
||||||
AM_PROG_LEX
|
AM_PROG_LEX
|
||||||
AC_PROG_YACC
|
AC_PROG_YACC
|
||||||
AC_PROG_SED
|
AC_PROG_SED
|
||||||
|
PKG_PROG_PKG_CONFIG
|
||||||
|
|
||||||
AC_PATH_PROG([SWIG], [swig])
|
AC_PATH_PROG([SWIG], [swig])
|
||||||
|
|
||||||
|
|
|
@ -22,6 +22,7 @@ AA_LIB_CURRENT = 1
|
||||||
AA_LIB_REVISION = 2
|
AA_LIB_REVISION = 2
|
||||||
AA_LIB_AGE = 0
|
AA_LIB_AGE = 0
|
||||||
|
|
||||||
|
SUFFIXES = .pc.in .pc
|
||||||
|
|
||||||
BUILT_SOURCES = grammar.h scanner.h af_protos.h
|
BUILT_SOURCES = grammar.h scanner.h af_protos.h
|
||||||
AM_LFLAGS = -v
|
AM_LFLAGS = -v
|
||||||
|
@ -52,9 +53,18 @@ libapparmor_la_LDFLAGS = -version-info $(AA_LIB_CURRENT):$(AA_LIB_REVISION):$(AA
|
||||||
libimmunix_la_SOURCES = kernel_interface.c libimmunix_warning.c
|
libimmunix_la_SOURCES = kernel_interface.c libimmunix_warning.c
|
||||||
libimmunix_la_LDFLAGS = -version-info $(AA_LIB_CURRENT):$(AA_LIB_REVISION):$(AA_LIB_AGE) -Wl,--version-script=$(top_srcdir)/src/libapparmor.map -Wl,-soname=libimmunix.so.1
|
libimmunix_la_LDFLAGS = -version-info $(AA_LIB_CURRENT):$(AA_LIB_REVISION):$(AA_LIB_AGE) -Wl,--version-script=$(top_srcdir)/src/libapparmor.map -Wl,-soname=libimmunix.so.1
|
||||||
|
|
||||||
|
pkgconfigdir = $(libdir)/pkgconfig
|
||||||
|
pkgconfig_DATA = libapparmor.pc
|
||||||
|
|
||||||
|
CLEANFILES = libapparmor.pc
|
||||||
|
|
||||||
|
%.pc: %.pc.in $(top_builddir)/config.status
|
||||||
|
$(AM_V_GEN)cd "$(top_builddir)" && \
|
||||||
|
$(SHELL) ./config.status --file="src/$@"
|
||||||
|
|
||||||
tst_aalogmisc_SOURCES = tst_aalogmisc.c
|
tst_aalogmisc_SOURCES = tst_aalogmisc.c
|
||||||
tst_aalogmisc_LDADD = .libs/libapparmor.a
|
tst_aalogmisc_LDADD = .libs/libapparmor.a
|
||||||
check_PROGRAMS = tst_aalogmisc
|
check_PROGRAMS = tst_aalogmisc
|
||||||
TESTS = $(check_PROGRAMS)
|
TESTS = $(check_PROGRAMS)
|
||||||
|
|
||||||
EXTRA_DIST = grammar.y scanner.l libapparmor.map
|
EXTRA_DIST = grammar.y scanner.l libapparmor.map libapparmor.pc
|
||||||
|
|
10
libraries/libapparmor/src/libapparmor.pc.in
Normal file
10
libraries/libapparmor/src/libapparmor.pc.in
Normal file
|
@ -0,0 +1,10 @@
|
||||||
|
prefix=@prefix@
|
||||||
|
exec_prefix=@exec_prefix@
|
||||||
|
libdir=@libdir@
|
||||||
|
includedir=@includedir@
|
||||||
|
|
||||||
|
Name: libapparmor
|
||||||
|
Description: AppArmor library for for utility functions
|
||||||
|
Version: @VERSION@
|
||||||
|
Cflags: -I${includedir}
|
||||||
|
Libs: -L${libdir} -lapparmor
|
Loading…
Add table
Reference in a new issue