This commit was generated by cvs2svn to track changes on a CVS vendor
[unix-history] / sys / i386 / boot / Makefile
CommitLineData
15637ed4 1#
15637ed4
RG
2# Permission to use, copy, modify and distribute this software and its
3# documentation is hereby granted, provided that both the copyright
4# notice and this permission notice appear in all copies of the
5# software, derivative works or modified versions, and any portions
6# thereof, and that both notices appear in supporting documentation.
7#
8# CARNEGIE MELLON ALLOWS FREE USE OF THIS SOFTWARE IN ITS "AS IS"
9# CONDITION. CARNEGIE MELLON DISCLAIMS ANY LIABILITY OF ANY KIND FOR
10# ANY DAMAGES WHATSOEVER RESULTING FROM THE USE OF THIS SOFTWARE.
11#
12# Carnegie Mellon requests users of this software to return to
13#
14# Software Distribution Coordinator or Software.Distribution@CS.CMU.EDU
15# School of Computer Science
16# Carnegie Mellon University
17# Pittsburgh PA 15213-3890
18#
19# any improvements or extensions that they make and grant Carnegie Mellon
20# the rights to redistribute these changes.
21#
e4270b63
RG
22# from: Mach, Revision 2.2 92/04/04 11:33:46 rpd
23# $Id$
15637ed4 24#
e4270b63 25
a27f4645
RM
26wd0:
27 dd if=boot of=biosboot count=1
28 dd if=boot of=bootbios skip=1
29 disklabel -r -w wd0 nec5655 newboot biosboot bootbios
30 rm biosboot bootbios
15637ed4 31
a27f4645
RM
32NOPROG= noprog
33NOMAN= noman
34
35CFLAGS = -O -DDO_BAD144 -I${.CURDIR}
15637ed4 36LIBS= -lc
a27f4645 37INC= -I${.CURDIR}/../..
15637ed4 38
a27f4645 39# start.o should be first
15637ed4
RG
40OBJS = start.o table.o boot2.o boot.o asm.o bios.o io.o disk.o sys.o
41
a27f4645 42.SUFFIXES: .S .c .o
15637ed4 43
15637ed4 44.c.o:
a27f4645
RM
45 $(CC) $(CFLAGS) $(INC) -c $<
46
47.S.o:
48 $(CC) $(CFLAGS) -c $<
49
50boot: $(OBJS)
15637ed4
RG
51 $(LD) -N -T 0 -o boot $(OBJS) $(LIBS)
52 cp boot boot.sym
53 @strip boot
a27f4645 54 @sh ${.CURDIR}/rmaouthdr boot boot.tmp
15637ed4
RG
55 @mv -f boot.tmp boot
56 @ls -l boot
57
58biosboot: boot
59 dd if=boot of=biosboot count=1
60
61bootbios: boot
62 dd if=boot of=bootbios skip=1
63
64/usr/mdec/bootsd: bootbios
65 cp bootbios /usr/mdec/bootsd
66
67/usr/mdec/sdboot: biosboot
68 cp biosboot /usr/mdec/sdboot
69
70/usr/mdec/bootwd: /usr/mdec/bootsd
71 rm -f /usr/mdec/bootwd
72 ln /usr/mdec/bootsd /usr/mdec/bootwd
73
74/usr/mdec/wdboot: /usr/mdec/sdboot
75 rm -f /usr/mdec/wdboot
76 ln /usr/mdec/sdboot /usr/mdec/wdboot
77
78/usr/mdec/bootfd: /usr/mdec/bootsd
79 rm -f /usr/mdec/bootfd
80 ln /usr/mdec/bootsd /usr/mdec/bootfd
81
82/usr/mdec/fdboot: /usr/mdec/sdboot
83 rm -f /usr/mdec/fdboot
84 ln /usr/mdec/sdboot /usr/mdec/fdboot
85
86sd: /usr/mdec/bootsd /usr/mdec/sdboot
87wd: /usr/mdec/bootwd /usr/mdec/wdboot
88fd: /usr/mdec/bootfd /usr/mdec/fdboot
89
a27f4645 90all: biosboot bootbios
15637ed4 91
a27f4645
RM
92fd0:
93 dd if=boot of=biosboot count=1
94 dd if=boot of=bootbios skip=1
95 disklabel -r -w fd0 floppy bootflpy biosboot bootbios
96 rm biosboot bootbios
15637ed4 97
a27f4645 98install: wd sd fd
15637ed4 99
a27f4645 100clean cleandir:
15637ed4
RG
101 /bin/rm -f *.o *.d boot bootbios biosboot boot.sym
102
a27f4645 103.include <bsd.prog.mk>