Makefile revision 7981
1
2all: console
3
4DBMENTRY	= fffffc0000010000
5INCLUDES        = -I$(PALCODE) -I$(INCLUDEH) -I$(M5)/dev
6
7SOURDIR = ./
8PALCODE  = ../palcode
9INCLUDEH = ../h
10
11dbmentry.o: dbmentry.s 
12	$(AS)  $(INCLUDES) -nointrinsics -o $*.o $*.s
13
14console.o: console.c
15	$(CC)  -g3 $(INCLUDES) -nointrinsics -o $*.o -c $*.c
16
17printf.o: printf.c 
18	$(CC)  -g3 $(INCLUDES) -nointrinsics -o $*.o -c $*.c
19
20paljtokern.s.o: paljtokern.s
21	g++ -I ../palcode -E -P -nostdinc -nostdinc++ -x c++ paljtokern.s | \
22	gas -m 21164 -o paljtokern.s.o
23
24paljtoslave.s.o: paljtoslave.s
25	g++ -I ../palcode -E -P -nostdinc -nostdinc++ -x c++ paljtoslave.s | \
26	gas -m 21164 -o paljtoslave.s.o
27
28paljtokern.c: paljtokern.s.o
29	echo 'unsigned int palJToKern[] = {' > paljtokern.c
30	dis paljtokern.s.o | awk '{print "0x"$$2","}' >> paljtokern.c
31	echo "0x0\n};" >> paljtokern.c
32
33paljtoslave.c: paljtoslave.s.o
34	echo "unsigned int palJToSlave[] = {" > paljtoslave.c
35	dis paljtoslave.s.o | awk '{print "0x"$$2","}' >> paljtoslave.c
36	echo "0x0\n};" >> paljtoslave.c
37
38paljtokern.c.o: paljtokern.c
39	$(CC) -g3 -nointrinsics -o paljtokern.c.o -c paljtokern.c
40
41paljtoslave.c.o: paljtoslave.c
42	$(CC) -g3 -nointrinsics -o paljtoslave.c.o -c paljtoslave.c
43
44console: console.o dbmentry.o printf.o paljtokern.c.o paljtoslave.c.o 
45	$(LD) -o console  -N -T $(DBMENTRY) -non_shared \
46	dbmentry.o console.o printf.o paljtokern.c.o paljtoslave.c.o -lc
47
48install: console
49	scp console zizzer.eecs.umich.edu:/z/m5/system/testing/binaries/console
50
51clean:
52	rm -f *.o console *.strip paljtokern.c paljtoslave.c
53