]> git.ipfire.org Git - thirdparty/iw.git/commitdiff
always use libnl 3.2 as 3.2, not 3.0
authorBjarke Istrup Pedersen <gurli@gurlinet.dk>
Mon, 14 Nov 2011 10:12:19 +0000 (11:12 +0100)
committerJohannes Berg <johannes.berg@intel.com>
Mon, 14 Nov 2011 10:12:19 +0000 (11:12 +0100)
With libnl 3.2, both LIBNL3FOUND and LIBNL3xFOUND
might become true, leading to errors. Disable the
former if the latter is found.

Makefile

index 6cad858f3b8b1cd6a1941c3a1059bc8b127a741e..3393d15f4276bdda42f2785aad42109824c5f7c8 100644 (file)
--- a/Makefile
+++ b/Makefile
@@ -38,6 +38,14 @@ LIBS += -lnl-genl
 NLLIBNAME = libnl-2.0
 endif
 
+ifeq ($(NL3xFOUND),Y)
+# libnl 3.2 might be found as 3.2 and 3.0
+NL3FOUND = N
+CFLAGS += -DCONFIG_LIBNL30
+LIBS += -lnl-genl-3
+NLLIBNAME = libnl-3.0
+endif
+
 ifeq ($(NL3FOUND),Y)
 CFLAGS += -DCONFIG_LIBNL30
 LIBS += -lnl-genl
@@ -52,12 +60,6 @@ LIBS += -lnl-genl
 NLLIBNAME = libnl-3.1
 endif
 
-ifeq ($(NL3xFOUND),Y)
-CFLAGS += -DCONFIG_LIBNL30
-LIBS += -lnl-genl-3
-NLLIBNAME = libnl-3.0
-endif
-
 ifeq ($(NLLIBNAME),)
 $(error Cannot find development files for any supported version of libnl)
 endif