Fix to get the options for 'apt install' from build target

Desktop package needs to install the recommended packages for better UX,
such packages will be installed without '--no-install-recommends' in
'apt install' command.

Signed-off-by: Dongjin Kim <tobetter@gmail.com>
Change-Id: Ib024fa218b6d87d5df68f00e81584be87c4b7daa
This commit is contained in:
Dongjin Kim
2022-03-05 03:50:50 +09:00
parent 6f9ebd3395
commit 04c1aace65
2 changed files with 6 additions and 1 deletions

View File

@@ -7,7 +7,7 @@ locale-gen en_US.UTF-8
rm -f /etc/apt/sources.list.d/launchpad-hardkernel-ppa.list
apt update && apt upgrade -y
apt install -y --no-install-recommends \
apt install @@DEFAULT_APT_OPTIONS@@ \
odroid-base \
rsync \
@@DEFAULT_FLAVOUR_PACKAGES@@ \

View File

@@ -103,6 +103,10 @@ get_kernel_cmdline_defaults() {
echo ""
}
get_default_apt_options() {
echo "-y --no-install-recommends"
}
get_packages() {
[ -f ${1} ] && cat ${1} | awk -F '#|;' '{print $1}'
}
@@ -365,6 +369,7 @@ do_preinstall() {
sed -i \
-e "s,@@DEFAULT_BOARD@@,${BOARD},g" \
-e "s,@@DEFAULT_HOSTNAME@@,${DISTRO}-${FLAVOUR},g" \
-e "s,@@DEFAULT_APT_OPTIONS@@,$(get_default_apt_options ${FLAVOUR}),g" \
-e "s,@@DEFAULT_FLAVOUR_PACKAGES@@,$(get_flavour_packages),g" \
-e "s,@@DEFAULT_KERNEL_PACKAGE@@,$(get_kernel_package),g" \
-e "s,@@DEFAULT_BOOTSCRIPT_PACKAGE@@,$(get_bootscript_package),g" \