From a2d756dacef718773b7dc8e9a8ec80da42164795 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Igor=20Pe=C4=8Dovnik?= Date: Fri, 17 Jul 2020 18:29:24 +0200 Subject: [PATCH] Add support for two dedicated package lists for BOARD and FAMILY (#2097) * Add support for two dedicated package lists for BOARD and FAMILY - PACKAGE_LIST_BOARD - PACKAGE_LIST_FAMILY * Add some info about recently added features to the README.md --- config/boards/README.md | 2 ++ config/boards/cubox-i.conf | 1 + config/boards/olimex-som204-a20.csc | 1 + config/sources/families/imx6.conf | 5 ----- config/sources/families/sun7i.conf | 5 ----- lib/build-all-ng.sh | 2 +- lib/distributions.sh | 10 ++++++++++ 7 files changed, 15 insertions(+), 11 deletions(-) diff --git a/config/boards/README.md b/config/boards/README.md index f318368d0d..b657f8c7e5 100644 --- a/config/boards/README.md +++ b/config/boards/README.md @@ -5,6 +5,7 @@ | BOARDFAMILY | [sun8i, sun7i, rockchip64](../sources) | | BOOTCONFIG | name of u-boot config | | BOOTSIZE | size of a separate boot partition in Mib | +| BOOT_LOGO | yes/desktop enable armbian boot logo during booting | | IMAGE_PARTITION_TABLE | "msdos" (default) or "gpt" (boot loader must supports it) | | BOOTFS_TYPE | boot partition type: ext4, fat | | DEFAULT_OVERLAYS | usbhost1 usbhost2 ... | @@ -20,6 +21,7 @@ | KERNEL_TARGET | legacy,current,dev | | FULL_DESKTOP | yes/no = install Office, Thunderbird, ... | | DESKTOP_AUTOLOGIN | yes/no | +| PACKAGE_LIST_BOARD | space delimited packages to be installed on this boards | | PACKAGE_LIST_DESKTOP_BOARD | space delimited packages to be installed on this boards desktop build | diff --git a/config/boards/cubox-i.conf b/config/boards/cubox-i.conf index fac2a71e3c..584651d9ef 100644 --- a/config/boards/cubox-i.conf +++ b/config/boards/cubox-i.conf @@ -5,3 +5,4 @@ BOOTCONFIG="mx6cuboxi_defconfig" KERNEL_TARGET="current" FULL_DESKTOP="yes" BOOT_LOGO="desktop" +PACKAGE_LIST_BOARD="rfkill bluetooth bluez bluez-tools" diff --git a/config/boards/olimex-som204-a20.csc b/config/boards/olimex-som204-a20.csc index 2feb593d85..b1b2082e18 100644 --- a/config/boards/olimex-som204-a20.csc +++ b/config/boards/olimex-som204-a20.csc @@ -6,3 +6,4 @@ MODULES_CURRENT="bonding g_serial gpio-ir-tx r8723bs" MODULES_DEV="bonding g_serial gpio-ir-tx r8723bs " SERIALCON="ttyS0,ttyGS0" KERNEL_TARGET="current,dev" +PACKAGE_LIST_DESKTOP_BOARD="xfce4-power-manager xinput-calibrator" diff --git a/config/sources/families/imx6.conf b/config/sources/families/imx6.conf index 2afc5decd7..ff9160034e 100644 --- a/config/sources/families/imx6.conf +++ b/config/sources/families/imx6.conf @@ -47,11 +47,6 @@ write_uboot_platform() dd if=$1/u-boot.img.sdhc of=$2 bs=1K seek=69 status=noxfer > /dev/null 2>&1 } -family_tweaks() -{ - chroot $SDCARD /bin/bash -c "apt-get -y -qq install rfkill bluetooth bluez bluez-tools" -} - family_tweaks_bsp() { install -m 644 $SRC/packages/bsp/cubox/99-hdmi_fb0.conf $destination/etc/X11/xorg.conf.d/99-hdmi_fb0.conf diff --git a/config/sources/families/sun7i.conf b/config/sources/families/sun7i.conf index 1986d076bb..db8800e8d4 100644 --- a/config/sources/families/sun7i.conf +++ b/config/sources/families/sun7i.conf @@ -3,11 +3,6 @@ OVERLAY_PREFIX='sun7i-a20' [[ -z $CPUMIN ]] && CPUMIN=480000 [[ -z $CPUMAX ]] && CPUMAX=1010000 -family_tweaks_s() -{ - [[ $BOARD == olimex-som204-20 && $BUILD_DESKTOP == yes ]] && chroot $SDCARD /bin/bash -c "apt-get -y -qq install xinput-calibrator >/dev/null 2>&1" -} - family_tweaks_bsp_s() { if [[ $BOARD == olimex-som204-a20 ]]; then diff --git a/lib/build-all-ng.sh b/lib/build-all-ng.sh index 0126421a06..66ad4103c2 100644 --- a/lib/build-all-ng.sh +++ b/lib/build-all-ng.sh @@ -57,7 +57,7 @@ unset LINUXFAMILY LINUXCONFIG KERNELDIR KERNELSOURCE KERNELBRANCH BOOTDIR BOOTSO CRYPTROOT_SSH_UNLOCK_KEY_NAME ROOT_MAPPER NETWORK HDMI USB WIRELESS ARMBIANMONITOR FORCE_BOOTSCRIPT_UPDATE \ UBOOT_TOOLCHAIN2 toolchain2 BUILD_REPOSITORY_URL BUILD_REPOSITORY_COMMIT BUILD_TARGET HOST BUILD_IMAGE \ DEB_STORAGE REPO_STORAGE REPO_CONFIG REPOSITORY_UPDATE PACKAGE_LIST_RELEASE LOCAL_MIRROR COMPILE_ATF \ - PACKAGE_LIST_DESKTOP_BOARD PACKAGE_LIST_DESKTOP_FAMILY ATF_COMPILE ATFPATCHDIR OFFSET BOOTSOURCEDIR BOOT_USE_BLOBS \ + PACKAGE_LIST_BOARD PACKAGE_LIST_FAMILY PACKAGE_LIST_DESKTOP_BOARD PACKAGE_LIST_DESKTOP_FAMILY ATF_COMPILE ATFPATCHDIR OFFSET BOOTSOURCEDIR BOOT_USE_BLOBS \ BOOT_SOC DDR_BLOB MINILOADER_BLOB BL31_BLOB BOOT_RK3328_USE_AYUFAN_ATF BOOT_USE_BLOBS BOOT_RK3399_LEGACY_HYBRID \ BOOT_USE_MAINLINE_ATF BOOT_USE_TPL_SPL_BLOB OFFLINE_WORK IMAGE_PARTITION_TABLE BOOT_LOGO } diff --git a/lib/distributions.sh b/lib/distributions.sh index 9437c32e7b..925f9e2e64 100644 --- a/lib/distributions.sh +++ b/lib/distributions.sh @@ -210,6 +210,16 @@ install_common() ff02::2 ip6-allrouters EOF + # install family packages + if [[ -n ${PACKAGE_LIST_FAMILY} ]]; then + chroot "${SDCARD}" /bin/bash -c "DEBIAN_FRONTEND=noninteractive apt -yqq --no-install-recommends install $PACKAGE_LIST_FAMILY" >> "${DEST}"/debug/install.log + fi + + # install family packages + if [[ -n ${PACKAGE_LIST_BOARD} ]]; then + chroot "${SDCARD}" /bin/bash -c "DEBIAN_FRONTEND=noninteractive apt -yqq --no-install-recommends install $PACKAGE_LIST_BOARD" >> "${DEST}"/debug/install.log + fi + # install u-boot if [[ "${REPOSITORY_INSTALL}" != *u-boot* ]]; then UBOOT_VER=$(dpkg --info "${DEB_STORAGE}/${CHOSEN_UBOOT}_${REVISION}_${ARCH}.deb" | grep Descr | awk '{print $(NF)}')