]> git.ipfire.org Git - thirdparty/iptables.git/commitdiff
Makefile: fix static compilation iptables-compat without shared libraries
authorPablo Neira Ayuso <pablo@netfilter.org>
Fri, 13 Jun 2014 09:40:41 +0000 (11:40 +0200)
committerPablo Neira Ayuso <pablo@netfilter.org>
Fri, 13 Jun 2014 10:05:58 +0000 (12:05 +0200)
Fix linking problems when this configuration is used:

 $ ./configure --prefix=/usr --enable-shared=no --enable-static=yes
 $ make
 ...
xtables_compat_multi-xtables-save.o: In function `xtables_save_main':
/home/pablo/devel/iptables/iptables/xtables-save.c:98: undefined reference to `init_extensions4'
xtables_compat_multi-xtables-restore.o: In function `xtables_restore_main':
/home/pablo/devel/iptables/iptables/xtables-restore.c:195: undefined reference to `init_extensions4'
xtables_compat_multi-xtables-standalone.o: In function `xtables_main':
/home/pablo/devel/iptables/iptables/xtables-standalone.c:61: undefined reference to `init_extensions4'
xtables_compat_multi-xtables-events.o: In function `xtables_events_main':
/home/pablo/devel/iptables/iptables/xtables-events.c:184: undefined reference to `init_extensions4'

Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org>
iptables/Makefile.am

index 41bca7c757fcff1d58ebd69900a2c5a93563eeb5..aaaade85550315be016010a4a4f09f1ed75f40fb 100644 (file)
@@ -40,7 +40,7 @@ xtables_compat_multi_SOURCES += xtables-save.c xtables-restore.c \
                                nft-shared.c nft-ipv4.c nft-ipv6.c nft-arp.c \
                                xtables-config.c xtables-events.c \
                                xtables-arp-standalone.c xtables-arp.c
-xtables_compat_multi_LDADD   += ${libmnl_LIBS} ${libnftnl_LIBS}
+xtables_compat_multi_LDADD   += ${libmnl_LIBS} ${libnftnl_LIBS} ../extensions/libext4.a ../extensions/libext6.a
 # yacc and lex generate dirty code
 xtables_compat_multi-xtables-config-parser.o xtables_compat_multi-xtables-config-syntax.o: AM_CFLAGS += -Wno-missing-prototypes -Wno-missing-declarations -Wno-implicit-function-declaration -Wno-nested-externs -Wno-undef -Wno-redundant-decls
 xtables_compat_multi_SOURCES += xshared.c