Last change
on this file since 25 was 4, checked in by Mattia Monga, 14 years ago |
Importazione sorgenti libro
|
File size:
800 bytes
|
Rev | Line | |
---|
[4] | 1 | # Makefile for memory driver (MEMORY)
|
---|
| 2 | DRIVER = memory
|
---|
| 3 |
|
---|
| 4 | # directories
|
---|
| 5 | u = /usr
|
---|
| 6 | i = $u/include
|
---|
| 7 | s = $i/sys
|
---|
| 8 | m = $i/minix
|
---|
| 9 | b = $i/ibm
|
---|
| 10 | d = ..
|
---|
| 11 |
|
---|
| 12 | # programs, flags, etc.
|
---|
| 13 | MAKE = exec make
|
---|
| 14 | CC = exec cc
|
---|
| 15 | CFLAGS = -I$i
|
---|
| 16 | LDFLAGS = -i
|
---|
| 17 | LIBS = -lsys -lsysutil
|
---|
| 18 |
|
---|
| 19 | OBJ = memory.o
|
---|
| 20 | LIBDRIVER = $d/libdriver/driver.o
|
---|
| 21 |
|
---|
| 22 |
|
---|
| 23 | # build local binary
|
---|
| 24 | all build: $(DRIVER)
|
---|
| 25 | $(DRIVER): $(OBJ) $(LIBDRIVER)
|
---|
| 26 | $(CC) -o $@ $(LDFLAGS) $(OBJ) $(LIBDRIVER) $(LIBS)
|
---|
| 27 | install -S 1024w $(DRIVER)
|
---|
| 28 |
|
---|
| 29 | $(LIBDRIVER):
|
---|
| 30 | cd $d/libdriver && $(MAKE)
|
---|
| 31 |
|
---|
| 32 |
|
---|
| 33 | # install with other drivers
|
---|
| 34 | install: /usr/sbin/$(DRIVER)
|
---|
| 35 | /usr/sbin/$(DRIVER): $(DRIVER)
|
---|
| 36 | install -o root -cs $? $@
|
---|
| 37 |
|
---|
| 38 | # clean up local files
|
---|
| 39 | clean:
|
---|
| 40 | rm -f $(DRIVER) *.o *.bak
|
---|
| 41 |
|
---|
| 42 |
|
---|
| 43 | depend:
|
---|
| 44 | /usr/bin/mkdep "$(CC) -E $(CPPFLAGS)" *.c ../libdriver/*.c > .depend
|
---|
| 45 |
|
---|
| 46 | # Include generated dependencies.
|
---|
| 47 | include .depend
|
---|
| 48 |
|
---|
Note:
See
TracBrowser
for help on using the repository browser.