linux-firmware-visionfive2-imggpu: split IMG_GPU firmware blob

The firmware blob is architecture independent, move it to separate
package like all other firmware blobs to make rootfs creation simpler.
This commit is contained in:
Andreas Cord-Landwehr 2023-01-22 11:31:23 +01:00 committed by Khem Raj
parent 144f8b4270
commit 5af6643917
2 changed files with 29 additions and 5 deletions

View file

@ -3,10 +3,7 @@ LICENSE="CLOSED"
PROVIDES = "virtual/libgles2"
COMPATIBLE_MACHINE = "visionfive2"
SRC_URI = " \
git://github.com/starfive-tech/soft_3rdpart.git;protocol=https;lfs=1;branch=JH7110_VisionFive2_devel;rev=13975a3826bb98bd9a201780131262b6dd373452 \
"
require recipes-bsp/common/visionfive2-firmware.inc
inherit update-rc.d
S = "${WORKDIR}/git"
@ -29,6 +26,10 @@ do_install () {
install -d ${D}/usr/lib/pkgconfig/
cp -r ${D}/${IMG_GPU_POWERVR_VERSION}/staging/usr/lib/pkgconfig/* ${D}/usr/lib/pkgconfig/
# provided via separate arch-independent firmware package
rm -rf ${D}/lib/firmware
rmdir ${D}/lib
# cleanup unused
rm -rf ${D}/${IMG_GPU_POWERVR_VERSION}
}
@ -51,7 +52,7 @@ FILES:${PN}-firmware = " \
RDEPENDS:${PN} += " \
bash \
libdrm \
${PN}-firmware \
linux-firmware-visionfive2-imggpu \
"
RDEPENDS:${PN}-tools += " \

View file

@ -0,0 +1,23 @@
SUMMARY = "IMG GPU Firmware Binary Blob"
LICENSE = "CLOSED"
require recipes-bsp/common/visionfive2-firmware.inc
inherit allarch
S = "${WORKDIR}/git"
CLEANBROKEN = "1"
IMG_GPU_POWERVR_VERSION = "img-gpu-powervr-bin-1.17.6210866"
do_install () {
tar xz --no-same-owner -f ${S}/IMG_GPU/out/${IMG_GPU_POWERVR_VERSION}.tar.gz -C ${B}
install -d ${D}/lib/firmware
install -m 0644 ${IMG_GPU_POWERVR_VERSION}/target/lib/firmware/rgx.fw.36.50.54.182 ${D}/lib/firmware/
install -m 0644 ${IMG_GPU_POWERVR_VERSION}/target/lib/firmware/rgx.sh.36.50.54.182 ${D}/lib/firmware/
}
FILES:${PN} = "${nonarch_base_libdir}/firmware/"
INSANE_SKIP = "arch"