]> git.ipfire.org Git - thirdparty/xtables-addons.git/commitdiff
build: autodetect value for --with-xtlibdir
authorJan Engelhardt <jengelh@medozas.de>
Sat, 30 Oct 2010 23:00:37 +0000 (01:00 +0200)
committerJan Engelhardt <jengelh@medozas.de>
Sat, 30 Oct 2010 23:01:13 +0000 (01:01 +0200)
configure.ac
doc/changelog.txt

index 2c7b37c0c80d9cbd7ecb31681950c84daa7728b0..b7236b4e171baf147c21492fe003afa0a7d8e7e8 100644 (file)
@@ -21,15 +21,17 @@ if [[ "$kbuilddir" == no ]]; then
        kbuilddir="";
 fi
 
-AC_ARG_WITH([xtlibdir],
-       AS_HELP_STRING([--with-xtlibdir=PATH],
-       [Path where to install Xtables extensions [[LIBEXECDIR/xtables]]]),
-       [xtlibdir="$withval"],
-       [xtlibdir='${libexecdir}/xtables'])
-
-PKG_CHECK_MODULES([libxtables], [xtables >= 1.4.3])
 AC_CHECK_HEADERS([linux/netfilter/x_tables.h], [],
        [AC_MSG_ERROR([You need to have linux/netfilter/x_tables.h, see INSTALL file for details])])
+PKG_CHECK_MODULES([libxtables], [xtables >= 1.4.3])
+xtlibdir="$(pkg-config --variable=xtlibdir xtables)"
+
+AC_ARG_WITH([xtlibdir],
+       AS_HELP_STRING([--with-xtlibdir=PATH],
+       [Path where to install Xtables extensions [[autodetect]]]]),
+       [xtlibdir="$withval"])
+AC_MSG_CHECKING([Xtables module directory])
+AC_MSG_RESULT([$xtlibdir])
 
 regular_CFLAGS="-D_LARGEFILE_SOURCE=1 -D_LARGE_FILES -D_FILE_OFFSET_BITS=64 \
        -D_REENTRANT -Wall -Waggregate-return -Wmissing-declarations \
index 0982252daa7e3389dbfb1e02d696a09a4f9f9492..78cd36d9b553404d18b82ba81899732cb7b4459f 100644 (file)
@@ -3,6 +3,10 @@ HEAD
 ====
 - LOGMARK: print remaining lifetime of cts
 - build: improve detection of kernel version and error handling
+- build: automatically derive Xtables module directory, thus
+  --with-xtlibdir is no longer needed for ./configure in most cases
+  (If I still see a distro using it, I will scold you for not
+  reading this changelog.)
 
 
 v1.30 (October 02 2010)