From c6e68bf577b7cbb0f158f2334c9530644d56d72f Mon Sep 17 00:00:00 2001 From: Ricardo Pardini Date: Sun, 26 Mar 2023 18:00:36 +0200 Subject: [PATCH] meson64: only `gxbb` and `gxl` require fetching repo `odroidc2-blobs`, split hook --- config/sources/families/include/meson64_common.inc | 14 +++++++------- config/sources/families/meson-gxbb.conf | 6 ++++++ config/sources/families/meson-gxl.conf | 6 +++++- 3 files changed, 18 insertions(+), 8 deletions(-) diff --git a/config/sources/families/include/meson64_common.inc b/config/sources/families/include/meson64_common.inc index 47e9a9daaf..1356f1e575 100644 --- a/config/sources/families/include/meson64_common.inc +++ b/config/sources/families/include/meson64_common.inc @@ -17,6 +17,13 @@ BOOTBRANCH="${BOOTBRANCH_BOARD:-"tag:v2022.07"}" BOOTPATCHDIR="${BOOTPATCHDIR:-"v2022.07"}" OVERLAY_PREFIX='meson' +# This is an extension method, put directly in meson64_common. A "built-in" extension if you will. +# Bring in LibreELEC's amlogic-boot-fip repo, which is the authoritative source for FIP blobs. +# To add FIP blobs for a new board, send a PR there, they're awesome. +function fetch_sources_tools__libreelec_amlogic_fip() { + fetch_from_repo "https://github.com/LibreELEC/amlogic-boot-fip" "amlogic-boot-fip" "branch:master" +} + # this family does not need it ATF_COMPILE="no" @@ -296,10 +303,3 @@ family_tweaks_bsp() { ;; esac } - -# This is an extension method, put directly in meson64_common. A "built-in" extension if you will. -# If used in more than one place, it could be moved to an extension: enable_extension "amlogic-fip-tools" -function fetch_sources_tools__amlogic_fip() { - fetch_from_repo "https://github.com/armbian/odroidc2-blobs" "odroidc2-blobs" "branch:master" - fetch_from_repo "https://github.com/LibreELEC/amlogic-boot-fip" "amlogic-boot-fip" "branch:master" -} diff --git a/config/sources/families/meson-gxbb.conf b/config/sources/families/meson-gxbb.conf index f8b2c13826..96d1ca428d 100644 --- a/config/sources/families/meson-gxbb.conf +++ b/config/sources/families/meson-gxbb.conf @@ -7,6 +7,12 @@ # https://github.com/armbian/build/ # source "${BASH_SOURCE%/*}/include/meson64_common.inc" + +# Fetch c2 blobs. Those are ancient, when first released by HK. Also used in meson-gxl.conf +function fetch_sources_tools__amlogic_odroidc2_blobs_fip() { + fetch_from_repo "https://github.com/armbian/odroidc2-blobs" "odroidc2-blobs" "branch:master" +} + if [[ $BOARD == odroidc2 ]]; then UBOOT_TARGET_MAP=";;$SRC/cache/sources/odroidc2-blobs/bl1.bin.hardkernel u-boot.bin" fi diff --git a/config/sources/families/meson-gxl.conf b/config/sources/families/meson-gxl.conf index 35ffbeebb1..52ec831403 100644 --- a/config/sources/families/meson-gxl.conf +++ b/config/sources/families/meson-gxl.conf @@ -8,6 +8,11 @@ # source "${BASH_SOURCE%/*}/include/meson64_common.inc" +# Fetch c2 blobs. Those are ancient, when first released by HK. Also used in meson-gxbb.conf +function fetch_sources_tools__amlogic_odroidc2_blobs_fip() { + fetch_from_repo "https://github.com/armbian/odroidc2-blobs" "odroidc2-blobs" "branch:master" +} + if [[ $BOARD == lafrite ]]; then UBOOT_TARGET_MAP="u-boot-dtb.img;;u-boot.bin:u-boot.bin u-boot-dtb.img" fi @@ -26,7 +31,6 @@ family_tweaks() { : } - uboot_custom_postprocess() { if [[ $BOARD == lepotato ]]; then uboot_gxl_postprocess $SRC/cache/sources/odroidc2-blobs/ gxl