File: Makefile

package info (click to toggle)
thinkpad 5.8-4
  • links: PTS
  • area: main
  • in suites: sarge
  • size: 604 kB
  • ctags: 1,459
  • sloc: ansic: 5,985; makefile: 226; sh: 179; asm: 44; sed: 22
file content (29 lines) | stat: -rw-r--r-- 979 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29

all: thinkpad.o smapi.o superio.o rtcmosram.o

include ../Makefile_common

CFLAGS:=-I$(KSRC)/include -I../include -Wall -Wcast-align -Wstrict-prototypes -DLINUX -O2

MODCFLAGS:=$(CFLAGS) -O -DMODULE -D__KERNEL__

thinkpad.o: thinkpad.c ../include/thinkpad_common.h ../include/thinkpad_mod_defines.h ../include/thinkpad.h
	$(CC) $(MODCFLAGS) -o $@ -c thinkpad.c

smapi.o: smapi_core.o smapi_call.o
	ld -r $^ -o $@ 

smapi_core.o: smapi_core.c ../include/thinkpad_common.h ../include/thinkpad_mod_defines.h ../include/smapi.h ../include/smapi_call.h
	$(CC) $(MODCFLAGS) -o $@ -c smapi_core.c

smapi_call.o: smapi_call.s
	$(CC) $(MODCFLAGS) -o $@ -c smapi_call.s

superio.o: superio.c ../include/thinkpad_common.h ../include/thinkpad_mod_defines.h ../include/superio.h
	$(CC) $(MODCFLAGS) -o $@ -c superio.c

rtcmosram.o: rtcmosram.c ../include/thinkpad_common.h ../include/thinkpad_mod_defines.h ../include/rtcmosram.h
	$(CC) $(MODCFLAGS) -o $@ -c rtcmosram.c

clean:
	rm -vf *.o