Changeset 3989

Show
Ignore:
Timestamp:
07/24/05 17:40:03 (3 years ago)
Author:
khali
Message:

Detect 2.6+ kernels and stop. Original idea by Jim Cromie.

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • i2c/trunk/CHANGES

    r3984 r3989  
    20202.9.2 (2005????) 
    2121  Makefile: Do not compile i2c-algo-biths by default 
     22            Detect 2.6+ kernels and stop 
    2223  i2c.h: Drop additional members of struct i2c_msg, so as to 
    2324         restore the binary compatibility with Linux 2.4 
  • i2c/trunk/Makefile

    r3970 r3989  
    6161# This is the directory into which the modules will be installed. 
    6262# The magic invocation will return something like this: 
    63 #   /lib/modules/2.2.15-ac9/misc 
    64 #MODDIR := /lib/modules/`grep UTS_RELEASE $(LINUX_HEADERS)/linux/version.h|cut -f 2 -d'"'`/misc 
    65 #MODPREF := /lib/modules/`grep UTS_RELEASE $(LINUX_HEADERS)/linux/version.h|cut -f 2 -d'"'` 
    66 #MODPREF := /lib/modules/$(KERNELVERSION) 
     63#   /lib/modules/2.4.29 
    6764MODPREF := /lib/modules/$(shell $(CC) -I$(LINUX_HEADERS) -E etc/config.c | grep uts_release |cut -f 2 -d'"') 
     65 
     66# Prevent 2.6+ users from using this package, as this won't work. 
     67ifeq (,$(findstring /2.4., $(MODPREF))) 
     68    ifeq (, $(MAKECMDGOALS)) 
     69        $(error For 2.6 kernels and later, you do not need this package) 
     70    endif 
     71    ifeq (install, $(MAKECMDGOALS)) 
     72        $(error For 2.6 kernels and later, you do not need this package) 
     73    endif 
     74endif 
    6875 
    6976# This is the directory into which the header files will be installed.