4 # allegedly u-boot uses the bottom 8MB (up to 0x800000)
12 DEVS=`{rc ../port/mkdevlist $CONF}
66 /$objtype/lib/libmemlayer.a\
67 /$objtype/lib/libmemdraw.a\
68 /$objtype/lib/libdraw.a\
69 /$objtype/lib/libip.a\
70 /$objtype/lib/libsec.a\
72 /$objtype/lib/libmp.a\
73 /$objtype/lib/libfis.a\
77 $p$CONF:DQ: $CONF.c $OBJ $LIB mkfile
78 $CC $CFLAGS '-DKERNDATE='`{date -n} $CONF.c
79 echo '# linking raw kernel'
80 # sleep 1 # avoid relinking later
81 $LD -o $target -H0 -R4096 -T$loadaddr -l $OBJ $CONF.$O $LIB
83 s$p$CONF:DQ: $CONF.$O $OBJ $LIB
84 echo '# linking kernel with symbols'
85 # sleep 1 # avoid relinking later
86 $LD -o $target -R4096 -T$loadaddr -l $OBJ $CONF.$O $LIB
90 gzip -9 <$p$CONF >$target
94 install:V: /$objtype/$p$CONF
96 install-in-flash:V: /$objtype/$p$CONF paqdisk
98 echo erase all >/dev/flash/kernelctl
99 cp /$objtype/$p$CONF /dev/flash/kernel
100 echo erase all >/dev/flash/plan9ctl
101 cp paqdisk /dev/flash/plan9
103 /$objtype/$p$CONF:D: $p$CONF s$p$CONF
104 cp -x $p$CONF s$p$CONF /$objtype &
105 { 9fs lookout && cp -x $p$CONF s$p$CONF /n/lookout/$objtype } &
106 # { 9fs piestand && cp -x $p$CONF s$p$CONF /n/piestand/$objtype } &
114 disk/mkfs -d . /sys/lib/sysconfig/proto/armpaqproto
115 mkpaqfs -o ../paqdisk
120 <|../port/mkbootrules $CONF
122 # CFLAGS= -I. -I../port $CFLAGS # hack to compile private sysproc.c (e.g.)
124 arch.$O clock.$O fpiarm.$O main.$O mmu.$O screen.$O sdscsi.$O syscall.$O \
125 trap.$O: /$objtype/include/ureg.h
127 archkw.$O devether.$O ether1116.$O ethermii.$O: \
128 etherif.h ethermii.h ../port/netif.h
129 archkw.$O devflash.$O flashkw.$O: ../port/flashif.h
130 fpi.$O fpiarm.$O fpimem.$O: fpi.h
131 l.$O lexception.$O lproc.$O mmu.$O: arm.s arm.h mem.h
132 main.$O: errstr.h init.h reboot.h
134 devusb.$O: ../port/usb.h
135 usbehci.$O usbohci.$O usbuhci.$O: ../port/usb.h usbehci.h
137 init.h:D: ../port/initcode.c init9.s
138 $CC ../port/initcode.c
140 $LD -l -R1 -s -o init.out init9.$O initcode.$O /$objtype/lib/libc.a
141 {echo 'uchar initcode[]={'
143 sed -e 's/^[0-9a-f]+ //' -e 's/ ([0-9a-f][0-9a-f])/0x\1,/g'
146 reboot.h:D: rebootcode.s arm.s arm.h mem.h
148 # -lc is only for memmove. -T arg is PADDR(REBOOTADDR)
149 $LD -l -a -s -T0x100 -R4 -o reboot.out rebootcode.$O -lc >reboot.list
150 {echo 'uchar rebootcode[]={'
152 sed -e '1,2d' -e 's/^[0-9a-f]+ //' -e 's/ ([0-9a-f][0-9a-f])/0x\1,/g'
153 echo '};'} > reboot.h
154 errstr.h:D: ../port/mkerrstr ../port/error.h
155 rc ../port/mkerrstr > errstr.h
158 rm -rf $p$CONF s$p$CONF armpaq paqdisk $CONF.c boot$CONF.c ../boot/libboot.a5