mkfile 3.0 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200
  1. objtype=386
  2. </$objtype/mkfile
  3. BIN=/386
  4. TARG=\
  5. 9load\
  6. 9pxeload\
  7. 9loadlite\
  8. 9loaddebug\
  9. 9loadlitedebug\
  10. ld.com\
  11. mbr\
  12. pbs\
  13. pbslba\
  14. CORE=\
  15. alarm.$O\
  16. cga.$O\
  17. clock.$O\
  18. console.$O\
  19. dosboot.$O\
  20. devfloppy.$O\
  21. dma.$O\
  22. fs.$O\
  23. ilock.$O\
  24. kbd.$O\
  25. kfsboot.$O\
  26. print.$O\
  27. queue.$O\
  28. trap.$O\
  29. LOAD=\
  30. 8250.$O\
  31. apm.$O\
  32. boot.$O\
  33. devpccard.$O\
  34. conf.$O\
  35. devi82365.$O\
  36. devsd.$O\
  37. inflate.$O\
  38. load.$O\
  39. memory.$O\
  40. part.$O\
  41. pci.$O\
  42. sdata.$O\
  43. sdmylex.$O\
  44. sd53c8xx.$O\
  45. sdscsi.$O\
  46. ETHER=\
  47. bootp.$O\
  48. ether.$O\
  49. ether2114x.$O\
  50. ether2000.$O\
  51. ether589.$O\
  52. ether79c970.$O\
  53. ether8003.$O\
  54. ether8139.$O\
  55. ether8169.$O\
  56. ether82557.$O\
  57. ether83815.$O\
  58. ether8390.$O\
  59. etherec2t.$O\
  60. etherelnk3.$O\
  61. etherigbe.$O\
  62. ethermii.$O\
  63. etherrhine.$O\
  64. BCOM=\
  65. bcom.$O\
  66. bootld.$O\
  67. devsd.$O\
  68. memory.$O\
  69. part.$O\
  70. pci.$O\
  71. sdata.$O\
  72. sdscsi.$O\
  73. HFILES=\
  74. lib.h\
  75. mem.h\
  76. dat.h\
  77. fns.h\
  78. io.h\
  79. CFLAGS=-FVw -I.
  80. all:V: $TARG
  81. 9load: l.$O $CORE $LOAD $ETHER
  82. $LD -o $target -H3 -T0x80010000 -l $prereq -lflate -lc -lip
  83. ls -l $target
  84. 9pxeload: lpxe.$O $CORE $LOAD $ETHER
  85. $LD -o $target -H3 -T0x80007C00 -l $prereq -lflate -lc -lip
  86. ls -l $target
  87. 9loaddebug: l.$O $CORE $LOAD $ETHER
  88. $LD -o $target -T0x80010000 -l $prereq -lflate -lc -lip
  89. ls -l $target
  90. # acid $target
  91. # map({"text", 0x80010000, 0x80090000, 0x00000020})
  92. 9loadlite: l.$O $CORE $LOAD noether.$O
  93. $LD -o $target -H3 -T0x80010000 -l $prereq -lflate -lc
  94. ls -l $target
  95. 9loadlitedebug: l.$O $CORE $LOAD noether.$O
  96. $LD -o $target -T0x80010000 -l $prereq -lflate -lc
  97. ls -l $target
  98. # acid $target
  99. # map({"text", 0x80010000, 0x80090000, 0x00000020})
  100. ld.com: ld.$O $CORE $BCOM
  101. $LD -o $target -H3 -T0x80080100 -l $prereq -lc
  102. ls -l $target
  103. lddebug: ld.$O $CORE $BCOM
  104. $LD -o $target -T0x80080100 -l $prereq -lc
  105. ls -l $target
  106. # acid $target
  107. # map({"text", 0x80080100, 0x800B0000, 0x00000020})
  108. ld.$O: l.s
  109. $AS -DDOTCOM -o $target l.s
  110. lpxe.$O: l.s
  111. $AS -DPXE -o $target l.s
  112. %.$O: %.s
  113. $AS $stem.s
  114. %.$O: %.c
  115. $CC $CFLAGS $stem.c
  116. %.$O: $HFILES
  117. l.$O pbs.$O pbslba.$O mbr.$O: x16.h
  118. clock.$O floppy.$O trap.$O: ureg.h
  119. bcom.$O conf.$O devfloppy.$O devsd.$O dosboot.$O fs.$O \
  120. kfsboot.$O load.$O part.$O: dosfs.h fs.h kfs.h
  121. ether.$O etherelnk3.$O: etherif.h
  122. devsd.$O part.$O sdata.$O sdscsi.$O: sd.h
  123. bootp.$O: ip.h
  124. mbr: mbr.$O
  125. $LD -o $target -H3 -T0x0600 -l $prereq
  126. ls -l $target
  127. pbs&: pbs%.$O
  128. $LD -o $target -H3 -T0x7C00 -l $prereq
  129. ls -l $target
  130. pbs&.debug: pbs%.$O
  131. $LD -o $target -T0x7C00 -l $prereq
  132. ls -l $target
  133. # acid $target
  134. # map({"text", 0x7C00, 0x7E00, 0x00000020})
  135. clean:
  136. rm -f *.[$OS] [$OS].out y.tab.? y.debug y.output $TARG 9loaddebug lddebug
  137. install:V:
  138. for (i in $TARG)
  139. mk $MKFLAGS $i.install
  140. %.install:V: $BIN/%
  141. #import lookout / /n/lookout
  142. #cp $prereq /n/lookout/$prereq
  143. $BIN/%: %
  144. cp $stem $BIN/$stem
  145. UPDATE=\
  146. mkfile\
  147. ${CORE:%.$O=%.c}\
  148. ${LOAD:%.$O=%.c}\
  149. ${BCOM:%.$O=%.c}\
  150. ${ETHER:%.$O=%.c}\
  151. $HFILES\
  152. l.s\
  153. noether.c\
  154. pbs.s\
  155. pbslba.s\
  156. mbr.s\
  157. x16.h\
  158. ureg.h\
  159. dosfs.h\
  160. fs.h\
  161. kfs.h\
  162. etherif.h\
  163. sd.h\
  164. ip.h\
  165. devfloppy.h\
  166. ${TARG:%=/386/%}\
  167. update:V:
  168. update $UPDATEFLAGS $UPDATE