Restructure
20
build.sh
@@ -144,7 +144,7 @@ run_stage() {
|
||||
unmount "${WORK_DIR}/${STAGE}"
|
||||
|
||||
if [ ! -f SKIP_IMAGES ]; then
|
||||
if [ -f "${STAGE_DIR}/EXPORT_IMAGE" ] || [ -f "${STAGE_DIR}/EXPORT_ISO" ] || [ -f "${STAGE_DIR}/EXPORT_SQUASHFS" ]; then
|
||||
if [ -f "${STAGE_DIR}/EXPORT_IMG" ] || [ -f "${STAGE_DIR}/EXPORT_ISO" ] || [ -f "${STAGE_DIR}/EXPORT_SQUASHFS" ] || [ -f "${STAGE_DIR}/EXPORT_NOOBS" ]; then
|
||||
EXPORT_DIRS="${EXPORT_DIRS} ${STAGE_DIR}"
|
||||
fi
|
||||
fi
|
||||
@@ -184,7 +184,7 @@ term() {
|
||||
log "Build finished"
|
||||
fi
|
||||
unmount "${STAGE_WORK_DIR}"
|
||||
if [ "$STAGE" = "export-image" ]; then
|
||||
if [ "$STAGE" = "exports/img" ]; then
|
||||
for img in "${STAGE_WORK_DIR}/"*.img; do
|
||||
unmount_image "$img"
|
||||
done
|
||||
@@ -332,11 +332,7 @@ log "Begin ${BASE_DIR}"
|
||||
STAGE_LIST=${STAGE_LIST:-${BASE_DIR}/stage*}
|
||||
export STAGE_LIST
|
||||
|
||||
EXPORT_CONFIG_DIR=$(realpath "${EXPORT_CONFIG_DIR:-"${BASE_DIR}/export-image"}")
|
||||
if [ ! -d "${EXPORT_CONFIG_DIR}" ]; then
|
||||
echo "EXPORT_CONFIG_DIR invalid: ${EXPORT_CONFIG_DIR} does not exist"
|
||||
exit 1
|
||||
fi
|
||||
EXPORT_CONFIG_DIR="${EXPORT_CONFIG_DIR:-"${BASE_DIR}/exports"}"
|
||||
export EXPORT_CONFIG_DIR
|
||||
|
||||
for STAGE_DIR in $STAGE_LIST; do
|
||||
@@ -351,18 +347,18 @@ for EXPORT_DIR in ${EXPORT_DIRS}; do
|
||||
STAGE_DIR=${EXPORT_CONFIG_DIR}
|
||||
# shellcheck source=/dev/null
|
||||
source "${EXPORT_DIR}/EXPORT_ISO"
|
||||
STAGE_DIR="${BASE_DIR}/export-iso"
|
||||
STAGE_DIR="${BASE_DIR}/exports/iso"
|
||||
run_stage
|
||||
fi
|
||||
if [ -e "${EXPORT_DIR}/EXPORT_IMAGE" ]; then
|
||||
if [ -e "${EXPORT_DIR}/EXPORT_IMG" ]; then
|
||||
STAGE_DIR=${EXPORT_CONFIG_DIR}
|
||||
# shellcheck source=/dev/null
|
||||
source "${EXPORT_DIR}/EXPORT_IMAGE"
|
||||
STAGE_DIR="${BASE_DIR}/export-image"
|
||||
source "${EXPORT_DIR}/EXPORT_IMG"
|
||||
STAGE_DIR="${BASE_DIR}/exports/img"
|
||||
run_stage
|
||||
fi
|
||||
if [ -e "${EXPORT_DIR}/EXPORT_SQUASHFS" ]; then
|
||||
STAGE_DIR="${BASE_DIR}/export-squashfs"
|
||||
STAGE_DIR="${BASE_DIR}/exports/squashfs"
|
||||
run_stage
|
||||
fi
|
||||
if [ "${USE_QEMU}" != "1" ]; then
|
||||
|
||||
0
export-image/00-allow-rerun/00-run.sh → exports/img/00-allow-rerun/00-run.sh
Executable file → Normal file
0
export-image/01-set-sources/01-run.sh → exports/img/01-set-sources/01-run.sh
Executable file → Normal file
0
export-image/02-network/01-run.sh → exports/img/02-network/01-run.sh
Executable file → Normal file
0
export-image/03-set-partuuid/00-run.sh → exports/img/03-set-partuuid/00-run.sh
Executable file → Normal file
0
export-image/04-finalise/01-run.sh → exports/img/04-finalise/01-run.sh
Executable file → Normal file
0
export-image/prerun.sh → exports/img/prerun.sh
Executable file → Normal file
0
export-iso/00-allow-rerun/00-run.sh → exports/iso/00-allow-rerun/00-run.sh
Executable file → Normal file
0
export-iso/01-set-sources/01-run.sh → exports/iso/01-set-sources/01-run.sh
Executable file → Normal file
0
export-iso/02-network/01-run.sh → exports/iso/02-network/01-run.sh
Executable file → Normal file
0
export-iso/03-finalise/01-run.sh → exports/iso/03-finalise/01-run.sh
Executable file → Normal file
0
export-iso/prerun.sh → exports/iso/prerun.sh
Executable file → Normal file
0
export-noobs/00-release/00-run.sh → exports/noobs/00-release/00-run.sh
Executable file → Normal file
|
Before Width: | Height: | Size: 1.7 KiB After Width: | Height: | Size: 1.7 KiB |
|
Before Width: | Height: | Size: 50 KiB After Width: | Height: | Size: 50 KiB |
|
Before Width: | Height: | Size: 48 KiB After Width: | Height: | Size: 48 KiB |
|
Before Width: | Height: | Size: 104 KiB After Width: | Height: | Size: 104 KiB |
|
Before Width: | Height: | Size: 93 KiB After Width: | Height: | Size: 93 KiB |
|
Before Width: | Height: | Size: 79 KiB After Width: | Height: | Size: 79 KiB |
|
Before Width: | Height: | Size: 65 KiB After Width: | Height: | Size: 65 KiB |
|
Before Width: | Height: | Size: 104 KiB After Width: | Height: | Size: 104 KiB |