mkfile 3.5 KB

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