From 2b9ae40d830596eda80cc5bc5252c6685cb75eaa Mon Sep 17 00:00:00 2001 From: Samuli Suominen Date: Sat, 15 Mar 2014 20:40:24 +0200 Subject: [PATCH] Link against -lresolv to prevent linker errors like: /usr/lib/gcc/ia64-unknown-linux-gnu/4.7.3/../../../../ia64-unknown- linux-gnu/bin/ld: Warning: gc-sections option ignored ./.libs/libsystemd-internal.a(libsystemd_internal_la-sd-resolve.o): In function `handle_request': /tmp/systemd-211/src/libsystemd/sd-resolve/sd-resolve.c:432: undefined reference to '__res_search' /tmp/systemd-211/src/libsystemd/sd-resolve/sd-resolve.c:430: undefined reference to '__res_query' IA64 arch with -fuse-ld=gold doesn't support --gc-sections, which revealed the underlinking. See Gentoo bug 504700. --- Makefile.am | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/Makefile.am b/Makefile.am index 9e01cd5..4b8a081 100644 --- a/Makefile.am +++ b/Makefile.am @@ -2121,7 +2121,8 @@ libsystemd_internal_la_CFLAGS = \ -pthread libsystemd_internal_la_LIBADD = \ - $(RT_LIBS) + $(RT_LIBS) \ + -lresolv noinst_LTLIBRARIES += \ libsystemd-internal.la -- 1.9.0