From 0428e5a6541c3f5eaaf683d8da9ea60c44eac4c7 Mon Sep 17 00:00:00 2001 From: Jan Engelhardt Date: Tue, 3 Aug 2010 19:58:38 +0200 Subject: build: fix static linking Gabor Z. Papp noted this link-time error when configuring with --enable-static: extensions/libext4.a(initext4.o): In function "init_extensions": extensions/initext4.c:144: undefined reference to "libxt_IDLETIMER_init" extensions/initext4.c:145: undefined reference to "libxt_TEE_init" Indeed, since the two modules did not use our special macro "_init" (which expands to libxt_foo_init), initext4.c could not find them by that name. Correct this. References: http://marc.info/?l=netfilter&m=128085480927924&w=2 Signed-off-by: Jan Engelhardt --- extensions/libxt_IDLETIMER.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'extensions/libxt_IDLETIMER.c') diff --git a/extensions/libxt_IDLETIMER.c b/extensions/libxt_IDLETIMER.c index 12573a4f..1562e02a 100644 --- a/extensions/libxt_IDLETIMER.c +++ b/extensions/libxt_IDLETIMER.c @@ -132,7 +132,7 @@ static struct xtables_target idletimer_tg_reg = { .extra_opts = idletimer_tg_opts, }; -static __attribute__((constructor)) void idletimer_tg_ldr(void) +void _init(void) { xtables_register_target(&idletimer_tg_reg); } -- cgit v1.2.3