image_builder: split image_config.sh & standardization headers

This commit is contained in:
Artem Smirnov
2018-09-21 19:19:48 +03:00
parent d7e6629567
commit c828effd23
14 changed files with 247 additions and 156 deletions

View File

@@ -1,5 +1,11 @@
#! /usr/bin/env bash
#
# Script for image configure
# @urpylka Artem Smirnov
#
# Exit immidiately on non-zero result
set -e
export DEBIAN_FRONTEND=${DEBIAN_FRONTEND:='noninteractive'}
@@ -26,7 +32,7 @@ git clone ${TARGET_REPO} --single-branch --branch ${TARGET_REF} --depth 1 ${REPO
export IMAGE_VERSION="${TARGET_REF}_$(date '+%Y%m%d_%H%M%S')"
export IMAGE_PATH="$(pwd)/image/$(basename -s ".git" ${TARGET_REPO})_${IMAGE_VERSION}.img"
./image_config.sh get_image ${IMAGE_PATH} $(jq '.source_image' -r ${TARGET_CONFIG})
./get_new_image ${IMAGE_PATH} $(jq '.source_image' -r ${TARGET_CONFIG})
REGISTER=':arm:M::\x7fELF\x01\x01\x01\x00\x00\x00\x00\x00\x00\x00\x00\x00\x02\x00\x28\x00:\xff\xff\xff\xff\xff\xff\xff\x00\xff\xff\xff\xff\xff\xff\xff\xff\xfe\xff\xff\xff:/usr/bin/qemu-arm-static:'
if [[ $(arch) != 'armv7l' ]]; then