From: Jan Engelhardt Date: Fri, 31 Aug 2012 01:59:07 +0000 (+0200) Subject: build: separate AC variable replacements from xtables.h X-Git-Tag: v1.4.16~2^2~5 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=df60a301bf24c3b3e37188d9da155b97fd6dc076;p=thirdparty%2Fiptables.git build: separate AC variable replacements from xtables.h It was/is a bit annoying that modifying xtables.h.in causes configure to rerun. Split the @foo@ things into a separate file to bypass this. Signed-off-by: Jan Engelhardt --- diff --git a/.gitignore b/.gitignore index b7c3dfb8..fa86c482 100644 --- a/.gitignore +++ b/.gitignore @@ -9,7 +9,7 @@ Makefile Makefile.in -/include/xtables.h +/include/xtables-version.h /include/iptables/internal.h /aclocal.m4 diff --git a/Makefile.am b/Makefile.am index 4eb63ebe..6400ba41 100644 --- a/Makefile.am +++ b/Makefile.am @@ -27,4 +27,4 @@ tarball: rm -Rf /tmp/${PACKAGE_TARNAME}-${PACKAGE_VERSION}; config.status: extensions/GNUmakefile.in \ - include/xtables.h.in include/iptables/internal.h.in + include/xtables-version.h.in include/iptables/internal.h.in diff --git a/configure.ac b/configure.ac index 861f5b3e..4060f901 100644 --- a/configure.ac +++ b/configure.ac @@ -127,5 +127,5 @@ AC_CONFIG_FILES([Makefile extensions/GNUmakefile include/Makefile libiptc/Makefile libiptc/libiptc.pc libiptc/libip4tc.pc libiptc/libip6tc.pc libxtables/Makefile utils/Makefile - include/xtables.h include/iptables/internal.h]) + include/xtables-version.h include/iptables/internal.h]) AC_OUTPUT diff --git a/include/Makefile.am b/include/Makefile.am index 6f7da598..e6951209 100644 --- a/include/Makefile.am +++ b/include/Makefile.am @@ -1,7 +1,7 @@ # -*- Makefile -*- include_HEADERS = -nobase_include_HEADERS = xtables.h +nobase_include_HEADERS = xtables.h xtables-version.h if ENABLE_LIBIPQ include_HEADERS += libipq/libipq.h diff --git a/include/xtables-version.h.in b/include/xtables-version.h.in new file mode 100644 index 00000000..cb13827c --- /dev/null +++ b/include/xtables-version.h.in @@ -0,0 +1,2 @@ +#define XTABLES_VERSION "libxtables.so.@libxtables_vmajor@" +#define XTABLES_VERSION_CODE @libxtables_vmajor@ diff --git a/include/xtables.h.in b/include/xtables.h similarity index 99% rename from include/xtables.h.in rename to include/xtables.h index db69c03b..3b15e67e 100644 --- a/include/xtables.h.in +++ b/include/xtables.h @@ -31,8 +31,7 @@ #define IPPROTO_UDPLITE 136 #endif -#define XTABLES_VERSION "libxtables.so.@libxtables_vmajor@" -#define XTABLES_VERSION_CODE @libxtables_vmajor@ +#include struct in_addr;