summaryrefslogtreecommitdiff
path: root/recipes-bsp
diff options
context:
space:
mode:
Diffstat (limited to 'recipes-bsp')
-rw-r--r--recipes-bsp/binary-drivers/cudatoolkit6.5_21.5.0.bb41
-rwxr-xr-xrecipes-bsp/binary-drivers/linux-driver-package/nv87
-rw-r--r--recipes-bsp/binary-drivers/linux-driver-package/nv.service18
-rwxr-xr-xrecipes-bsp/binary-drivers/linux-driver-package/nvfb25
-rw-r--r--recipes-bsp/binary-drivers/linux-driver-package/nvfb.service17
-rw-r--r--recipes-bsp/binary-drivers/linux-driver-package/tegra_xusb_firmwarebin0 -> 124416 bytes
-rw-r--r--recipes-bsp/binary-drivers/linux-driver-package/xorg.conf22
-rw-r--r--recipes-bsp/binary-drivers/linux-driver-package/xorg.conf.add11
-rw-r--r--recipes-bsp/binary-drivers/linux-driver-package_21.%.bbappend99
-rwxr-xr-xrecipes-bsp/binary-drivers/linux-driver-package_21.7.0.bb102
-rw-r--r--recipes-bsp/binary-drivers/opencv4tegra_21.5.0.bb45
11 files changed, 467 insertions, 0 deletions
diff --git a/recipes-bsp/binary-drivers/cudatoolkit6.5_21.5.0.bb b/recipes-bsp/binary-drivers/cudatoolkit6.5_21.5.0.bb
new file mode 100644
index 0000000..6bb8657
--- /dev/null
+++ b/recipes-bsp/binary-drivers/cudatoolkit6.5_21.5.0.bb
@@ -0,0 +1,41 @@
+DESCRIPTION = "NVIDIA CUDA 6.5 Toolkit for L4T Rel 21.x Packages"
+HOMEPAGE = "https://developer.nvidia.com/"
+LICENSE = "Proprietary"
+
+SRC_URI = "http://developer.download.nvidia.com/devzone/devcenter/mobile/jetpack_l4t/005/linux-x64/cuda-repo-l4t-r21.5-6-5-local_6.5-53_armhf.deb"
+
+LIC_FILES_CHKSUM = "file://usr/share/doc/cuda-repo-l4t-r21.5-6-5-local/copyright;md5=f87877410d6936081b0b8ddd124ca96d"
+
+SRC_URI[md5sum] = "93b5c6592292565c389c46a16b4cbf5d"
+SRC_URI[sha256sum] = "4739c63e16b9a169f988c2b8f175c0182fa118833b49950fe72fe8c039ba1359"
+
+DEPENDS = "dpkg-native"
+
+INSANE_SKIP_${PN} = "ldflags"
+
+PACKAGE_ARCH = "${MACHINE_ARCH}"
+
+S = "${WORKDIR}/cuda6.5"
+
+INSANE_SKIP_${PN}-dev = "ldflags"
+
+FILES_${PN} = "${datadir}/lintian/* \
+ ${base_prefix}/usr/local/cuda-6.5/* "
+
+INHIBIT_PACKAGE_STRIP = "1"
+
+INSANE_SKIP_${PN} += "already-stripped dev-so libdir"
+
+python do_unpack () {
+ locals = d.getVar('WORKDIR', True)
+ s = d.getVar('S', True)
+ d.setVar('WORKDIR', s)
+ d.setVar('S', s)
+ bb.build.exec_func('base_do_unpack', d)
+ d.setVar('WORKDIR', locals)
+}
+
+do_install () {
+ cp -r ${WORKDIR}/cuda6.5/usr ${D}
+ dpkg -x ${WORKDIR}/cuda6.5/var/cuda-repo-6-5-local/cuda-cudart-6-5_6.5-53_armhf.deb ${D}
+}
diff --git a/recipes-bsp/binary-drivers/linux-driver-package/nv b/recipes-bsp/binary-drivers/linux-driver-package/nv
new file mode 100755
index 0000000..2221688
--- /dev/null
+++ b/recipes-bsp/binary-drivers/linux-driver-package/nv
@@ -0,0 +1,87 @@
+#!/bin/sh
+#"NVIDIA specific init script"
+
+nvexec() {
+ # power state
+ if [ -e /sys/power/state ]; then
+ chmod 0666 /sys/power/state
+ fi
+
+ # Set minimum cpu freq.
+ if [ -e /sys/devices/soc0/family ]; then
+ SOCFAMILY="`cat /sys/devices/soc0/family`"
+ fi
+
+ if [ "$SOCFAMILY" = "Tegra13" ] &&
+ [ -e /sys/devices/system/cpu/cpu0/cpufreq/scaling_min_freq ]; then
+ sudo bash -c "echo -n 510000 > /sys/devices/system/cpu/cpu0/cpufreq/scaling_min_freq"
+ fi
+
+ # CPU hotplugging
+ if [ -d /sys/devices/system/cpu/cpuquiet/tegra_cpuquiet ] ; then
+ echo 500 > /sys/devices/system/cpu/cpuquiet/tegra_cpuquiet/down_delay
+ echo 1 > /sys/devices/system/cpu/cpuquiet/tegra_cpuquiet/enable
+ elif [ -w /sys/module/cpu_tegra3/parameters/auto_hotplug ] ; then
+ # compatibility for prior kernels without cpuquiet support
+ echo 1 > /sys/module/cpu_tegra3/parameters/auto_hotplug
+ fi
+
+ # lp2 idle state
+ if [ -e /sys/module/cpuidle/parameters/power_down_in_idle ] ; then
+ echo "Y" > /sys/module/cpuidle/parameters/power_down_in_idle
+ elif [ -e /sys/module/cpuidle/parameters/lp2_in_idle ] ; then
+ # compatibility for prior kernels
+ echo "Y" > /sys/module/cpuidle/parameters/lp2_in_idle
+ fi
+
+ #FIXME remove once kernel CL merges into main Bug 1231069
+ for uartInst in 0 1 2 3
+ do
+ uartNode="/dev/ttyHS$uartInst"
+ if [ -e "$uartNode" ]; then
+ ln -s /dev/ttyHS$uartInst /dev/ttyTHS$uartInst
+ fi
+ done
+ # remove power to dc.0 for jetson-tk1
+ machine=`cat /sys/devices/soc0/machine`
+ if [ "${machine}" = "jetson-tk1" ] ; then
+ echo 4 > /sys/class/graphics/fb0/blank
+ if [ -e /sys/devices/platform/tegra-otg/enable_device ] ; then
+ echo 0 > /sys/devices/platform/tegra-otg/enable_device
+ fi
+ if [ -e /sys/devices/platform/tegra-otg/enable_host ] ; then
+ echo 1 > /sys/devices/platform/tegra-otg/enable_host
+ fi
+ fi
+
+ # CPU frequency governor
+ if [ -e /sys/devices/system/cpu/cpu0/cpufreq/scaling_available_governors ]; then
+ read governors < /sys/devices/system/cpu/cpu0/cpufreq/scaling_available_governors
+ case $governors in
+ *interactive*)
+ echo interactive > /sys/devices/system/cpu/cpu0/cpufreq/scaling_governor
+ if [ -e /sys/devices/system/cpu/cpufreq/interactive ] ; then
+ echo "1224000" > /sys/devices/system/cpu/cpufreq/interactive/hispeed_freq
+ echo "95" > /sys/devices/system/cpu/cpufreq/interactive/target_loads
+ echo "20000" > /sys/devices/system/cpu/cpufreq/interactive/min_sample_time
+ fi
+ ;;
+ *)
+ ;;
+ esac
+ fi
+
+ # CPU frequency boost on input event
+ if [ -e /sys/module/input_cfboost/parameters/boost_freq ]; then
+ echo "1224000" > /sys/module/input_cfboost/parameters/boost_freq
+ fi
+}
+
+case "$1" in
+ start)
+ nvexec
+ exit 0
+ ;;
+ *)
+ exit 1
+esac
diff --git a/recipes-bsp/binary-drivers/linux-driver-package/nv.service b/recipes-bsp/binary-drivers/linux-driver-package/nv.service
new file mode 100644
index 0000000..3fab9b2
--- /dev/null
+++ b/recipes-bsp/binary-drivers/linux-driver-package/nv.service
@@ -0,0 +1,18 @@
+[Unit]
+Description=Nvidia binary driver init script
+After=nvfb.service
+
+[Install]
+WantedBy=multi-user.target
+
+[Service]
+Type=forking
+Restart=no
+TimeoutSec=5min
+IgnoreSIGPIPE=no
+KillMode=process
+GuessMainPID=no
+RemainAfterExit=yes
+ExecStart=/etc/init.d/nv start
+ExecStop=/etc/init.d/nv stop
+
diff --git a/recipes-bsp/binary-drivers/linux-driver-package/nvfb b/recipes-bsp/binary-drivers/linux-driver-package/nvfb
new file mode 100755
index 0000000..e5f4502
--- /dev/null
+++ b/recipes-bsp/binary-drivers/linux-driver-package/nvfb
@@ -0,0 +1,25 @@
+#!/bin/sh
+#"specific first-boot script"
+
+nvexec() {
+ RET=0
+ if [ ! -e /etc/nv/nvfirstboot ]; then
+ RET=0
+ else
+ echo "/usr/lib/arm-linux-gnueabihf/tegra" >> /etc/ld.so.conf
+ echo "/usr/lib/arm-linux-gnueabihf/tegra-egl" >> /etc/ld.so.conf
+
+ ldconfig
+ rm -rf /etc/nv/nvfirstboot
+ fi
+ exit $RET
+}
+
+case "$1" in
+ start)
+ nvexec
+ exit 0
+ ;;
+ *)
+ exit 1
+esac
diff --git a/recipes-bsp/binary-drivers/linux-driver-package/nvfb.service b/recipes-bsp/binary-drivers/linux-driver-package/nvfb.service
new file mode 100644
index 0000000..4d923da
--- /dev/null
+++ b/recipes-bsp/binary-drivers/linux-driver-package/nvfb.service
@@ -0,0 +1,17 @@
+[Unit]
+Description=Nvidia binary driver first-boot script
+Before=nv.service
+
+[Install]
+WantedBy=multi-user.target
+
+[Service]
+Type=forking
+Restart=no
+TimeoutSec=5min
+IgnoreSIGPIPE=no
+KillMode=process
+GuessMainPID=no
+RemainAfterExit=yes
+ExecStart=/etc/init.d/nvfb start
+ExecStop=/etc/init.d/nvfb stop
diff --git a/recipes-bsp/binary-drivers/linux-driver-package/tegra_xusb_firmware b/recipes-bsp/binary-drivers/linux-driver-package/tegra_xusb_firmware
new file mode 100644
index 0000000..7a18086
--- /dev/null
+++ b/recipes-bsp/binary-drivers/linux-driver-package/tegra_xusb_firmware
Binary files differ
diff --git a/recipes-bsp/binary-drivers/linux-driver-package/xorg.conf b/recipes-bsp/binary-drivers/linux-driver-package/xorg.conf
new file mode 100644
index 0000000..68b7925
--- /dev/null
+++ b/recipes-bsp/binary-drivers/linux-driver-package/xorg.conf
@@ -0,0 +1,22 @@
+# Copyright (c) 2011-2013 NVIDIA CORPORATION. All Rights Reserved.
+
+#
+# This is the minimal configuration necessary to use the Tegra driver.
+# Please refer to the xorg.conf man page for more configuration
+# options provided by the X server, including display-related options
+# provided by RandR 1.2 and higher.
+
+# Disable extensions not useful on Tegra.
+Section "Module"
+ Disable "dri"
+ SubSection "extmod"
+ Option "omit xfree86-dga"
+ EndSubSection
+EndSection
+
+Section "Device"
+ Identifier "Tegra0"
+ Driver "nvidia"
+ Option "NoLogo" "true"
+EndSection
+
diff --git a/recipes-bsp/binary-drivers/linux-driver-package/xorg.conf.add b/recipes-bsp/binary-drivers/linux-driver-package/xorg.conf.add
new file mode 100644
index 0000000..0abe390
--- /dev/null
+++ b/recipes-bsp/binary-drivers/linux-driver-package/xorg.conf.add
@@ -0,0 +1,11 @@
+Section "Monitor"
+ Identifier "DSI-1"
+ Option "DPMS" "false"
+EndSection
+
+Section "ServerLayout"
+ Identifier "ServerLayout0"
+ Option "StandbyTime" "0"
+ Option "SuspendTime" "0"
+ Option "OffTime" "0"
+EndSection
diff --git a/recipes-bsp/binary-drivers/linux-driver-package_21.%.bbappend b/recipes-bsp/binary-drivers/linux-driver-package_21.%.bbappend
new file mode 100644
index 0000000..90bc0ae
--- /dev/null
+++ b/recipes-bsp/binary-drivers/linux-driver-package_21.%.bbappend
@@ -0,0 +1,99 @@
+FILESEXTRAPATHS_prepend := "${THISDIR}/linux-driver-package:"
+
+SRC_URI_append_apalis-tk1 = " \
+ file://xorg.conf \
+ file://nvfb.service \
+ file://nv.service \
+"
+inherit systemd
+
+do_install_append_apalis-tk1 () {
+ rm ${D}/usr/lib/libGL.so
+ ln -sf libGL.so.1 ${D}/usr/lib/arm-linux-gnueabihf/tegra/libGL.so
+
+ cp ${WORKDIR}/xorg.conf ${D}/etc/X11/
+ install -d ${D}${systemd_unitdir}/system/
+ install -m 0755 ${WORKDIR}/nvfb.service ${D}${systemd_unitdir}/system
+ install -m 0755 ${WORKDIR}/nv.service ${D}${systemd_unitdir}/system
+}
+
+# deploy additional binaries from the nv_gst_apps tarball
+PACKAGES_prepend = "${PN}-gstnvcamera ${PN}-gstnvvidconv-1.0 ${PN}-nvgstjpeg-1.0 ${PN}-gstnvvidconv-0.10 ${PN}-nvgstjpeg-0.10 ${PN}-nvgstapps "
+RRECOMMENDS_${PN}_append = " ${PN}-gstnvcamera ${PN}-gstnvvidconv-1.0 ${PN}-nvgstjpeg-1.0 ${PN}-gstnvvidconv-0.10 ${PN}-nvgstjpeg-0.10 ${PN}-nvgstapps"
+
+DEPENDS = "gst-plugins-base"
+
+RDEPENDS_${PN}-gstnvcamera = "libgstvideo-1.0"
+RDEPENDS_${PN}-gstnvvidconv-1.0 = "libgstvideo-1.0"
+RDEPENDS_${PN}-gstnvvidconv-0.10 = "gstreamer"
+RDEPENDS_${PN}-nvgstjpeg-1.0 = "libgstvideo-1.0"
+RDEPENDS_${PN}-nvgstjpeg-0.10 = "gstreamer"
+RDEPENDS_${PN}-nvgstapps = "libgstpbutils-1.0 gstreamer"
+
+FILES_${PN}-gstnvcamera = " \
+ ${libdir}/gstreamer-1.0/libgstnvcamera.so \
+"
+
+FILES_${PN}-gstnvvidconv-1.0 = " \
+ ${libdir}/gstreamer-1.0/libgstnvvidconv.so \
+"
+FILES_${PN}-gstnvvidconv-0.10 = " \
+ ${libdir}/gstreamer-0.10/libgstnvvidconv.so \
+"
+
+FILES_${PN}-nvgstjpeg-1.0 = " \
+ ${libdir}/gstreamer-1.0/libnvgstjpeg.so \
+"
+FILES_${PN}-nvgstjpeg-0.10 = " \
+ ${libdir}/gstreamer-0.10/libnvgstjpeg.so \
+"
+
+FILES_${PN}-nvgstapps = " \
+ ${bindir}/nvgstcapture-1.0 \
+ ${bindir}/nvgstplayer-1.0 \
+ ${bindir}/nvgstcapture-0.10 \
+ ${bindir}/nvgstplayer-0.10 \
+ ${docdir}/nvgst*README.txt \
+"
+
+FILES_${PN}-boot += " \
+ ${systemd_unitdir}/system/nv.service \
+"
+
+FILES_${PN}-firstboot += "\
+ ${systemd_unitdir}/system/nvfb.service \
+"
+
+#no gnu_hash in NVIDIA binaries, skip QA dev-so for this package
+#we have symlinks ending in .so, skip QA ldflags for this package
+#inhibit warnings about files being stripped
+INSANE_SKIP_${PN} = "build-deps dev-so ldflags already-stripped textrel"
+INSANE_SKIP_${PN}-gstnvcamera = "build-deps dev-so ldflags already-stripped textrel"
+INSANE_SKIP_${PN}-gstnvvidconv-1.0 = "build-deps dev-so ldflags already-stripped textrel"
+INSANE_SKIP_${PN}-nvgstjpeg-1.0 = "build-deps dev-so ldflags already-stripped textrel"
+INSANE_SKIP_${PN}-gstnvvidconv-0.10 = "build-deps dev-so ldflags already-stripped textrel"
+INSANE_SKIP_${PN}-nvgstjpeg-0.10 = "build-deps dev-so ldflags already-stripped textrel"
+INSANE_SKIP_${PN}-nvgstapps = "build-deps dev-so ldflags already-stripped textrel"
+
+do_install_append () {
+ NV_SAMPLE=${WORKDIR}/Linux_for_Tegra/nv_tegra/nv_sample_apps
+ tar xjf ${NV_SAMPLE}/nvgstapps.tbz2 -C ${NV_SAMPLE}
+ install -d ${D}${bindir} ${D}${libdir}/gstreamer-1.0 ${D}${docdir}
+ install -d ${D}${libdir}/gstreamer-0.10
+ install -m 0755 ${NV_SAMPLE}/usr/bin/nvgstcapture-1.0 ${D}${bindir}
+ install -m 0755 ${NV_SAMPLE}/usr/bin/nvgstplayer-1.0 ${D}${bindir}
+ install -m 0755 ${NV_SAMPLE}/nvgstcapture-1.0_README.txt ${D}${docdir}
+ install -m 0755 ${NV_SAMPLE}/nvgstplayer-1.0_README.txt ${D}${docdir}
+ install -m 0755 ${NV_SAMPLE}/usr/bin/nvgstcapture-0.10 ${D}${bindir}
+ install -m 0755 ${NV_SAMPLE}/usr/bin/nvgstplayer-0.10 ${D}${bindir}
+ install -m 0755 ${NV_SAMPLE}/nvgstcapture-0.10_README.txt ${D}${docdir}
+ install -m 0755 ${NV_SAMPLE}/nvgstplayer-0.10_README.txt ${D}${docdir}
+
+ install -m 0755 ${NV_SAMPLE}/usr/lib/arm-linux-gnueabihf/gstreamer-1.0/libgstnvcamera.so ${D}${libdir}/gstreamer-1.0
+ install -m 0755 ${NV_SAMPLE}/usr/lib/arm-linux-gnueabihf/gstreamer-1.0/libgstnvvidconv.so ${D}${libdir}/gstreamer-1.0
+ install -m 0755 ${NV_SAMPLE}/usr/lib/arm-linux-gnueabihf/gstreamer-1.0/libnvgstjpeg.so ${D}${libdir}/gstreamer-1.0
+ install -m 0755 ${NV_SAMPLE}/usr/lib/arm-linux-gnueabihf/gstreamer-0.10/libgstnvvidconv.so ${D}${libdir}/gstreamer-0.10
+ install -m 0755 ${NV_SAMPLE}/usr/lib/arm-linux-gnueabihf/gstreamer-0.10/libnvgstjpeg.so ${D}${libdir}/gstreamer-0.10
+}
+
+SYSTEMD_SERVICE_${PN} = "nvfb.service nv.service"
diff --git a/recipes-bsp/binary-drivers/linux-driver-package_21.7.0.bb b/recipes-bsp/binary-drivers/linux-driver-package_21.7.0.bb
new file mode 100755
index 0000000..ab12b2d
--- /dev/null
+++ b/recipes-bsp/binary-drivers/linux-driver-package_21.7.0.bb
@@ -0,0 +1,102 @@
+DESCRIPTION = "NVIDIA Linux Driver Packages"
+HOMEPAGE = "https://developer.nvidia.com/"
+LICENSE = "Proprietary"
+
+SRC_URI = "http://developer.download.nvidia.com/embedded/L4T/r21_Release_v7.0/Tegra124_Linux_R21.7.0_armhf.tbz2 \
+ file://xorg.conf.add \
+ file://nv \
+ file://nvfb \
+ file://tegra_xusb_firmware \
+ "
+
+LIC_FILES_CHKSUM = "file://nv_tegra/LICENSE;md5=60ad17cc726658e8cf73578bea47b85f"
+
+SRC_URI[md5sum] = "2139c0c7ecff94da68aef8a6ad0df20b"
+SRC_URI[sha256sum] = "676add1e8e6b2fcf76d97f22f38c9d0cbbe8a92342039a85c8a4c87e8c1ce824"
+
+PR = "r7"
+
+inherit ${@bb.utils.contains('DISTRO_FEATURES', 'systemd', '', 'update-rc.d', d)}
+
+INITSCRIPT_PACKAGES = "${PN}-boot ${PN}-firstboot"
+
+INITSCRIPT_NAME_${PN}-boot = "nv"
+INITSCRIPT_PARAMS_${PN}-boot = "start 41 S . "
+
+INITSCRIPT_NAME_${PN}-firstboot = "nvfb"
+INITSCRIPT_PARAMS_${PN}-firstboot = "start 40 S . "
+
+DEPENDS = "virtual/libx11 alsa-lib libxext"
+
+INSANE_SKIP_${PN} = "ldflags"
+
+PACKAGE_ARCH = "${MACHINE_ARCH}"
+
+S = "${WORKDIR}/Linux_for_Tegra"
+
+
+PACKAGES =+ "${PN}-firmware ${PN}-boot ${PN}-firstboot"
+
+INSANE_SKIP_${PN}-dev = "ldflags"
+
+FILES_${PN} = "${bindir}/* ${libdir}/* ${sysconfdir}/* ${sysconfdir}/*/*"
+RRECOMMENDS_${PN} = "xserver-xorg-module-libwfb"
+RDEPENDS_${PN} = "xserver-xorg bash"
+
+FILES_${PN}-firmware = "${base_libdir}/firmware/* ${base_libdir}/firmware/tegra12x/* "
+
+INHIBIT_PACKAGE_STRIP = "1"
+#INHIBIT_PACKAGE_DEBUG_SPLIT = "1"
+
+INSANE_SKIP_${PN} += "dev-so"
+
+do_patch () {
+ mkdir -p ${WORKDIR}/l4tdrv
+ tar xjf ${WORKDIR}/Linux_for_Tegra/nv_tegra/config.tbz2 -C ${WORKDIR}/l4tdrv
+}
+
+do_install () {
+ tar xjf ${WORKDIR}/Linux_for_Tegra/nv_tegra/nvidia_drivers.tbz2 -C ${D}
+ cp -r ${WORKDIR}/tegra_xusb_firmware ${D}/lib/firmware/
+ ln -sf ./libcuda.so.1.1 ${D}/usr/lib/arm-linux-gnueabihf/tegra/libcuda.so
+ ln -sf ./arm-linux-gnueabihf/tegra/libcuda.so ${D}/usr/lib/libcuda.so
+ ln -sf ./arm-linux-gnueabihf/tegra/libGL.so.1 ${D}/usr/lib/libGL.so
+ cp ${WORKDIR}/l4tdrv/etc/asound* ${D}/etc/
+ cp -r ${WORKDIR}/l4tdrv/etc/udev ${D}/etc/
+ mkdir ${D}/etc/X11/
+ cp ${WORKDIR}/l4tdrv/etc/X11/xorg.conf* ${D}/etc/X11/
+ cat ${WORKDIR}/l4tdrv/etc/X11/xorg.conf.jetson-tk1 ${WORKDIR}/xorg.conf.add > ${D}/etc/X11/xorg.conf.jetson-tk1
+
+ # install init scripts
+ install -d ${D}${sysconfdir}/init.d/
+ install -m 0755 ${WORKDIR}/nv ${D}${sysconfdir}/init.d/nv
+ install -m 0755 ${WORKDIR}/nvfb ${D}${sysconfdir}/init.d/nvfb
+ install -d ${D}${sysconfdir}/nv
+ touch ${D}${sysconfdir}/nv/nvfirstboot
+}
+
+do_populate_sysroot () {
+ tar xjf ${WORKDIR}/Linux_for_Tegra/nv_tegra/nvidia_drivers.tbz2 -C ${WORKDIR}/sysroot-destdir/
+ rm ${WORKDIR}/sysroot-destdir/usr/lib/xorg/modules/extensions/libglx.so
+ mkdir ${WORKDIR}/sysroot-destdir/sysroot-providers
+ touch ${WORKDIR}/sysroot-destdir/sysroot-providers/${PN}
+}
+
+# Function to add the relevant ABI dependency to drivers, which should be called# from a PACKAGEFUNC.
+python add_xorg_abi_depends() {
+ mlprefix = d.getVar('MLPREFIX', True) or ''
+ abi = "%sxorg-abi-%s-%s" % (mlprefix, "video", "19")
+
+ pn = d.getVar("PN", True)
+ d.appendVar('RDEPENDS_' + pn, ' ' + abi)
+}
+PACKAGEFUNCS =+ "add_xorg_abi_depends"
+
+FILES_${PN}-boot = " \
+ ${sysconfdir}/init.d/nv \
+"
+
+FILES_${PN}-firstboot = "\
+ ${sysconfdir}/init.d/nvfb \
+ ${sysconfdir}/nv/nvfirstboot \
+"
diff --git a/recipes-bsp/binary-drivers/opencv4tegra_21.5.0.bb b/recipes-bsp/binary-drivers/opencv4tegra_21.5.0.bb
new file mode 100644
index 0000000..b12c501
--- /dev/null
+++ b/recipes-bsp/binary-drivers/opencv4tegra_21.5.0.bb
@@ -0,0 +1,45 @@
+DESCRIPTION = "NVIDIA OpenCV4Tegra for L4T 21.x Packages"
+HOMEPAGE = "https://developer.nvidia.com/"
+LICENSE = "Proprietary"
+
+SRC_URI = "http://developer.download.nvidia.com/devzone/devcenter/mobile/jetpack_l4t/003/linux-x64/libopencv4tegra-repo_2.4.13_armhf_l4t-r21.deb"
+
+LIC_FILES_CHKSUM = "file://usr/share/doc/libopencv4tegra-repo/copyright;md5=99d8c0c1313afdf990f6407c07a88407"
+
+SRC_URI[md5sum] = "0db305a4d24a9211606bb1fb8ec2d480"
+SRC_URI[sha256sum] = "9bfa9d5df0c3218f5b4000c8d9d50d136cd8e6ad82384b7781719deb7093ae21"
+
+DEPENDS = "dpkg-native tiff zlib jpeg glib-2.0 python gtk+ libpng12 jasper libav cudatoolkit6.5"
+
+INSANE_SKIP_${PN} = "ldflags"
+
+PACKAGE_ARCH = "${MACHINE_ARCH}"
+
+S = "${WORKDIR}/opencv4tegra"
+
+INSANE_SKIP_${PN}-dev = "ldflags"
+
+FILES_${PN} = "${bindir}/* \
+ ${datadir}/OpenCV/* \
+ ${datadir}/lintian/* \
+ ${libdir}/*"
+
+INHIBIT_PACKAGE_STRIP = "1"
+
+INSANE_SKIP_${PN} += "already-stripped dev-so"
+
+python do_unpack () {
+ locals = d.getVar('WORKDIR', True)
+ s = d.getVar('S', True)
+ d.setVar('WORKDIR', s)
+ d.setVar('S', s)
+ bb.build.exec_func('base_do_unpack', d)
+ d.setVar('WORKDIR', locals)
+}
+
+do_install () {
+ cp -r ${WORKDIR}/opencv4tegra/usr ${D}
+ dpkg -x ${WORKDIR}/opencv4tegra/var/libopencv4tegra-repo/libopencv4tegra_2.4.13_armhf.deb ${D}
+ dpkg -x ${WORKDIR}/opencv4tegra/var/libopencv4tegra-repo/libopencv4tegra-dev_2.4.13_armhf.deb ${D}
+ dpkg -x ${WORKDIR}/opencv4tegra/var/libopencv4tegra-repo/libopencv4tegra-python_2.4.13_armhf.deb ${D}
+}