move work on clean rule
[reactos.git] / reactos / drivers / input / sermouse / makefile
1 # $Id: makefile,v 1.5 2001/07/15 21:19:00 rex Exp $
2 #
3 #
4 TARGET = sermouse
5
6 PATH_TO_TOP = ../../..
7
8 OBJECTS = $(TARGET).o $(TARGET).coff ../../../ntoskrnl/ntoskrnl.a
9
10 CFLAGS = -D__NTDRIVER__ -O2 -I.
11
12 all: $(TARGET).sys
13
14 .phony: all
15
16 clean:
17 - $(RM) $(TARGET).o $(TARGET).coff junk.tmp base.tmp temp.exp sermouse.sys
18
19 .phony: clean
20
21 install: $(FLOPPY_DIR)/drivers/$(TARGET).sys
22
23 $(FLOPPY_DIR)/drivers/$(TARGET).sys: $(TARGET).sys
24 $(CP) $(TARGET).sys $(FLOPPY_DIR)/drivers/$(TARGET).sys
25
26 dist: ../../../$(DIST_DIR)/drivers/$(TARGET).sys
27
28 ../../../$(DIST_DIR)/drivers/$(TARGET).sys: $(TARGET).sys
29 $(CP) $(TARGET).sys ../../../$(DIST_DIR)/drivers/$(TARGET).sys
30
31 $(TARGET).sys: $(OBJECTS)
32 $(CC) \
33 -specs=../../svc_specs \
34 -mdll \
35 -o junk.tmp \
36 -Wl,--defsym,_end=end \
37 -Wl,--defsym,_edata=__data_end__ \
38 -Wl,--defsym,_etext=etext \
39 -Wl,--base-file,base.tmp \
40 $(OBJECTS)
41 - $(RM) junk.tmp
42 $(DLLTOOL) \
43 --dllname $(TARGET).sys \
44 --base-file base.tmp \
45 --output-exp temp.exp \
46 --kill-at
47 - $(RM) base.tmp
48 $(CC) \
49 --verbose \
50 -Wl,--image-base,0x10000 \
51 -Wl,-e,_DriverEntry@8 \
52 -Wl,temp.exp \
53 -specs=../../svc_specs \
54 -mdll \
55 -o $(TARGET).sys \
56 $(OBJECTS)
57 - $(RM) temp.exp
58
59
60 include ../../../rules.mak