Add support for Linux 3.x and newer
authorproski <proski@0192ed92-7a03-0410-a25b-9323aeb14dbd>
Wed, 1 Jun 2011 16:00:18 +0000 (16:00 +0000)
committerproski <proski@0192ed92-7a03-0410-a25b-9323aeb14dbd>
Wed, 1 Jun 2011 16:00:18 +0000 (16:00 +0000)
git-svn-id: http://madwifi-project.org/svn/madwifi/trunk@4143 0192ed92-7a03-0410-a25b-9323aeb14dbd

Makefile

index c05032785ef9d4cf7324268f57ac989497af6fa5..bf21ea7a5bb5c156f26a2de97c687251f7a7d256 100644 (file)
--- a/Makefile
+++ b/Makefile
@@ -170,13 +170,15 @@ unload:
 configcheck: sanitycheck
        @echo -n "Checking kernel configuration... "
        
-       @# check version of kernel
-       @echo $(KERNELRELEASE) | grep -q -i '^[2-9]\.[4-9]\.' || { \
-           echo "FAILED"; \
-           echo "Only kernel versions 2.4.x and above are supported."; \
-           echo "You have $(KERNELRELEASE)."; \
-           exit 1; \
-       }
+       @# check kernel version
+       @case $(KERNELRELEASE) in \
+           2.[456].*) ;; \
+           [3-9].*) ;; \
+           *) echo "FAILED"; \
+              echo "Only kernel versions 2.4.x and above are supported."; \
+              echo "You have $(KERNELRELEASE)."; \
+              exit 1 ;; \
+       esac
        
        @# check kernel configuration
        @if [ -z "$(CONFIG_SYSCTL)" ]; then \