[systemd-devel] [PATCH] Add -lresolv to libudev LIBADD

Łukasz Stelmach l.stelmach at samsung.com
Fri Feb 21 06:54:57 PST 2014


Fix problems with unresolved symbols when building on Ubuntu 12.04 x86_64.

--8<---------------cut here---------------start------------->8---
./.libs/libudev.so: undefined reference to `__res_search'
./.libs/libudev.so: undefined reference to `__res_query'
collect2: ld returned 1 exit status
--8<---------------cut here---------------end--------------->8---

---
 Makefile.am |    3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/Makefile.am b/Makefile.am
index f6c22bd..682266b 100644
--- a/Makefile.am
+++ b/Makefile.am
@@ -2416,7 +2416,8 @@ libudev_la_LDFLAGS = \
 
 libudev_la_LIBADD = \
 	libsystemd-internal.la \
-	libsystemd-shared.la
+	libsystemd-shared.la \
+	-lresolv
 
 pkgconfiglib_DATA += \
 	src/libudev/libudev.pc
-- 
1.7.9.5



More information about the systemd-devel mailing list