Changeset 556

Show
Ignore:
Timestamp:
09/12/99 02:25:00 (9 years ago)
Author:
frodo
Message:

Makefile now automatically detects whether kernel modules need to

be made, or only the user-space utiltities.

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • lm-sensors/trunk/Makefile

    r547 r556  
    3232LINUX_HEADERS=$(LINUX)/include 
    3333 
     34# Determine whether we need to compile the kernel modules, or only the 
     35# user-space utilities. 
     36COMPILE_KERNEL := $(shell if test -d $(LINUX)/drivers/sensors ; \ 
     37                          then echo 0; else echo 1; fi) 
     38#COMPILE_KERNEL := 0 
     39#COMPILE_KERNEL := 1 
     40 
    3441# If you have installed the i2c header at some other place (like  
    3542# /usr/local/include/linux), set that directory here. Please check this out 
     
    123130# to do this.  
    124131 
    125  
    126132# The subdirectories we need to build things in  
    127 SRCDIRS := kernel kernel/busses kernel/chips kernel/include lib prog/sensors \ 
    128            prog/dump prog/detect etc 
     133SRCDIRS :=  
     134ifeq ($(COMPILE_KERNEL),1) 
     135SRCDIRS += kernel kernel/busses kernel/chips kernel/include 
     136endif 
     137SRCDIRS += lib prog/sensors prog/dump prog/detect etc 
    129138 
    130139# Some often-used commands with default options