]> git.ipfire.org Git - thirdparty/nftables.git/commitdiff
Export libnftables (again)
authorPhil Sutter <phil@nwl.cc>
Wed, 21 Mar 2018 13:16:40 +0000 (14:16 +0100)
committerPablo Neira Ayuso <pablo@netfilter.org>
Wed, 21 Mar 2018 13:23:51 +0000 (14:23 +0100)
This reverts commits d572d59788143945c2a638f12a5227d9b21ce489 and
9f5e49e147219cd161de8cd80cadf8a444969ef0.

Current libnftables API should be stable enough to release it into the
public, and after 4aba100e593f ("rule: reset cache iff there is an
existing cache") we have a simple way to batch commands through this
API.

Suggested-by: Pablo Neira Ayuso <pablo@netfilter.org>
Signed-off-by: Phil Sutter <phil@nwl.cc>
Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org>
Makefile.am
configure.ac
libnftables.pc.in [new file with mode: 0644]
src/.gitignore
src/Makefile.am

index 5ef61be6dfecbfa82bd9ce9e03f7d97b02ed66c9..1201ca78e4f1721a65464fd726dc3f56ed776630 100644 (file)
@@ -6,3 +6,6 @@ SUBDIRS =       src     \
 
 EXTRA_DIST =   tests   \
                files
+
+pkgconfigdir = $(libdir)/pkgconfig
+pkgconfig_DATA = libnftables.pc
index 6c6b9b3a4c4bbf1c0aae8e11d76acd13ffcf3d05..284bcc502346a0039110e16d62e49ecfbd4e07d6 100644 (file)
@@ -109,6 +109,7 @@ AM_CONDITIONAL([BUILD_XTABLES], [test "x$with_libxtables" == xyes])
 
 AC_CONFIG_FILES([                                      \
                Makefile                                \
+               libnftables.pc                          \
                src/Makefile                            \
                include/Makefile                        \
                include/nftables/Makefile               \
diff --git a/libnftables.pc.in b/libnftables.pc.in
new file mode 100644 (file)
index 0000000..6431d48
--- /dev/null
@@ -0,0 +1,15 @@
+# libnftables pkg-config file
+
+prefix=@prefix@
+exec_prefix=@exec_prefix@
+libdir=@libdir@
+includedir=@includedir@
+
+Name: libnftables
+Description: Netfilter nf_tables user library
+URL: http://netfilter.org/projects/nftables/
+Version: @VERSION@
+Requires:
+Conflicts:
+Libs: -L${libdir} -lnftables
+Cflags: -I${includedir}
index e27d4f8431eec146a2b56460d21237e72a8cc83a..36d6acd1e4d0138cd16a0c03f3c4e451c8edd9c8 100644 (file)
@@ -1,4 +1,3 @@
-libnftables.a
 libnftables.la
 parser.c
 parser.h
index 677ca3969c8589fd68aaab394c01497f2d67148b..92e6795f659aa06be4f751e7344ba77216d1eca7 100644 (file)
@@ -24,7 +24,7 @@ AM_YFLAGS = -d
 
 BUILT_SOURCES = parser_bison.h
 
-noinst_LTLIBRARIES = libnftables.la
+lib_LTLIBRARIES = libnftables.la
 
 libnftables_la_SOURCES =                       \
                rule.c                          \
@@ -58,7 +58,7 @@ libnftables_la_SOURCES =                      \
                libnftables.c
 
 # yacc and lex generate dirty code
-noinst_LTLIBRARIES += libparser.la
+noinst_LTLIBRARIES = libparser.la
 libparser_la_SOURCES = parser_bison.y scanner.l
 libparser_la_CFLAGS = ${AM_CFLAGS} \
                      -Wno-missing-prototypes \