diff options
author | Cem Keylan <cem@ckyln.com> | 2020-05-18 11:57:59 +0300 |
---|---|---|
committer | Cem Keylan <cem@ckyln.com> | 2020-05-18 11:57:59 +0300 |
commit | e4a2415c13b9fa34a9c7b80d19120bfb1caa3319 (patch) | |
tree | 6bea50c410b26657725c07e1da35f55e81cff1f5 | |
parent | 7a75d6d44e194540de84cabadedfa3c9a31f226f (diff) | |
download | mkrootfs-e4a2415c13b9fa34a9c7b80d19120bfb1caa3319.tar.gz |
use kiss as a library
-rwxr-xr-x | mkrootfs.sh | 20 |
1 files changed, 15 insertions, 5 deletions
diff --git a/mkrootfs.sh b/mkrootfs.sh index 453e005..134b46a 100755 --- a/mkrootfs.sh +++ b/mkrootfs.sh @@ -4,6 +4,12 @@ # Bootstrapper for Carbs Linux # See LICENSE file for copyright and license details +# Source kiss as a library +kissloc=$(command -v kiss) +kissln=$(wc -l < "$kissloc") +sed "${kissln}d" "$kissloc" > .kisslib +. ./.kisslib + # Functions msg() { printf '\033[1;35m-> \033[m%s\n' "$@" ;} @@ -26,23 +32,27 @@ BASEDIR="$PWD" [ "$PKGS" ] || die "You must set PKGS variable to continue the bootstrapper" [ "$MNTDIR" ] || die "You must specify fakeroot location 'MNTDIR' in order to continue the bootstrapper" +# Word splitting is intentional here +# shellcheck disable=2086 +pkg_order $PKGS # Print variables from the configuration file cat <<EOF Here are the configuration values: -MNTDIR = $MNTDIR +MNTDIR = $MNTDIR Build Options -CFLAGS = $CFLAGS -CXXFLAGS = $CXXFLAGS +CFLAGS = $CFLAGS +CXXFLAGS = $CXXFLAGS MAKEFLAGS = $MAKEFLAGS Repository and package options -REPO = $REPO +REPO = $REPO REPOSITORY PATH = $HOST_REPO_PATH -PKGS = $PKGS +PKGS = $PKGS +ORDER = $order EOF |