[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: Bug#737465: wpa: FTBFS on kfreebsd-*: src/eap_peer/tncc.o: undefined reference to symbol 'dlsym@@GLIBC_2.3'



Control: tags -1 + patch

The problem is that GNU/kFreeBSD needs -ldl for that object, whereas if
using the BSD driver it skips adding -ldl to $LIBS:

> ifdef CONFIG_EAP_TNC
> OBJS += ../src/eap_peer/tncc.o
> [...]
> ifndef CONFIG_DRIVER_BSD
> LIBS += -ldl
> endif
> endif

Adding it to the wpasupplicant/kfreebsd configuration file is
sufficient.  The same problem also happens building hostapd and can be
fixed the same way.  Patch is attached.

(While here, the -lbsd turns out not to be needed so I've commented it out.)

Thanks!
Regards,
-- 
Steven Chamberlain
steven@pyro.eu.org
diff -Nru a/wpa-1.0/debian/config/hostapd/kfreebsd b/wpa-1.0/debian/config/hostapd/kfreebsd
--- a/wpa-1.0/debian/config/hostapd/kfreebsd	2012-04-14 00:13:49.000000000 +0100
+++ b/wpa-1.0/debian/config/hostapd/kfreebsd	2014-02-02 21:27:36.260346137 +0000
@@ -29,7 +29,10 @@
 #LIBS += -L/usr/local/lib
 #LIBS_p += -L/usr/local/lib
 #LIBS_c += -L/usr/local/lib
-LIBS += -lbsd
+# Not needed on GNU/kFreeBSD
+#LIBS += -lbsd
+# Needed on GNU/kFreeBSD
+LIBS += -ldl
 
 # Driver interface for no driver (e.g., RADIUS server only)
 CONFIG_DRIVER_NONE=y
diff -Nru a/wpa-1.0/debian/config/wpasupplicant/kfreebsd b/wpa-1.0/debian/config/wpasupplicant/kfreebsd
--- a/wpa-1.0/debian/config/wpasupplicant/kfreebsd	2013-12-05 18:55:40.000000000 +0000
+++ b/wpa-1.0/debian/config/wpasupplicant/kfreebsd	2014-02-02 21:27:26.552345400 +0000
@@ -95,7 +95,10 @@
 #LIBS += -L/usr/local/lib
 #LIBS_p += -L/usr/local/lib
 #LIBS_c += -L/usr/local/lib
-LIBS += -lbsd
+# Not needed on GNU/kFreeBSD
+#LIBS += -lbsd
+# Needed on GNU/kFreeBSD
+LIBS += -ldl
 
 # Driver interface for Windows NDIS
 #CONFIG_DRIVER_NDIS=y

Reply to: