compat-wireless: fix building with CONFIG_CFG80211_INTERNAL_REGDB
authorHauke Mehrtens <hauke@hauke-m.de>
Thu, 18 Aug 2011 11:45:04 +0000 (13:45 +0200)
committerLuis R. Rodriguez <mcgrof@qca.qualcomm.com>
Mon, 22 Aug 2011 15:05:29 +0000 (08:05 -0700)
When building with CONFIG_CFG80211_INTERNAL_REGDB set there is a db.txt
and genregdb.awk needed. $(srctree) contains the position of the kernel
source and not the position of the compat-wireless root directory.

Reported-by: Ed W <lists@wildgooses.com>
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
config.mk
patches/35-fix-makefile-includes.patch
scripts/admin-update.sh

index e2bffeb227e567f07607f11fe4696fe328a5cde9..7c6bc3bb7be819a5b2f6d7ee1bcb1e684a157797 100644 (file)
--- a/config.mk
+++ b/config.mk
@@ -158,6 +158,7 @@ CONFIG_CFG80211_DEFAULT_PS=y
 # CONFIG_NL80211_TESTMODE=y
 # CONFIG_CFG80211_DEVELOPER_WARNINGS=y
 # CONFIG_CFG80211_REG_DEBUG=y
+# CONFIG_CFG80211_INTERNAL_REGDB=y
 # See below for wext stuff
 
 CONFIG_LIB80211=m
index 3211c71e0957655f694542f26bbee4fb3f553988..aa3dd92a171868f37a7a85ca87a53007f9cb7a0b 100644 (file)
@@ -59,3 +59,13 @@ path the make process will search in the kernel tree for the headers.
  
  BRCMUTIL_OFILES := \
        utils.o \
+--- a/net/wireless/Makefile
++++ b/net/wireless/Makefile
+@@ -18,6 +18,6 @@ cfg80211-$(CONFIG_CFG80211_INTERNAL_REGD
+ ccflags-y += -D__CHECK_ENDIAN__
+ $(obj)/regdb.c: $(src)/db.txt $(src)/genregdb.awk
+-      @$(AWK) -f $(srctree)/$(src)/genregdb.awk < $< > $@
++      @$(AWK) -f $(src)/genregdb.awk < $< > $@
+ clean-files := regdb.c
index edd45d4073f4a5314c87717edc270f690920a41b..061748c3c669ba9dfc8bce889542906096a77d81 100755 (executable)
@@ -328,6 +328,10 @@ for i in $NET_DIRS; do
        rm -f net/$i/*.mod.c
 done
 
+# Copy files needed for statically compiled regulatory rules database
+cp $GIT_TREE/net/wireless/db.txt net/wireless/
+cp $GIT_TREE/net/wireless/genregdb.awk net/wireless/
+
 # net/bluetooth
 for i in $NET_BT_DIRS; do
        mkdir -p net/$i