command: add new build flag '--customos'

Assuming the first argument will fail when multiple arguments are given
or other argument is at first place to build for a custom OS project.
Therefore use '--customos'...

Signed-off-by: Dongjin Kim <tobetter@gmail.com>
Change-Id: I14eaec23ed06790053522e33c1e5d7215c9566b0
This commit is contained in:
Dongjin Kim
2022-04-13 03:29:41 +09:00
parent aee229b6a9
commit f962680bfb

View File

@@ -24,8 +24,6 @@ usage() {
exit 1
}
[ -z "$1" ] || CUSTOMOS=${1}
for opt in "$@"; do
case $opt in
--help)
@@ -47,6 +45,8 @@ for opt in "$@"; do
--internal) opt_internal=true;;
--keep-builddir)
opt_keep_builddir=true;;
--custom=*)
opt_custom="${opt#*=}";;
esac
done
@@ -58,6 +58,8 @@ download_dir="/var/cache/odroid-stamper/downloads"
. ${TOPDIR}/default
. ${TOPDIR}/functions
[ -z ${opt_custom} ] || CUSTOMOS=${opt_custom}
if [ -f ${TOPDIR}/custom/${CUSTOMOS}/config ]; then
cp -f ${TOPDIR}/custom/${CUSTOMOS}/config ${DEFAULT_CONFIG} || exit 1
RUN_MENU=false