Show
Ignore:
Timestamp:
01/28/99 16:36:01 (14 years ago)
Author:
frodo
Message:

Stuff to get rid of the LM_SENSORS define

Until now, all installed include files depended on a #defined variable
LM_SENSORS: if it was defined, other files were included as "somefile.h"
instead of <linux/somefile.h>. This was clearly dangerous, and is fixed
now, by automatically deleting the offending lines from the include file
when it is installed.

Files:
1 modified

Legend:

Unmodified
Added
Removed
  • lm-sensors/trunk/kernel/include/Module.mk

    r179 r180  
    2121MODULE_DIR := kernel/include 
    2222 
    23 KERNELINCLUDEHEADERFILES := $(MODULE_DIR)/sensors.h $(MODULE_DIR)/isa.h \ 
    24                             $(MODULE_DIR)/smbus.h $(MODULE_DIR)/i2c-dev.h 
     23KERNELINCLUDEFILES := $(MODULE_DIR)/sensors.h $(MODULE_DIR)/isa.h \ 
     24                      $(MODULE_DIR)/smbus.h $(MODULE_DIR)/i2c-dev.h 
    2525 
    2626install-all-kernel-include: 
    2727        $(MKDIR) $(SYSINCLUDEDIR) 
    28         $(INSTALL) -o root -g root -m 644 $(SRCHEADERFILES) $(SYSINCLUDEDIR) 
     28        for file in $(KERNELINCLUDEFILES) ; do \ 
     29          $(RM) $$file.install; \ 
     30          $(GREP) -v '/\* TBD \*/' $$file > $$file.install; \ 
     31          $(INSTALL) -o root -g root -m 644 $$file.install \ 
     32                    $(SYSINCLUDEDIR)/`basename $$file`; \ 
     33          $(RM) $$file.install; \ 
     34        done 
    2935install :: install-all-kernel-include 
     36 
     37clean-all-kernel-include: 
     38        $(RM) $(KERNELINCLUDEFILES:.h=.h.install) 
     39 
     40clean :: clean-all-kernel-include