hostapd: fix build errors on supplicant-only builds
authorFelix Fietkau <nbd@openwrt.org>
Mon, 18 Mar 2013 16:11:32 +0000 (16:11 +0000)
committerFelix Fietkau <nbd@openwrt.org>
Mon, 18 Mar 2013 16:11:32 +0000 (16:11 +0000)
SVN-Revision: 36085

package/network/services/hostapd/Makefile
package/network/services/hostapd/patches/700-ubus_support.patch

index 0c44a8b08d92e8c4959eab463a5632db9709f54b..7024844d10cca297249389044192eac53647b870 100644 (file)
@@ -225,7 +225,9 @@ TARGET_CPPFLAGS := \
 
 TARGET_CFLAGS += -ffunction-sections -fdata-sections
 TARGET_LDFLAGS += -Wl,--gc-sections
-TARGET_LDFLAGS += -lubox -lubus
+ifeq ($(findstring supplicant,$(BUILD_VARIANT)),)
+  TARGET_LDFLAGS += -lubox -lubus
+endif
 
 ifdef CONFIG_PACKAGE_kmod-mac80211
   TARGET_LDFLAGS += -lm -lnl-tiny
index 92ca7b21ca185d462a3aed27e77c84788d54d54c..ad1a45bf38060478000c1aaa32a277d41c34e0b0 100644 (file)
 +      const u8 *addr;
 +};
 +
++struct hostapd_iface;
++struct hostapd_data;
++
 +#ifdef UBUS_SUPPORT
 +
 +#include <libubox/avl.h>
 +#include <libubus.h>
 +
-+struct hostapd_iface;
-+struct hostapd_data;
-+
 +struct hostapd_ubus_iface {
 +      struct ubus_object obj;
 +};