Android: Make libnl 2.0 support build-agnostic
Change-Id: If9e922d88a542dc30a66879dec614a592e91f350
Signed-off-by: Dmitry Shmidt <dimitrysh@google.com>
diff --git a/hostapd/Android.mk b/hostapd/Android.mk
index f2bc9b0..5d6fe56 100644
--- a/hostapd/Android.mk
+++ b/hostapd/Android.mk
@@ -51,7 +51,11 @@
INCLUDES += external/openssl/include
INCLUDES += system/security/keystore/include
ifdef CONFIG_DRIVER_NL80211
+ifneq ($(wildcard external/libnl),)
INCLUDES += external/libnl/include
+else
+INCLUDES += external/libnl-headers
+endif
endif
@@ -910,7 +914,11 @@
endif
LOCAL_SHARED_LIBRARIES := libc libcutils liblog libcrypto libssl
ifdef CONFIG_DRIVER_NL80211
+ifneq ($(wildcard external/libnl),)
LOCAL_SHARED_LIBRARIES += libnl
+else
+LOCAL_STATIC_LIBRARIES += libnl_2
+endif
endif
LOCAL_CFLAGS := $(L_CFLAGS)
LOCAL_SRC_FILES := $(OBJS)