|
|
1.1 root 1: #
2: # Ported to boot 386BSD by Julian Elischer ([email protected])
3: # September 1992
4: #
5: # Permission to use, copy, modify and distribute this software and its
6: # documentation is hereby granted, provided that both the copyright
7: # notice and this permission notice appear in all copies of the
8: # software, derivative works or modified versions, and any portions
9: # thereof, and that both notices appear in supporting documentation.
10: #
11: # CARNEGIE MELLON ALLOWS FREE USE OF THIS SOFTWARE IN ITS "AS IS"
12: # CONDITION. CARNEGIE MELLON DISCLAIMS ANY LIABILITY OF ANY KIND FOR
13: # ANY DAMAGES WHATSOEVER RESULTING FROM THE USE OF THIS SOFTWARE.
14: #
15: # Carnegie Mellon requests users of this software to return to
16: #
17: # Software Distribution Coordinator or [email protected]
18: # School of Computer Science
19: # Carnegie Mellon University
20: # Pittsburgh PA 15213-3890
21: #
22: # any improvements or extensions that they make and grant Carnegie Mellon
23: # the rights to redistribute these changes.
24: #
25: #
26: # HISTORY
27: # $Log: Makefile,v $
28: # Revision 1.1 1993/03/21 18:08:11 cgd
29: # after 0.2.2 "stable" patches applied
30: #
31: # Revision 2.2 92/04/04 11:33:46 rpd
32: # Fabricated for MACH 3.0
33: # [92/03/30 mg32]
34: #
35: # Thu Sep 10 22:40:23 PDT 1992
36: # Ported to 386BSD by Julian Elischer
37: # [email protected]
38: #
39:
40: CFLAGS = -O -DDO_BAD144
41: LIBS= -lc
42: INC= -I../..
43:
44: # start.o should be first, table.o should be second
45: OBJS = start.o table.o boot2.o boot.o asm.o bios.o io.o disk.o sys.o
46:
47: .SUFFIXES: .s .c .o
48:
49: # These are wierd because we don't want separate code and data segments.. ok?
50: .c.o:
51: @echo $(CC) -c $(CFLAGS) $(INC) $*.c
52: -@trap "/bin/rm -f $*.i $*.s; exit 0" 0 1 2 3 10 15; \
53: $(CC) $(CFLAGS) $(INC) -S $<; \
54: if [ $$? != 0 ]; then :; else \
55: sed -f boot.sed $*.s > $*.i; \
56: $(AS) $*.i -o $@; \
57: fi
58:
59: .s.o:
60: @echo $(AS) -o $*.o $<
61: -@trap "/bin/rm -f $*.i X$*.c; exit 0" 0 1 2 3 10 15; \
62: /bin/rm -f X$*.c; \
63: ln $*.s X$*.c; \
64: $(CC) -E $(CFLAGS) X$*.c > $*.i; \
65: if [ $$? != 0 ]; then :; \
66: else \
67: $(AS) $*.i -o $@; \
68: fi
69:
70:
71: boot: boot.sed $(OBJS)
72: $(LD) -N -T 0 -o boot $(OBJS) $(LIBS)
73: cp boot boot.sym
74: @strip boot
75: @./rmaouthdr boot boot.tmp
76: @mv -f boot.tmp boot
77: @ls -l boot
78:
79: biosboot: boot
80: dd if=boot of=biosboot count=1
81:
82: bootbios: boot
83: dd if=boot of=bootbios skip=1
84:
85: /usr/mdec/bootsd: bootbios
86: cp bootbios /usr/mdec/bootsd
87:
88: /usr/mdec/sdboot: biosboot
89: cp biosboot /usr/mdec/sdboot
90:
91: /usr/mdec/bootwd: /usr/mdec/bootsd
92: rm -f /usr/mdec/bootwd
93: ln /usr/mdec/bootsd /usr/mdec/bootwd
94:
95: /usr/mdec/wdboot: /usr/mdec/sdboot
96: rm -f /usr/mdec/wdboot
97: ln /usr/mdec/sdboot /usr/mdec/wdboot
98:
99: /usr/mdec/bootfd: /usr/mdec/bootsd
100: rm -f /usr/mdec/bootfd
101: ln /usr/mdec/bootsd /usr/mdec/bootfd
102:
103: /usr/mdec/fdboot: /usr/mdec/sdboot
104: rm -f /usr/mdec/fdboot
105: ln /usr/mdec/sdboot /usr/mdec/fdboot
106:
107: sd: /usr/mdec/bootsd /usr/mdec/sdboot
108: wd: /usr/mdec/bootwd /usr/mdec/wdboot
109: fd: /usr/mdec/bootfd /usr/mdec/fdboot
110:
111: #wd0: /usr/mdec/bootwd /usr/mdec/wdboot
112: # disklabel -r -w wd0 julian julian5 /usr/mdec/wdboot /usr/mdec/bootwd
113: #
114:
115: sd0: /usr/mdec/bootsd /usr/mdec/sdboot
116: disklabel -r -w sd0 XT-8760 scsitest /usr/mdec/sdboot /usr/mdec/bootsd
117:
118:
119: #fd0: /usr/mdec/bootfd /usr/mdec/fdboot
120: # disklabel -r -w fd0 floppy5 bootflpy /usr/mdec/fdboot /usr/mdec/bootfd
121: #
122:
123: install: wd sd
124: # you should use the old floppy booter, it's MUCH faster
125: # This one works but it's too slow.
126: # besides how many kernels can you fit on a floppy?
127: # only use this one if you want to boot a kernel
128: # from a hard disk 2 when you've trashed hard disk 1
129: #install: wd sd fd
130:
131: clean:
132: /bin/rm -f *.o *.d boot bootbios biosboot boot.sym
133:
134:
This archive runs on limited infrastructure. Preserving old code on modern bandwidth. Automated agents are requested to crawl responsibly.