Return-path: Received: from server19320154104.serverpool.info ([193.201.54.104]:33741 "EHLO hauke-m.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753493Ab0IKQS7 (ORCPT ); Sat, 11 Sep 2010 12:18:59 -0400 From: Hauke Mehrtens To: lrodriguez@atheros.com Cc: linux-wireless@vger.kernel.org, mcgrof@infradead.org, Hauke Mehrtens Subject: [PATCH 1/8] compat-wireless: handle depending on something build as module Date: Sat, 11 Sep 2010 18:18:26 +0200 Message-Id: <1284221913-22455-3-git-send-email-hauke@hauke-m.de> In-Reply-To: <1284221913-22455-1-git-send-email-hauke@hauke-m.de> References: <1284221913-22455-1-git-send-email-hauke@hauke-m.de> Sender: linux-wireless-owner@vger.kernel.org List-ID: If something was build as module in the kernel it is named CONFIG_..._MODULE in autoconf.h. We have to check for bouth the name with and wothout _MODULE at the end. Signed-off-by: Hauke Mehrtens --- scripts/gen-compat-autoconf.sh | 4 ++-- 1 files changed, 2 insertions(+), 2 deletions(-) diff --git a/scripts/gen-compat-autoconf.sh b/scripts/gen-compat-autoconf.sh index 5d38ea1..62aa890 100755 --- a/scripts/gen-compat-autoconf.sh +++ b/scripts/gen-compat-autoconf.sh @@ -148,11 +148,11 @@ kernel_version_req $OLDEST_KERNEL_SUPPORTED for i in $(egrep '^CONFIG_|^ifdef CONFIG_|^ifndef CONFIG_|^endif #CONFIG_|^else #CONFIG_' $COMPAT_CONFIG | sed 's/ /+/'); do case $i in 'ifdef+CONFIG_'* ) - echo "#$i" | sed 's/+/ /' | sed 's/\(ifdef CONFIG_COMPAT_KERNEL_\)\([0-9]*\)/if (LINUX_VERSION_CODE < KERNEL_VERSION(2,6,\2))/' + echo "#$i" | sed -e 's/+/ /' -e 's/\(ifdef CONFIG_COMPAT_KERNEL_\)\([0-9]*\)/if (LINUX_VERSION_CODE < KERNEL_VERSION(2,6,\2))/' -e 's/\(#ifdef \)\(CONFIG_[^:space:]*\)/#if defined(\2) || defined(\2_MODULE)/' continue ;; 'ifndef+CONFIG_'* ) - echo "#$i" | sed 's/+/ /' | sed 's/\(ifndef CONFIG_COMPAT_KERNEL_\)\([0-9]*\)/if (LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,\2))/' + echo "#$i" | sed -e 's/+/ /' -e 's/\(ifndef CONFIG_COMPAT_KERNEL_\)\([0-9]*\)/if (LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,\2))/' -e 's/\(#ifndef \)\(CONFIG_[^:space:]*\)/#if !defined(\2) && !defined(\2_MODULE)/' continue ;; 'else+#CONFIG_'* | 'endif+#CONFIG_'* ) -- 1.7.0.4