4
4
# # define releases for tools
5
5
. conf
6
6
VERSIONINFO=` git describe --dirty`
7
- BUILDTYPE=$1
8
- BUILDIMG=LINUXPBA${1 } -${VERSIONINFO} .img
7
+ BUILDTYPE=Release
8
+ BUILDIMG=LINUXPBA${BUILDTYPE } -${VERSIONINFO} .img
9
9
if [ " $BUILDTYPE " == " Debug" ] || [ " $BUILDTYPE " == " Release" ] ; then
10
10
echo " Building " $BUILDTYPE " image"
11
11
else
@@ -14,23 +14,18 @@ if [ "$BUILDTYPE" == "Debug" ] || [ "$BUILDTYPE" == "Release" ] ; then
14
14
fi
15
15
16
16
# Start fresh
17
- sudo rm -rf LINUXPBA${BUILDTYPE} ; mkdir LINUXPBA${BUILDTYPE} ; cd LINUXPBA${BUILDTYPE}
18
17
# # check that everything is available
19
- [ -f ../scratch/${SYSLINUX} /bios/mbr/mbr.bin -a \
20
- -x ../scratch/${SYSLINUX} /bios/extlinux/extlinux -a \
21
- -f ../../LinuxPBA/dist/${BUILDTYPE} /GNU-Linux/linuxpba -a \
22
- -f ../../linux/CLI/dist/${BUILDTYPE} _i686/GNU-Linux/sedutil-cli -a \
23
- -f ../scratch/buildroot/PBA32/images/bzImage \
18
+ [ -f scratch/${SYSLINUX} /bios/mbr/mbr.bin -a \
19
+ -x scratch/${SYSLINUX} /bios/extlinux/extlinux -a \
20
+ -f scratch/buildroot/32bit/images/bzImage -a \
21
+ -f scratch/buildroot/32bit/images/rootfs.cpio.xz -a \
22
+ -x scratch/buildroot/32bit/target/sbin/linuxpba -a \
23
+ -x scratch/buildroot/32bit/target/sbin/sedutil-cli -a \
24
+ -f buildroot/syslinux.cfg \
24
25
] || { echo " prereqs are not available " ; exit 1; }
25
26
#
26
- # recreate the initrd file with the latest PBA
27
- mkdir ../scratch/buildroot/PBA32/overlay/sbin
28
- cp ../../LinuxPBA/dist/${BUILDTYPE} /GNU-Linux/linuxpba ../scratch/buildroot/PBA32/overlay/sbin/linuxpba
29
- cp ../../linux/CLI/dist/${BUILDTYPE} _i686/GNU-Linux/sedutil-cli ../scratch/buildroot/PBA32/overlay/sbin/sedutil-cli
30
- cd ../scratch/buildroot
31
- make all O=PBA32 2>&1 > PBA32.log
32
- cd ../../LINUXPBA${BUILDTYPE}
33
- dd if=/dev/zero of=${BUILDIMG} bs=1M count=8
27
+ sudo rm -rf LINUXPBA${BUILDTYPE} ; mkdir LINUXPBA${BUILDTYPE} ; cd LINUXPBA${BUILDTYPE}
28
+ dd if=/dev/zero of=${BUILDIMG} bs=1M count=32
34
29
(echo o; echo n; echo p; echo 1; echo" " ; echo " " ; echo " " ; echo a; echo 1; echo w) | fdisk ${BUILDIMG}
35
30
dd if=../scratch/${SYSLINUX} /bios/mbr/mbr.bin of=${BUILDIMG} count=1 conv=notrunc bs=512
36
31
LOOPDEV=` sudo losetup --show -f -o 1048576 ${BUILDIMG} `
@@ -40,8 +35,8 @@ sudo mount $LOOPDEV image
40
35
sudo chmod 777 image
41
36
sudo mkdir -p image/boot/extlinux
42
37
sudo ../scratch/${SYSLINUX} /bios/extlinux/extlinux --install image/boot/extlinux
43
- sudo cp ../scratch/buildroot/PBA32 /images/bzImage image/boot/extlinux/
44
- sudo cp ../scratch/buildroot/PBA32 /images/rootfs.cpio.xz image/boot/extlinux/
38
+ sudo cp ../scratch/buildroot/32bit /images/bzImage image/boot/extlinux/
39
+ sudo cp ../scratch/buildroot/32bit /images/rootfs.cpio.xz image/boot/extlinux/
45
40
sudo cp ../buildroot/syslinux.cfg image/boot/extlinux/extlinux.conf
46
41
sudo umount image
47
42
sudo losetup -d $LOOPDEV
0 commit comments