0.00-050613_Makefile

 1 # Makefile for the simple example kernel.
 2 AS86    =as86 -0 -a
 3 LD86    =ld86 -0
 4 AS    =gas
 5 LD    =gld
 6 LDFLAGS    =-s -x -M
 7 
 8 all:    Image
 9 
10 Image: boot system
11     dd bs=32 if=boot of=Image skip=1
12     dd bs=512 if=system of=Image skip=2 seek=1
13     sync
14 
15 disk: Image
16     dd bs=8192 if=Image of=/dev/fd0
17     sync;sync;sync
18 
19 head.o: head.s
20 
21 system:    head.o 
22     $(LD) $(LDFLAGS) head.o  -o system > System.map
23 
24 boot:    boot.s
25     $(AS86) -o boot.o boot.s
26     $(LD86) -s -o boot boot.o
27 
28 clean:
29     rm -f Image System.map core boot *.o system
原文地址:https://www.cnblogs.com/CodeSkill/p/5086060.html