Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -15,11 +15,24 @@ inherit allarch
do_configure[noexec] = "1"
do_compile[noexec] = "1"

# Possible values are "xz" and "zst".
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The code below also works with 'zstd' as a 3rd possible value....

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes, but it's not documented as supported in OE-Core.

FIRMWARE_COMPRESSION ?= ""

do_install() {
install -d ${D}${nonarch_base_libdir}/firmware/qcom/qcm6490
install -d ${D}${datadir}/doc/${BPN}

cp -r ${S}/usr/lib/firmware/CAMERA_ICP_170.elf ${D}${nonarch_base_libdir}/firmware/qcom/qcm6490/

case "${FIRMWARE_COMPRESSION}" in
zst | zstd)
zstd --compress --rm ${D}${nonarch_base_libdir}/firmware/qcom/qcm6490/CAMERA_ICP_170.elf
;;
xz)
xz --compress --check=crc32 ${D}${nonarch_base_libdir}/firmware/qcom/qcm6490/CAMERA_ICP_170.elf
;;
esac

install -m 0644 ${S}/usr/share/doc/${BPN}/NO.LOGIN.BINARY.LICENSE.QTI.pdf ${D}${datadir}/doc/${BPN}
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,17 +15,28 @@ inherit allarch
do_configure[noexec] = "1"
do_compile[noexec] = "1"

# Possible values are "xz" and "zst".
FIRMWARE_COMPRESSION ?= ""

do_install() {
install -d ${D}${nonarch_base_libdir}/firmware/qcom/sa8775p
install -d ${D}${nonarch_base_libdir}/firmware/qcom/qcs8300
install -d ${D}${datadir}/doc/${BPN}

cp -r ${S}/usr/lib/firmware/CAMERA_ICP.mbn ${D}${nonarch_base_libdir}/firmware/qcom/sa8775p/

case "${FIRMWARE_COMPRESSION}" in
zst | zstd)
zstd --compress --rm ${D}${nonarch_base_libdir}/firmware/qcom/sa8775p/CAMERA_ICP.mbn
;;
xz)
xz --compress --check=crc32 ${D}${nonarch_base_libdir}/firmware/qcom/sa8775p/CAMERA_ICP.mbn
;;
esac

install -m 0644 ${S}/usr/share/doc/${BPN}/NO.LOGIN.BINARY.LICENSE.QTI.pdf ${D}${datadir}/doc/${BPN}

# Link target should be relative to the link location
ln -sf ../sa8775p/CAMERA_ICP.mbn \
${D}${nonarch_base_libdir}/firmware/qcom/qcs8300/CAMERA_ICP.mbn
ln -srf ${D}${nonarch_base_libdir}/firmware/qcom/sa8775p/CAMERA_ICP.mbn* ${D}${nonarch_base_libdir}/firmware/qcom/qcs8300/
}

PACKAGES += "camxfirmware-monaco"
Expand Down
Loading