2017-12-09 21:51:48 +01:00
|
|
|
build_release() {
|
|
|
|
local RELEASE_DIR="$1"
|
2018-01-16 21:10:20 +01:00
|
|
|
|
|
|
|
local ROOTFS_SQFS=$(find $PKGDEPLOYDIR/rootfs-${CFG}/ -name '*.img')
|
2017-12-09 21:51:48 +01:00
|
|
|
|
|
|
|
local rootfs_image=$(basename $ROOTFS_SQFS)
|
|
|
|
local bootdir="$RELEASE_DIR/boot"
|
|
|
|
|
|
|
|
mkdir -p "$bootdir"
|
|
|
|
cp -r ${PKGDEPLOYDIR}/linux-rpi3/* "$bootdir"
|
|
|
|
cp -r ${PKGDEPLOYDIR}/boot-rpi3/* "$bootdir"
|
|
|
|
cp "$SCRIPTDIR/cfg/$CFG/cmdline.txt" "$bootdir"
|
|
|
|
cp "$ROOTFS_SQFS" "$bootdir"
|
|
|
|
sed -i 's/ROOTFSFILE/'$rootfs_image'/g' "$bootdir/cmdline.txt"
|
|
|
|
|
|
|
|
cp "$SCRIPTDIR/cfg/$CFG/install.sh" "$RELEASE_DIR"
|
|
|
|
cp "$SCRIPTDIR/cfg/$CFG/genimage.sh" "$RELEASE_DIR"
|
|
|
|
}
|