dec21140A ethernet driver for virtualpc, contributed by nicolas tittley.
[minix.git] / drivers / memory / Makefile
blobd27a36472ae61dcc942e03bece22020417215be5
1 # Makefile for memory driver (MEMORY)
2 DRIVER = memory
4 # directories
5 u = /usr
6 i = $u/include
7 s = $i/sys
8 m = $i/minix
9 b = $i/ibm
10 d = ..
12 # programs, flags, etc.
13 MAKE = exec make
14 CC = exec cc
15 CFLAGS = -I$i
16 LDFLAGS = -i -L../libdriver
17 LIBS = -ldriver -lsys
19 # imgrd_s.s is the ACK assembler version of the ramdisk. For more portability,
20 # use the C version imgrd.c. However, the C compiler takes too much memory
21 # compiling imgrd.c.
22 IMGRD=imgrd_s.o
23 #IMGRD=imgrd.c
25 OBJ = memory.o $(IMGRD)
27 # build local binary
28 all build: $(DRIVER)
30 $(DRIVER): ramdisk_image $(OBJ)
31 $(CC) -o $@ $(LDFLAGS) $(OBJ) $(LIBS)
32 install -S 8k $(DRIVER)
34 imgrd.o: ramdisk/image.c
36 imgrd_s.o: ramdisk/image.s
37 TMPDIR=/usr/tmp $(CC) -T /usr/tmp -c imgrd_s.s
39 ramdisk_image:
40 cd ramdisk && make
42 # install with other drivers
43 install: /usr/sbin/$(DRIVER)
44 /usr/sbin/$(DRIVER): $(DRIVER)
45 install -o root -cs $? $@
47 # clean up local files
48 clean:
49 rm -f $(DRIVER) *.o *.bak
50 cd ramdisk && make clean
52 depend:
53 mkdep "$(CC) -E $(CPPFLAGS)" memory.c ../libdriver/*.c > .depend
54 cd ramdisk && make depend
56 # Include generated dependencies.
57 include .depend