NVidia GPU binary blobs for x86 and ARM (branch yem/gfx)
v6 cover NVidia GPU binary blobs for x86 and ARM (branch yem/gfx)
Hello All!
This series adds support for NVidia's binary blob, the driver to its family of GPUs, for x86 (by Yann) and Tegra2 and Tegra3 (by Nicolas).
It also introduces the OpenGL Registry, to provide GL headers for those OpenGL/EGL/GLES implementations that do not provide their own headers (like NVidia's binary blob.)
The x86 drivers were build- and runtile-tested using XBMC (not yet with Kodi); the tests were very shallow, though, and not everything was thouroughly tested (especially the video decoding part), but it is apparently working OK so far.
Changes v5 -> v6:
- make python-lxml a target package too (Yegor)
- rename the packages and move one directory up (J?r?me)
- use mesa3d to provide additional headers, don;t bundle them
- install extra GLES platform headers (Nicolas)
- x86 nvidia driver installs a gl.pc file (J?r?me)
- drop JPEG HW acceleration for Tegra2/3, since we do not have the headers (Nicolas)
Changes v4 -> v5:
- fix env vars when building opengl-registry
Changes v3 -> v4:
- integrate the Tegra2/3 driver from Nicolas
- lots of cleanups in the packages for Tegra2/3
- further fixes after Thomas comments
- introduce more of the Khronos registry (OpenMAX, OpenKode...)
Changes v2 -> v3:
- some rewrite after Thomas comments
Changes v1 -> v2:
- bump opengl-registry
- drop i915, applied (Peter)
Regards,
Yann E. MORIN.
The following changes since commit dfdf173a4c7ca1c8584833a7286df37cb008fdb2:
qt: add X11 support (2015-01-23 23:32:23 +0100)
are available in the git repository at:
git://git.busybox.net/~ymorin/git/buildroot yem/gfx
for you to fetch changes up to a7e8708b7a6bd74374470fd8a453c612de9a60dd:
package/nvidia-tegra23-codecs: new package (2015-01-23 23:48:33 +0100)
----------------------------------------------------------------
J?r?me Pouiller (1):
package/nvidia-driver: Add gl.pc
Nicolas Serafini (3):
package/nvidia-tegra23-binaries: new package package.nvidia-tegra23-binaries: add gstreamer plugins package/nvidia-tegra23-codecs: new package
Yann E. MORIN (9):
package/python-lxml: new host package package/khronos-registry-khrplatform: new package package/khronos-registry-openkode: new package package/mesa3d-headers: new package package/khronos-registry-opengl: new package package/khronos-registry-opengl: download and install extra headers package/khronos-registry-openmaxil: new package package/nvidia-driver: add NVidia's OpenGL binary blob package/nvidia-driver: build the kernel module
Yegor Yefremov (1):
package/python-lxml: add target variant
package/Config.in | 4 + package/mesa3d-headers/Config.in | 8 + package/mesa3d-headers/mesa3d-headers.hash | 2 + package/mesa3d-headers/mesa3d-headers.mk | 57 ++++++++ package/nvidia-driver/Config.in | 65 +++++++++ package/nvidia-driver/gl.pc | 11 ++ package/nvidia-driver/nvidia-driver.hash | 3 + package/nvidia-driver/nvidia-driver.mk | 161 +++++++++++++++++++++ package/nvidia-tegra23/Config.in | 37 +++++ .../nvidia-tegra23-binaries/Config.in | 110 ++++++++++++++ .../nvidia-tegra23/nvidia-tegra23-binaries/egl.pc | 10 ++ .../nvidia-tegra23/nvidia-tegra23-binaries/gles.pc | 10 ++ .../nvidia-tegra23-binaries/glesv2.pc | 10 ++ .../nvidia-tegra23-binaries.hash | 3 + .../nvidia-tegra23-binaries.mk | 130 +++++++++++++++++ .../nvidia-tegra23/nvidia-tegra23-codecs/Config.in | 7 + .../nvidia-tegra23-codecs.hash | 3 + .../nvidia-tegra23-codecs/nvidia-tegra23-codecs.mk | 41 ++++++ package/nvidia-tegra23/nvidia-tegra23.mk | 17 +++ package/opengl/Config.in | 6 + .../opengl/khronos-registry-khrplatform/Config.in | 11 ++ .../khronos-registry-khrplatform.hash | 2 + .../khronos-registry-khrplatform.mk | 28 ++++ .../0001-run-from-current-dir.patch | 17 +++ package/opengl/khronos-registry-opengl/Config.in | 25 ++++ .../khronos-registry-opengl.hash | 4 + .../khronos-registry-opengl.mk | 115 +++++++++++++++ package/opengl/khronos-registry-openkode/Config.in | 15 ++ .../khronos-registry-openkode.hash | 7 + .../khronos-registry-openkode.mk | 49 +++++++ .../opengl/khronos-registry-openmaxil/Config.in | 20 +++ .../khronos-registry-openmax.hash | 3 + .../khronos-registry-openmaxil.mk | 32 ++++ package/python-lxml/Config.in | 10 ++ package/python-lxml/python-lxml.hash | 2 + package/python-lxml/python-lxml.mk | 33 +++++ 36 files changed, 1068 insertions(+) create mode 100644 package/mesa3d-headers/Config.in create mode 100644 package/mesa3d-headers/mesa3d-headers.hash create mode 100644 package/mesa3d-headers/mesa3d-headers.mk create mode 100644 package/nvidia-driver/Config.in create mode 100644 package/nvidia-driver/gl.pc create mode 100644 package/nvidia-driver/nvidia-driver.hash create mode 100644 package/nvidia-driver/nvidia-driver.mk create mode 100644 package/nvidia-tegra23/Config.in create mode 100644 package/nvidia-tegra23/nvidia-tegra23-binaries/Config.in create mode 100644 package/nvidia-tegra23/nvidia-tegra23-binaries/egl.pc create mode 100644 package/nvidia-tegra23/nvidia-tegra23-binaries/gles.pc create mode 100644 package/nvidia-tegra23/nvidia-tegra23-binaries/glesv2.pc create mode 100644 package/nvidia-tegra23/nvidia-tegra23-binaries/nvidia-tegra23-binaries.hash create mode 100644 package/nvidia-tegra23/nvidia-tegra23-binaries/nvidia-tegra23-binaries.mk create mode 100644 package/nvidia-tegra23/nvidia-tegra23-codecs/Config.in create mode 100644 package/nvidia-tegra23/nvidia-tegra23-codecs/nvidia-tegra23-codecs.hash create mode 100644 package/nvidia-tegra23/nvidia-tegra23-codecs/nvidia-tegra23-codecs.mk create mode 100644 package/nvidia-tegra23/nvidia-tegra23.mk create mode 100644 package/opengl/khronos-registry-khrplatform/Config.in create mode 100644 package/opengl/khronos-registry-khrplatform/khronos-registry-khrplatform.hash create mode 100644 package/opengl/khronos-registry-khrplatform/khronos-registry-khrplatform.mk create mode 100644 package/opengl/khronos-registry-opengl/0001-run-from-current-dir.patch create mode 100644 package/opengl/khronos-registry-opengl/Config.in create mode 100644 package/opengl/khronos-registry-opengl/khronos-registry-opengl.hash create mode 100644 package/opengl/khronos-registry-opengl/khronos-registry-opengl.mk create mode 100644 package/opengl/khronos-registry-openkode/Config.in create mode 100644 package/opengl/khronos-registry-openkode/khronos-registry-openkode.hash create mode 100644 package/opengl/khronos-registry-openkode/khronos-registry-openkode.mk create mode 100644 package/opengl/khronos-registry-openmaxil/Config.in create mode 100644 package/opengl/khronos-registry-openmaxil/khronos-registry-openmax.hash create mode 100644 package/opengl/khronos-registry-openmaxil/khronos-registry-openmaxil.mk create mode 100644 package/python-lxml/Config.in create mode 100644 package/python-lxml/python-lxml.hash create mode 100644 package/python-lxml/python-lxml.mk
Signature · 6 lines
.-----------------.--------------------.------------------.--------------------. | Yann E. MORIN | Real-Time Embedded | /"\ ASCII RIBBON | Erics' conspiracy: | | +33 662 376 056 | Software Designer | \ / CAMPAIGN | ___ | | +33 223 225 172 `------------.-------: X AGAINST | \e/ There is no | | http://ymorin.is-a-geek.org/ | _/*\_ | / \ HTML MAIL | v conspiracy. | '------------------------------^-------^------------------^--------------------'
PATCH v6 1/14 package/python-lxml: new host package
The lxml XML toolkit is a Pythonic binding for the C libraries libxml2 and libxslt.
---
This is a host-only package for now, because I only needed it to build opengl-registry.
--- package/python-lxml/python-lxml.hash | 2 ++ package/python-lxml/python-lxml.mk | 25 +++++++++++++++++++++++++ 2 files changed, 27 insertions(+) create mode 100644 package/python-lxml/python-lxml.hash create mode 100644 package/python-lxml/python-lxml.mk
package/python-lxml/python-lxml.hash new file +2 -0
@@ -0,0 +1,2 @@ +# Locally computed +sha256 069594837d0376a1bacf5cc42aa9a1be2e1c1396dc62f7d07f7358afecd34adf lxml-3.4.1.tgz
package/python-lxml/python-lxml.mk new file +25 -0
@@ -0,0 +1,25 @@ +################################################################################ +# +# python-lxml +# +################################################################################ + +PYTHON_LXML_VERSION = 3.4.1 +PYTHON_LXML_SITE = http://lxml.de/files +PYTHON_LXML_SOURCE = lxml-$(PYTHON_LXML_VERSION).tgz + +# Not including the GPL, because it is used only for the test scripts. +PYTHON_LXML_LICENSE = BSD-3c, Others +PYTHON_LXML_LICENSE_FILES = \ + LICENSES.txt \ + doc/licenses/BSD.txt \ + doc/licenses/elementtree.txt \ + src/lxml/isoschematron/resources/rng/iso-schematron.rng + +# python-lxml can use either setuptools, or distutils as a fallback. +# So, we use setuptools. +PYTHON_LXML_SETUP_TYPE = setuptools + +PYTHON_LXML_DEPENDENCIES = libxml2 libxslt + +$(eval $(host-python-package))
Signature · 1 line
1.9.1
PATCH v6 2/14 package/python-lxml: add target variant
In reply to Yann E. MORINFrom: Yegor Yefremov <[email protected]>
[yann.morin.1998 at free.fr: fix staging path; trim dependencies of
the host variant]
--- package/Config.in | 1 + package/python-lxml/Config.in | 10 ++++++++++ package/python-lxml/python-lxml.mk | 10 +++++++++- 3 files changed, 20 insertions(+), 1 deletion(-) create mode 100644 package/python-lxml/Config.in
package/Config.in +1 -0
@@ -519,6 +519,7 @@ menu "external python modules" source "package/python-json-schema-validator/Config.in" source "package/python-keyring/Config.in" source "package/python-libconfig/Config.in" + source "package/python-lxml/Config.in" source "package/python-mad/Config.in" source "package/python-markdown/Config.in" source "package/python-markupsafe/Config.in"
package/python-lxml/Config.in new file +10 -0
@@ -0,0 +1,10 @@ +config BR2_PACKAGE_PYTHON_LXML + bool "python-lxml" + select BR2_PACKAGE_LIBXML2 + select BR2_PACKAGE_LIBXSLT + select BR2_PACKAGE_ZLIB + help + The lxml XML toolkit is a Pythonic binding for the C libraries + libxml2 and libxslt. + + http://lxml.de/
package/python-lxml/python-lxml.mk +9 -1
@@ -20,6 +20,14 @@ PYTHON_LXML_LICENSE_FILES = \ # So, we use setuptools. PYTHON_LXML_SETUP_TYPE = setuptools -PYTHON_LXML_DEPENDENCIES = libxml2 libxslt +PYTHON_LXML_DEPENDENCIES = libxml2 libxslt zlib +HOST_PYTHON_LXML_DEPENDENCIES = host-libxml2 host-libxslt +# python-lxml needs these scripts in order to properly detect libxml2 and +# libxslt compiler and linker flags +PYTHON_LXML_BUILD_OPTS = \ + --with-xslt-config=$(STAGING_DIR)/usr/bin/xslt-config \ + --with-xml2-config=$(STAGING_DIR)/usr/bin/xml2-config + +$(eval $(python-package)) $(eval $(host-python-package))
Signature · 1 line
1.9.1
PATCH v6 3/14 package/khronos-registry-khrplatform: new package
In reply to Yann E. MORINKhronos is the group behind OpenGL and its siblings, OpenMAX and all other GFX-related Open-something.
Khronos maintains the Registry, in which the reference headers for the different Open-something are maintained.
khrplatform is the header used by most (if not all) other Khronos headers.
Note: there is no version for that file, so we rely on the hash to decide whether we have to re-download it or not. That's unfortunate, however, as an old build will not be reproducible in the future... :-(
--- package/opengl/Config.in | 3 +++ .../opengl/khronos-registry-khrplatform/Config.in | 11 +++++++++ .../khronos-registry-khrplatform.hash | 2 ++ .../khronos-registry-khrplatform.mk | 28 ++++++++++++++++++++++ 4 files changed, 44 insertions(+) create mode 100644 package/opengl/khronos-registry-khrplatform/Config.in create mode 100644 package/opengl/khronos-registry-khrplatform/khronos-registry-khrplatform.hash create mode 100644 package/opengl/khronos-registry-khrplatform/khronos-registry-khrplatform.mk
package/opengl/Config.in +3 -0
@@ -3,3 +3,6 @@ source "package/opengl/libegl/Config.in" source "package/opengl/libgles/Config.in" source "package/opengl/libopenvg/Config.in" source "package/opengl/libopenmax/Config.in" + +# Khronos headers, from the Khronos Registries +source "package/opengl/khronos-registry-khrplatform/Config.in"
package/opengl/khronos-registry-khrplatform/Config.in new file +11 -0
@@ -0,0 +1,11 @@ +# Promptless package, because we do not want the user be responsible +# for enabling this package. Instead, it should be selected by those +# packages that need the KHR header(s). + +config BR2_PACKAGE_KHRONOS_REGISTRY_KHRPLATFORM + bool + help + khrplatform installs the khrplatform.h headers, used by most + other Khronos headers. + + https://www.khronos.org/registry/
package/opengl/khronos-registry-khrplatform/khronos-registry-khrplatform.hash new file +2 -0
@@ -0,0 +1,2 @@ +# Locally computed +sha256 7631de0f2ce64747bfd893486eaa41aa08b9e8c5e5c6501b81c045c6ebf04b2a khrplatform.h
package/opengl/khronos-registry-khrplatform/khronos-registry-khrplatform.mk new file +28 -0
@@ -0,0 +1,28 @@ +################################################################################ +# +# khronos-registry-khrplatform +# +################################################################################ + +# There is no version for that file :-( + +KHRONOS_REGISTRY_KHRPLATFORM_SOURCE = khrplatform.h +KHRONOS_REGISTRY_KHRPLATFORM_SITE = https://www.khronos.org/registry/egl/api/KHR + +# No license file, license in the header file itself +KHRONOS_REGISTRY_KHRPLATFORM_LICENSE = MIT + +# Only installs a header +KHRONOS_REGISTRY_KHRPLATFORM_INSTALL_STAGING = YES +KHRONOS_REGISTRY_KHRPLATFORM_INSTALL_TARGET = NO + +define KHRONOS_REGISTRY_KHRPLATFORM_EXTRACT_CMDS + $(INSTALL) -d $(@D) + $(INSTALL) -D -m 0644 $(DL_DIR)/khrplatform.h $(@D)/khrplatform.h +endef + +define KHRONOS_REGISTRY_KHRPLATFORM_INSTALL_STAGING_CMDS + $(INSTALL) -D -m 0644 $(@D)/khrplatform.h $(STAGING_DIR)/usr/include/KHR/khrplatform.h +endef + +$(eval $(generic-package))
Signature · 1 line
1.9.1
PATCH v6 4/14 package/khronos-registry-openkode: new package
In reply to Yann E. MORINThe OpenKODE Registry provides all OpenKODE headers, directly from the Khronos group.
Those headers are needed when an OpenKODE implementation does not provide them, like the NVidia binary blobs.
--- package/opengl/Config.in | 1 + package/opengl/khronos-registry-openkode/Config.in | 15 +++++++ .../khronos-registry-openkode.hash | 7 ++++ .../khronos-registry-openkode.mk | 49 ++++++++++++++++++++++ 4 files changed, 72 insertions(+) create mode 100644 package/opengl/khronos-registry-openkode/Config.in create mode 100644 package/opengl/khronos-registry-openkode/khronos-registry-openkode.hash create mode 100644 package/opengl/khronos-registry-openkode/khronos-registry-openkode.mk
package/opengl/Config.in +1 -0
@@ -6,3 +6,4 @@ source "package/opengl/libopenmax/Config.in" # Khronos headers, from the Khronos Registries source "package/opengl/khronos-registry-khrplatform/Config.in" +source "package/opengl/khronos-registry-openkode/Config.in"
package/opengl/khronos-registry-openkode/Config.in new file +15 -0
@@ -0,0 +1,15 @@ +# Note: this package has no prompt, because it is to be selected by +# packages that need it, and does not make sense on its own. +# Further more, we want to avoid it being enabled alongside any other +# package that provide their own OpenKODE headers + +config BR2_PACKAGE_KHRONOS_REGISTRY_OPENKODE + bool + select BR2_PACKAGE_KHRONOS_REGISTRY_KHRPLATFORM + help + The OpenKODE Registry contains specifications of the core API and + headers, optional OpenKODE extensions and headers, points to other + Khronos APIs required by a conformant OpenKODE implementation, and + includes some related documentation. + + https://www.khronos.org/registry/kode/
package/opengl/khronos-registry-openkode/khronos-registry-openkode.hash new file +7 -0
@@ -0,0 +1,7 @@ +# Locally computed +sha256 e55f962ec91f9a58824a8c42d3556ea1d803b589f5d7b1b6d1ab5bae929fd1cd kd.h +sha256 a51e0cbda20c393585e08a5035fe1bb6b9bed239a80f95e843686d1567a9f513 kdplatform.h +sha256 331835322e53fc131774b6116318a2445651b3487e41510a786d5a27ce556e91 KHR_float64.h +sha256 37a7596ec5377bb17fb157750a584b39b8bc7955a96b4fb29ff0c6cdf7a3fd9e KHR_formatted.h +sha256 cea58f28b749c59790327f61c445b09a202ef71c97b13cbbce1310316121c23e KHR_perfcounter.h +sha256 aa2bfc742d209e195580a0194352e1b375f9b71688ce7f6b222ab020c397e7f9 KHR_thread_storage.h
package/opengl/khronos-registry-openkode/khronos-registry-openkode.mk new file +49 -0
49 lines not on this page · raw message
Signature · 1 line
1.9.1
PATCH v6 5/14 package/mesa3d-headers: new package
In reply to Yann E. MORINSome headers required to build GL/EGL/GLES/... stuff are not provided by Khronos, so we must find an alternate source for those headers. Currently, we're missing:
- gl.h for full GL (gl.h for GLES is available from Khronos)
- dri_interface.h to be able to build GL-enabled Xorg
mesa3d provides all of them, and they are generic enough that they can be re-used even for other GL/EGL/GLES/... implementations.
Unfortunately, modifying mesa3d so that it only installs its headers is no trivial task, and would render the mesa3d package really ugly and unmaintainable in the long run.
Instead, we introduce a stripped-down mesa3d-headers package, which sole purpose is to install those missing headers.
Alongside the dri_interface.h header, we also need to install a pkg-config file, dri.pc, so that Xorg et al. are content and believe they have DRI available.
Since we do only really require a very limited subset of files from mesa3d, we do not really care of the version we use, so there is no reason to keep them both in sync, and no reason to add a comment in mesa3d to that effect.
---
Notes:
It should not be possible to select both mesa3d *and* mesa3d-headers at the same time, but it is difficult to foresee the multiple combinations we may have, due to poor understanding on how binary drivers may behave and may require, as well as my own poor understanding of the GL stack(s).
So I decided to just print a warning in that case, and just depend on mesa3d, which would ultimately provide the headers we are interested in anyway. This can be turned into an error if preferred.
--- package/Config.in | 1 + package/mesa3d-headers/Config.in | 8 +++++ package/mesa3d-headers/mesa3d-headers.hash | 2 ++ package/mesa3d-headers/mesa3d-headers.mk | 57 ++++++++++++++++++++++++++++++ 4 files changed, 68 insertions(+) create mode 100644 package/mesa3d-headers/Config.in create mode 100644 package/mesa3d-headers/mesa3d-headers.hash create mode 100644 package/mesa3d-headers/mesa3d-headers.mk
package/Config.in +1 -0
@@ -215,6 +215,7 @@ endif source "package/linux-fusion/Config.in" source "package/lite/Config.in" source "package/mesa3d/Config.in" + source "package/mesa3d-headers/Config.in" source "package/ocrad/Config.in" source "package/psplash/Config.in" source "package/sawman/Config.in"
package/mesa3d-headers/Config.in new file +8 -0
@@ -0,0 +1,8 @@ +config BR2_PACKAGE_MESA3D_HEADERS + bool + help + Mesa 3D, an open-source implementation of the OpenGL specification. + + This package only installs headers needed by other packages. + + http://mesa3d.org
package/mesa3d-headers/mesa3d-headers.hash new file +2 -0
@@ -0,0 +1,2 @@ +# From http://mesa3d.org/relnotes/10.4.2.html +sha256 08a119937d9f2aa2f66dd5de97baffc2a6e675f549e40e699a31f5485d15327f MesaLib-10.4.2.tar.bz2
package/mesa3d-headers/mesa3d-headers.mk new file +57 -0
57 lines not on this page · raw message
Signature · 1 line
1.9.1
PATCH v6 5/14 package/mesa3d-headers: new package
Hello Yann,
Quoted 6 lines · On Saturday 24 January 2015 00:24:34 Yann E. MORIN wrote:
Some headers required to build GL/EGL/GLES/... stuff are not provided by Khronos, so we must find an alternate source for those headers. Currently, we're missing:
-gl.hfor full GL (gl.hfor GLES is available from Khronos)
-dri_interface.hto be able to build GL-enabled Xorg
Quoted 6 lines
mesa3d provides all of them, and they are generic enough that they can be re-used even for other GL/EGL/GLES/... implementations.
Unfortunately, modifying mesa3d so that it only installs its headers is no trivial task, and would render the mesa3d package really ugly and unmaintainable in the long run.
Did you try "make install-data" in mesa3d tree? It should install all files but the libraries (in other terms, it install headers only).
Quoted 2 lines
Instead, we introduce a stripped-down mesa3d-headers package, which sole purpose is to install those missing headers.
hmmm... since mesa3d-headers provide all headers, do we really need khronos-registry-* packages? In add, all developers test their code using mesa3d headers. So, I would prefer to use headers provided by mesa3d than khronos.
[...]
Signature · 3 lines
J?r?me Pouiller, Sysmic Embedded Linux specialist http://www.sysmic.fr
PATCH v6 5/14 package/mesa3d-headers: new package
J?r?me, All,
On 2015-01-26 09:54 +0100, J?r?me Pouiller spake thusly:
Quoted 7 lines · On Saturday 24 January 2015 00:24:34 Yann E. MORIN wrote:
Quoted 6 lines
Some headers required to build GL/EGL/GLES/... stuff are not provided by Khronos, so we must find an alternate source for those headers. Currently, we're missing:
-gl.hfor full GL (gl.hfor GLES is available from Khronos)
-dri_interface.hto be able to build GL-enabled Xorg
Quoted 8 lines
Quoted 6 lines
mesa3d provides all of them, and they are generic enough that they can be re-used even for other GL/EGL/GLES/... implementations.
Unfortunately, modifying mesa3d so that it only installs its headers is no trivial task, and would render the mesa3d package really ugly and unmaintainable in the long run.
Did you try "make install-data" in mesa3d tree? It should install all files but the libraries (in other terms, it install headers only).
I thought of doing just that, indeed.
But then, it is only possible to run 'make install-anything' if the package had previously been configured and built, i.e. './configure' and .make' were previously called.
But then, what flags are we supposed to pass ./configure ? We surely do not want to enable everything, jsut what is needed to get the headers.
And then, we would have to carefuly call 'make' so that it does not build everything, just the headers.
Quoted 6 lines
Quoted 2 lines
Instead, we introduce a stripped-down mesa3d-headers package, which sole purpose is to install those missing headers.
hmmm... since mesa3d-headers provide all headers, do we really need khronos-registry-* packages? In add, all developers test their code using mesa3d headers. So, I would prefer to use headers provided by mesa3d than khronos.
Well, I'm not really against droippign the Khronos registries, since it is not fun packaging those.
However, as I said above, we'd have to carefuly craft mesa3d-headers to just configure and build the headers, and I'm afraid that's not so easy...
But I can give it a shot to see how dirty/difficult it would be.
Regards,
Yann E. MORIN.
Signature · 6 lines
.-----------------.--------------------.------------------.--------------------. | Yann E. MORIN | Real-Time Embedded | /"\ ASCII RIBBON | Erics' conspiracy: | | +33 662 376 056 | Software Designer | \ / CAMPAIGN | ___ | | +33 223 225 172 `------------.-------: X AGAINST | \e/ There is no | | http://ymorin.is-a-geek.org/ | _/*\_ | / \ HTML MAIL | v conspiracy. | '------------------------------^-------^------------------^--------------------'
PATCH v6 6/14 package/khronos-registry-opengl: new package
In reply to Yann E. MORINThe OpenGL Registry provides all GL headers, save for gl.h itself. We vampirise the one from mesa3d (at the version we currently package), which is as good as any other.
Those headers are needed when an OpenGL/EGL/GLES implementation does not provide its own headers, like the NVidia binary blob (to come in follow-up patches.)
Note that, even though this is a generic package, and we could everything in the BUILD_CMDS, we decided to split the tweaking of glx.h in a post-build script, to really make it clear we are tweaking a generated file.
--
Tested by building XBMC against the NVidia proprietary blob.
Note: their svn repository holds many other things, even non-public stuff, so the svn revision we use is the one at which the api directory was *changed*, which might be lagging behind the revision the repository is currently at
---
Changes v5 -> v6:
- depend on mesa3d-headers to provide gl.h, so ditch our bundled copy
Changes v4 -> v5:
- fix env when calling make
Changes v3 -> v4:
- move to a sub-dir of opengl/ because we'll add some more Khronos registry packages (OpenMAX...)
- bump revision
--- package/opengl/Config.in | 1 + .../0001-run-from-current-dir.patch | 17 +++++ package/opengl/khronos-registry-opengl/Config.in | 25 +++++++ .../khronos-registry-opengl.mk | 83 ++++++++++++++++++++++ 4 files changed, 126 insertions(+) create mode 100644 package/opengl/khronos-registry-opengl/0001-run-from-current-dir.patch create mode 100644 package/opengl/khronos-registry-opengl/Config.in create mode 100644 package/opengl/khronos-registry-opengl/khronos-registry-opengl.mk
package/opengl/Config.in +1 -0
@@ -7,3 +7,4 @@ source "package/opengl/libopenmax/Config.in" # Khronos headers, from the Khronos Registries source "package/opengl/khronos-registry-khrplatform/Config.in" source "package/opengl/khronos-registry-openkode/Config.in" +source "package/opengl/khronos-registry-opengl/Config.in"
package/opengl/khronos-registry-opengl/0001-run-from-current-dir.patch new file +17 -0
@@ -0,0 +1,17 @@ +Makefile: allow running without the current dir in PATH + +Signed-off-by: "Yann E. MORIN" <[email protected]> + +Index: a/Makefile +=================================================================== +--- a/Makefile (revision 27863) ++++ a/Makefile (working copy) +@@ -24,7 +24,7 @@ + + PYFILES = genheaders.py reg.py + GENOPTS = +-GENHEADERS = genheaders.py $(GENOPTS) ++GENHEADERS = ./genheaders.py $(GENOPTS) + + # Generate all headers for GL / GLES / WGL / GLX / EGL + # Different headers depend on different XML registry files
package/opengl/khronos-registry-opengl/Config.in new file +25 -0
@@ -0,0 +1,25 @@ +# Note: this package has no prompt, because it is to be selected by +# packages that need it, and does not make sense on its own. +# Further more, we want to avoid it being enabled alongside any other +# package that provide their own OpenGL headers, like mesa3d or +# rpi-userland... + +config BR2_PACKAGE_KHRONOS_REGISTRY_OPENGL + bool + select BR2_PACKAGE_KHRONOS_REGISTRY_KHRPLATFORM + select BR2_PACKAGE_MESA3D_HEADERS + help + The OpenGL Registry contains specifications, header files, and + related documentation for OpenGL and related APIs including GLU, + GLX, and WGL. In addition to the core API specifications, many + extensions to these APIs have been defined by vendors, groups of + vendors, and the ARB. The Registry also contains specifications + and header files for all registered extensions, written as + modifications to the appropriate core API specifications. + + This package installs the openGL header files. You do not need them + if the OpenGL/EGL/GLES implementation provides its own headers. + Currently, the only known implementation requiring OpenGL Resgistry + is the NVidia proprietary driver. + + https://www.opengl.org/registry/
package/opengl/khronos-registry-opengl/khronos-registry-opengl.mk new file +83 -0
83 lines not on this page · raw message
Signature · 1 line
1.9.1
PATCH v6 7/14 package/khronos-registry-opengl: download and install extra headers
In reply to Yann E. MORINThose headers are not part of the OpenGL registry, and are provided by Khronos in a location different from the OpenGL registry.
We get the registry via svn, and we want to download the extra headers with wget. But extra-downloads are currently always using the same ite-methos as the main download, so we have to define our own download function, like we are doing for the Linux kernel patches.
--- .../khronos-registry-opengl.hash | 4 +++ .../khronos-registry-opengl.mk | 32 ++++++++++++++++++++++ 2 files changed, 36 insertions(+) create mode 100644 package/opengl/khronos-registry-opengl/khronos-registry-opengl.hash
package/opengl/khronos-registry-opengl/khronos-registry-opengl.hash new file +4 -0
@@ -0,0 +1,4 @@ +# Locally computed +sha256 03552610f3dd821c020264745d7aa37d760ca68ab44d3c7314b0959a0a24ae8e glplatform.h +sha256 9fa1b645c46dee2ff091628f3804572403ba5e424785595d3d97068c3fdc7522 gl2platform.h +sha256 3eae5adc8ad2adef24c2a9fc5572a8ea73dc953fd519d3fe7d374cd7f7b9aba8 gl3platform.h
package/opengl/khronos-registry-opengl/khronos-registry-opengl.mk +32 -0
@@ -27,6 +27,38 @@ KHRONOS_REGISTRY_OPENGL_DIRS = \ $(if $(BR2_PACKAGE_HAS_LIBEGL),EGL) \ $(if $(BR2_PACKAGE_HAS_LIBGLES),GLES GLES2 GLES3) +ifeq ($(BR2_PACKAGE_HAS_LIBGLES),y) + +KHRONOS_REGISTRY_OPENGL_EXTRA_HEADERS_BASE = http://www.khronos.org/registry/gles/api +KHRONOS_REGISTRY_OPENGL_EXTRA_HEADERS = \ + GLES/glplatform.h \ + GLES2/gl2platform.h \ + GLES3/gl3platform.h + +# Extra downloads can only be dowloaded with the same site-method as the main +# sources, so we can not use them. Instead, we have to download them manually +# as a post-download hook. +define KHRONOS_REGISTRY_OPENGL_DOWNLOAD_PATCHES + $(foreach h,$(KHRONOS_REGISTRY_OPENGL_EXTRA_HEADERS),\ + $(call DOWNLOAD_WGET,$(KHRONOS_REGISTRY_OPENGL_EXTRA_HEADERS_BASE)/$(h),$(notdir $(h)))$(sep)) +endef +KHRONOS_REGISTRY_OPENGL_POST_DOWNLOAD_HOOKS += KHRONOS_REGISTRY_OPENGL_DOWNLOAD_PATCHES + +# Destination directories already exist +define KHRONOS_REGISTRY_OPENGL_EXTRACT_PATCHES + $(foreach h,$(KHRONOS_REGISTRY_OPENGL_EXTRA_HEADERS),\ + cp $(DL_DIR)/$(notdir $(h)) $(@D)/$(h)$(sep)) +endef +KHRONOS_REGISTRY_OPENGL_POST_EXTRACT_HOOKS += KHRONOS_REGISTRY_OPENGL_EXTRACT_PATCHES + +define KHRONOS_REGISTRY_OPENGL_INSTALL_PATCHES + $(foreach h,$(KHRONOS_REGISTRY_OPENGL_EXTRA_HEADERS),\ + $(INSTALL) -m 0644 -D $(@D)/$(h) $(STAGING_DIR)/usr/include/$(h)$(sep)) +endef +KHRONOS_REGISTRY_OPENGL_POST_INSTALL_STAGING_HOOKS += KHRONOS_REGISTRY_OPENGL_INSTALL_PATCHES + +endif # GLES + # Remove pre-generated files define KHRONOS_REGISTRY_OPENGL_RM_H rm -f $(@D)/GL/*.h
Signature · 1 line
1.9.1
PATCH v6 8/14 package/khronos-registry-openmaxil: new package
In reply to Yann E. MORINThe OpenMAX Registry provides all OpenMAX headers, directly from the Khronos group.
Those headers are needed when an OpenMAX implementation does not provide them, like the NVidia binary blob.
These are the OpenMAX Inegration Layer (IL) headers.
--- package/opengl/Config.in | 1 + .../opengl/khronos-registry-openmaxil/Config.in | 20 ++++++++++++++ .../khronos-registry-openmax.hash | 3 ++ .../khronos-registry-openmaxil.mk | 32 ++++++++++++++++++++++ 4 files changed, 56 insertions(+) create mode 100644 package/opengl/khronos-registry-openmaxil/Config.in create mode 100644 package/opengl/khronos-registry-openmaxil/khronos-registry-openmax.hash create mode 100644 package/opengl/khronos-registry-openmaxil/khronos-registry-openmaxil.mk
package/opengl/Config.in +1 -0
@@ -8,3 +8,4 @@ source "package/opengl/libopenmax/Config.in" source "package/opengl/khronos-registry-khrplatform/Config.in" source "package/opengl/khronos-registry-openkode/Config.in" source "package/opengl/khronos-registry-opengl/Config.in" +source "package/opengl/khronos-registry-openmaxil/Config.in"
package/opengl/khronos-registry-openmaxil/Config.in new file +20 -0
@@ -0,0 +1,20 @@ +# Note: this package has no prompt, because it is to be selected by +# packages that need it, and does not make sense on its own. +# Further more, we want to avoid it being enabled alongside any other +# package that provide their own OpenMAX headers, like rpi-userland... + +config BR2_PACKAGE_KHRONOS_REGISTRY_OPENMAXIL + bool + select BR2_PACKAGE_KHRONOS_REGISTRY_KHRPLATFORM + help + The OpenMAX IL registry contains specifications of the core API; + specifications of Khronos- and vendor-approved OpenMAX IL extensions; + header files corresponding to the specifications; and other related + documentation. + + This package installs the OpenMAX header files. You do not need them + if the OpenMAX implementation provides its own headers. + Currently, the only known implementation requiring OpenGL Resgistry + is the NVidia proprietary driver. + + https://www.khronos.org/registry/omxil/
package/opengl/khronos-registry-openmaxil/khronos-registry-openmax.hash new file +3 -0
@@ -0,0 +1,3 @@ +# Locally computed: +sha1 35b2c565a050b4235feac3f22bbbf4bf80092a00 OpenMAX_IL_1_1_2_Header.zip +sha256 9e8aee85f37946202ff15a52836233f983e90a751c0816ba341ba0c1ffedf99e OpenMAX_IL_1_1_2_Header.zip
package/opengl/khronos-registry-openmaxil/khronos-registry-openmaxil.mk new file +32 -0
@@ -0,0 +1,32 @@ +################################################################################ +# +# khronos-registry-openmaxil +# +################################################################################ + +# The latest 'stable' version is 1.1.2; the 1.2.0 version is only +# considered "provisional", so we keep using 1.1.2 for now. +KHRONOS_REGISTRY_OPENMAXIL_VERSION = 1.1.2 +KHRONOS_REGISTRY_OPENMAXIL_SOURCE = OpenMAX_IL_$(subst .,_,$(KHRONOS_REGISTRY_OPENMAXIL_VERSION))_Header.zip +KHRONOS_REGISTRY_OPENMAXIL_SITE = https://www.khronos.org/registry/omxil/api/$(KHRONOS_REGISTRY_OPENMAXIL_VERSION) + +# No license file, license text in each header file +KHRONOS_REGISTRY_OPENMAXIL_LICENSE = MIT + +# The registry only installs header files +KHRONOS_REGISTRY_OPENMAXIL_INSTALL_STAGING = YES +KHRONOS_REGISTRY_OPENMAXIL_INSTALL_TARGET = NO + +define KHRONOS_REGISTRY_OPENMAXIL_EXTRACT_CMDS + $(UNZIP) $(DL_DIR)/$(KHRONOS_REGISTRY_OPENMAXIL_SOURCE) -d $(@D) +endef + +# OpenMAX headers go directly into /usr/include, no sub-dir +# At least, that's what bellagio does... +define KHRONOS_REGISTRY_OPENMAXIL_INSTALL_STAGING_CMDS + for h in $(@D)/*.h; do \ + $(INSTALL) -D -m 0644 $${h} $(STAGING_DIR)/usr/include/$${h##*/} || exit 1; \ + done +endef + +$(eval $(generic-package))
Signature · 1 line
1.9.1
PATCH v6 9/14 package/nvidia-driver: add NVidia's OpenGL binary blob
In reply to Yann E. MORINThis patch only adds the userland part. Unless other such other packages (which we named like: rpi-userland), we do not replicate this naming scheme with this package, as a future patch will also enable building the kernel part of the driver. So, it is better to just name that package with -driver, rather than with -userland and renaming it afterwards.
---
Changes v4 -> v5:
- fix libGL.la for stupid libtool
--- package/Config.in | 1 + package/nvidia-driver/Config.in | 51 ++++++++++++++ package/nvidia-driver/nvidia-driver.hash | 3 + package/nvidia-driver/nvidia-driver.mk | 110 +++++++++++++++++++++++++++++++ 4 files changed, 165 insertions(+) create mode 100644 package/nvidia-driver/Config.in create mode 100644 package/nvidia-driver/nvidia-driver.hash create mode 100644 package/nvidia-driver/nvidia-driver.mk
package/Config.in +1 -0
@@ -352,6 +352,7 @@ endif source "package/minicom/Config.in" source "package/nanocom/Config.in" source "package/neard/Config.in" + source "package/nvidia-driver/Config.in" source "package/ofono/Config.in" source "package/ola/Config.in" source "package/on2-8170-modules/Config.in"
package/nvidia-driver/Config.in new file +51 -0
51 lines not on this page · raw message
package/nvidia-driver/nvidia-driver.hash new file +3 -0
@@ -0,0 +1,3 @@ +# Locally computed +sha256 bba63c30c730ad7b8500a77c81cae58562b9f9b57cd576b61f37a2d8bc45df25 NVIDIA-Linux-x86-346.35.run +sha256 8625acbbc7a2abdda436a5cb9d06f2a7f5913b16e0a35ac4f9f106853a94d086 NVIDIA-Linux-x86_64-346.35.run
package/nvidia-driver/nvidia-driver.mk new file +110 -0
110 lines not on this page · raw message
Signature · 1 line
1.9.1
PATCH v6 9/14 package/nvidia-driver: add NVidia's OpenGL binary blob
Dear Yann E. MORIN,
Quoted 8 lines · Yann E. MORIN
This patch only adds the userland part. Unless other such other packages (which we named like: rpi-userland), we do not replicate this naming scheme with this package, as a future patch will also enable building the kernel part of the driver. So, it is better to just name that package with -driver, rather than with -userland and renaming it afterwards.
Signed-off-by "Yann E. MORIN" <[email protected]>
I've applied to next, after doing some changes:
[Thomas:
- Rewrap Config.in help text.
- Add a comment to explain why mesa3d-headers, xlib_libX11 and xlib_libXext are part of the dependencies.
- Fix typo in comment about library installation: s/The/Then/
- Use 'addsuffix' instead of 'patsubst' to calculate the final filename of libraries to install.
- Use more temporary variables to make the library installation
loop clearer: 'libpath' is the relative path of the library in
nvidia-driver sources, 'libname' the base name of the library, 'libsoname' the soname of the library, and 'baseso' the base .so symlink name.]
See my diff below for the details.
However, one thing that I find a bit unclear and that might need improvement is that you are making this package depend on X.org while it does provide an EGL implementation. So you install the 36 MB libnvidia-eglcore.so.346.35 unconditionally, even though I believe it's probably unused when X.org is used.
Same for libGLES: do we really need to install both libGL and libGLES ? Though I agree libGLES* are very small.
So I believe at least the EGL stuff should be separated out: either you do X.org, or you do EGL. But I don't think both can be used at the same time. Doing this would allow to drastically cut the installed size of this huge package.
So now, the diff of the changes I made:
package/nvidia-driver/Config.in +6 -5
@@ -41,11 +41,12 @@ config BR2_PACKAGE_NVIDIA_DRIVER_OPENCL config BR2_PACKAGE_NVIDIA_DRIVER_PRIVATE_LIBS bool "Install private libraries" help - Two libraries require special agreement with NVidia to develop code - linking to those libraries: libnvidia-ifr.so and libnvidia-fbc.so - (to grab and encode an OpenGL buffer or an X framebuffer.) + Two libraries require special agreement with NVidia to + develop code linking to those libraries: libnvidia-ifr.so + and libnvidia-fbc.so (to grab and encode an OpenGL buffer or + an X framebuffer.) - Say 'y' here if you plan on running a program that uses those - private libraries. + Say 'y' here if you plan on running a program that uses + those private libraries. endif # BR2_PACKAGE_NVIDIA_DRIVER
package/nvidia-driver/nvidia-driver.mk +17 -11
@@ -13,6 +13,11 @@ NVIDIA_DRIVER_LICENSE_FILES = LICENSE NVIDIA_DRIVER_REDISTRIBUTE = NO NVIDIA_DRIVER_INSTALL_STAGING = YES +# Since nvidia-driver are binary blobs, the below dependencies are not +# strictly speaking build dependencies of nvidia-driver. However, they +# are build dependencies of packages that depend on nvidia-driver, so +# they should be built prior to those packages, and the only simple +# way to do so is to make nvidia-driver depend on them. NVIDIA_DRIVER_DEPENDENCIES = mesa3d-headers xlib_libX11 xlib_libXext NVIDIA_DRIVER_PROVIDES = libgl libegl libgles
@@ -69,22 +74,23 @@ endef # $1: destination directory (target or staging) # # For all libraries that need it, we append the NVidia version string. -# The for all libraries, we install them and create a symlink using their -# SONAME, so we can link to them at runtime; we also create the no-version -# symlink, so we can link to them at build time. +# Then for all libraries, we install them and create a symlink using +# their SONAME, so we can link to them at runtime; we also create the +# no-version symlink, so we can link to them at build time. define NVIDIA_DRIVER_INSTALL_LIBS - for lib in $(patsubst %,%.so.$(NVIDIA_DRIVER_VERSION),$(NVIDIA_DRIVER_LIBS)) \ + for libpath in $(addsuffix .so.$(NVIDIA_DRIVER_VERSION),$(NVIDIA_DRIVER_LIBS)) \ $(NVIDIA_DRIVER_LIBS_NO_VERSION); \ do \ - $(INSTALL) -D -m 0644 $(@D)/$${lib} $(1)/usr/lib/$${lib##*/}; \ - n="$$( $(TARGET_READELF) -d "$(@D)/$${lib}" \ + libname="$${libpath##*/}"; \ + $(INSTALL) -D -m 0644 $(@D)/$${libpath} $(1)/usr/lib/$${libname}; \ + libsoname="$$( $(TARGET_READELF) -d "$(@D)/$${libpath}" \ |sed -r -e '/.*\(SONAME\).*\[(.*)\]$$/!d; s//\1/;' )"; \ - if [ -n "$${n}" -a "$${n}" != "$${lib##*/}" ]; then \ - ln -sf $${lib##*/} $(1)/usr/lib/$${n}; \ + if [ -n "$${libsoname}" -a "$${libsoname}" != "$${libname}" ]; then \ + ln -sf $${libname} $(1)/usr/lib/$${libsoname}; \ fi; \ - n="$${lib##*/}"; n="$${n/.so*}.so"; \ - if [ -n "$${n}" -a "$${n}" != "$${lib##*/}" ]; then \ - ln -sf $${lib##*/} $(1)/usr/lib/$${n}; \ + baseso="$${libname/.so*}.so"; \ + if [ -n "$${baseso}" -a "$${baseso}" != "$${libname}" ]; then \ + ln -sf $${libname} $(1)/usr/lib/$${baseso}; \ fi; \ done endef
Thomas
Signature · 3 lines
Thomas Petazzoni, CTO, Free Electrons Embedded Linux, Kernel and Android engineering http://free-electrons.com
PATCH v6 9/14 package/nvidia-driver: add NVidia's OpenGL binary blob
Thomas, All,
On 2015-02-21 18:39 +0100, Thomas Petazzoni spake thusly:
Quoted 11 lines · Yann E. MORIN
Quoted 8 lines
This patch only adds the userland part. Unless other such other packages (which we named like: rpi-userland), we do not replicate this naming scheme with this package, as a future patch will also enable building the kernel part of the driver. So, it is better to just name that package with -driver, rather than with -userland and renaming it afterwards.
Signed-off-by "Yann E. MORIN" <[email protected]>I've applied to next, after doing some changes:
[--SNIP--]
Quoted 8 lines
However, one thing that I find a bit unclear and that might need improvement is that you are making this package depend on X.org while it does provide an EGL implementation. So you install the 36 MB libnvidia-eglcore.so.346.35 unconditionally, even though I believe it's probably unused when X.org is used.
Same for libGLES: do we really need to install both libGL and libGLES ? Though I agree libGLES* are very small.
Well, I just did reproduce what the standard install procedure of the package does: it installs everything. Agreed, I did not even try to think those things apart.
Quoted 4 lines
So I believe at least the EGL stuff should be separated out: either you do X.org, or you do EGL. But I don't think both can be used at the same time. Doing this would allow to drastically cut the installed size of this huge package.
Well, it is indeed quite huge, but also consider the type of systems it is supposed to run on: desktop-class machines. The only embedded-class board I know of that has an NVidia GPU is the newly introduced Jetson TK1, and it has 16GiB of on-board eMMC...
Quoted 1 line
So now, the diff of the changes I made:
Thanks for this cleanup pass! :-)
Regards,
Yann E. MORIN.
Signature · 6 lines
.-----------------.--------------------.------------------.--------------------. | Yann E. MORIN | Real-Time Embedded | /"\ ASCII RIBBON | Erics' conspiracy: | | +33 662 376 056 | Software Designer | \ / CAMPAIGN | ___ | | +33 223 225 172 `------------.-------: X AGAINST | \e/ There is no | | http://ymorin.is-a-geek.org/ | _/*\_ | / \ HTML MAIL | v conspiracy. | '------------------------------^-------^------------------^--------------------'
PATCH v6 10/14 package/nvidia-driver: Add gl.pc
In reply to Yann E. MORINFrom: J?r?me Pouiller <[email protected]>
In order to compile xserver, libgl provider have to provide gl.pc file.
--- package/nvidia-driver/gl.pc | 11 +++++++++++ package/nvidia-driver/nvidia-driver.mk | 1 + 2 files changed, 12 insertions(+) create mode 100644 package/nvidia-driver/gl.pc
package/nvidia-driver/gl.pc new file +11 -0
@@ -0,0 +1,11 @@ +prefix=/usr +exec_prefix=${prefix} +libdir=${exec_prefix}/lib +includedir=${prefix}/include + +Name: gl +Description: Nvidia OpenGL library +Version: 10.4.2 +Libs: -L${libdir} -lGL -lm -lXext -lX11 -ldl +Cflags: -I${includedir} -DMESA_EGL_NO_X11_HEADERS +glx_tls: no
package/nvidia-driver/nvidia-driver.mk +1 -0
@@ -96,6 +96,7 @@ define NVIDIA_DRIVER_INSTALL_STAGING_CMDS $(SED) 's:__GENERATED_BY__:Buildroot:' $(STAGING_DIR)/usr/lib/libGL.la $(SED) 's:__LIBGL_PATH__:/usr/lib:' $(STAGING_DIR)/usr/lib/libGL.la $(SED) 's:-L[^[:space:]]\+::' $(STAGING_DIR)/usr/lib/libGL.la + $(INSTALL) -D -m 0644 package/nvidia-driver/gl.pc $(STAGING_DIR)/usr/lib/pkgconfig/gl.pc endef # For target, install libraries and X.org modules
Signature · 1 line
1.9.1
Thomas Petazzoni
AppliedPATCH v6 10/14 package/nvidia-driver: Add gl.pc
Dear Yann E. MORIN,
Quoted 6 lines · Yann E. MORIN
From: J?r?me Pouiller <[email protected]>
In order to compile xserver, libgl provider have to provide gl.pc file.
Signed-off-by J?r?me Pouiller <[email protected]>Signed-off-by Yann E. MORIN <[email protected]>
Applied to next, thanks!
Thomas
Signature · 3 lines
Thomas Petazzoni, CTO, Free Electrons Embedded Linux, Kernel and Android engineering http://free-electrons.com
PATCH v6 11/14 package/nvidia-driver: build the kernel module
In reply to Yann E. MORINAdd option to build the nvidia.ko module. If CUDA is enabled on x86_64, also build the nvidia-uvm.ko kernel module (for Unified Memory access), which is required by the CUDA user-land library.
Substancially inspired by the corresponding Gentoo ebuild:
http://sources.gentoo.org/cgi-bin/viewvc.cgi/gentoo-x86/x11-drivers/nvidia-drivers/nvidia-drivers-340.32.ebuild?revision=1.2&view=markup
--- package/nvidia-driver/Config.in | 14 ++++++++++ package/nvidia-driver/nvidia-driver.mk | 50 ++++++++++++++++++++++++++++++++++ 2 files changed, 64 insertions(+)
package/nvidia-driver/Config.in +14 -0
@@ -48,4 +48,18 @@ config BR2_PACKAGE_NVIDIA_DRIVER_PRIVATE_LIBS Say 'y' here if you plan on running a program that uses those private libraries. +comment "nvidia kernel module needs a kernel to be built" + depends on !BR2_LINUX_KERNEL + +config BR2_PACKAGE_NVIDIA_DRIVER_MODULE + bool "nvidia kernel module" + depends on BR2_LINUX_KERNEL + help + Build the nvidia.ko kernel module. + + If CUDA support (above) is set, and the target is x86_64, then + this will also build the nvidia-uvm.ko kernel module, which + provides Unified Memory access to the GPU and CPU memories for + CUDA programs. + endif # BR2_PACKAGE_NVIDIA_DRIVER
package/nvidia-driver/nvidia-driver.mk +50 -0
62 lines not on this page · raw message
Signature · 1 line
1.9.1
PATCH v6 12/14 package/nvidia-tegra23-binaries: new package
In reply to Yann E. MORINFrom: Nicolas Serafini <[email protected]>
This patch adds a new package for all libraries and drivers provided by Nvidia Linux4Tegra release 16.4.0.
We have intermediate .mk and Config.in, because those values will be shared with the codecs package, to come in a follow-up patch, like we have for the Freescale stuff.
[yann.morin.1998 at free.fr:
- split jpeg into its own patch
- split codecs and gstreamer plugins out into their own packages
- do not patch for .pc files, just bundle them in $(@D)
]
--- package/Config.in | 1 + package/nvidia-tegra23/Config.in | 36 ++++++++ .../nvidia-tegra23-binaries/Config.in | 95 ++++++++++++++++++++ .../nvidia-tegra23/nvidia-tegra23-binaries/egl.pc | 10 +++ .../nvidia-tegra23/nvidia-tegra23-binaries/gles.pc | 10 +++ .../nvidia-tegra23-binaries/glesv2.pc | 10 +++ .../nvidia-tegra23-binaries.hash | 3 + .../nvidia-tegra23-binaries.mk | 100 +++++++++++++++++++++ package/nvidia-tegra23/nvidia-tegra23.mk | 17 ++++ 9 files changed, 282 insertions(+) create mode 100644 package/nvidia-tegra23/Config.in create mode 100644 package/nvidia-tegra23/nvidia-tegra23-binaries/Config.in create mode 100644 package/nvidia-tegra23/nvidia-tegra23-binaries/egl.pc create mode 100644 package/nvidia-tegra23/nvidia-tegra23-binaries/gles.pc create mode 100644 package/nvidia-tegra23/nvidia-tegra23-binaries/glesv2.pc create mode 100644 package/nvidia-tegra23/nvidia-tegra23-binaries/nvidia-tegra23-binaries.hash create mode 100644 package/nvidia-tegra23/nvidia-tegra23-binaries/nvidia-tegra23-binaries.mk create mode 100644 package/nvidia-tegra23/nvidia-tegra23.mk
package/Config.in +1 -0
@@ -353,6 +353,7 @@ endif source "package/nanocom/Config.in" source "package/neard/Config.in" source "package/nvidia-driver/Config.in" + source "package/nvidia-tegra23/Config.in" source "package/ofono/Config.in" source "package/ola/Config.in" source "package/on2-8170-modules/Config.in"
package/nvidia-tegra23/Config.in new file +36 -0
@@ -0,0 +1,36 @@ +menuconfig BR2_PACKAGE_NVIDIA_TEGRA23 + bool "nvidia-tegra23" + depends on BR2_cortex_a9 + depends on BR2_ARM_EABIHF && BR2_TOOLCHAIN_USES_GLIBC + depends on BR2_PACKAGE_XORG7 + help + Install NVidia proprietary blobs to drive Tegra2 or Tegra3 + GPUs found in some mobile-targeted ARM SoCs. + +if BR2_PACKAGE_NVIDIA_TEGRA23 + +choice + prompt "Tegra platform" + help + Select the SOC platform. + +config BR2_PACKAGE_NVIDIA_TEGRA23_TEGRA2 + bool "Tegra 2" + help + NVIDIA Tegra 2 is a dual-core Cortex-A9 without NEON. + +config BR2_PACKAGE_NVIDIA_TEGRA23_TEGRA3 + bool "Tegra 3" + depends on BR2_ARM_CPU_HAS_NEON + help + NVIDIA Tegra 3 is a quad-core Cortex-A9 with NEON. + +endchoice + +source "package/nvidia-tegra23/nvidia-tegra23-binaries/Config.in" +endif + +comment "nvidia-tegra23 needs Xorg and a (e)glibc toolchain w/ EABIhf" + depends on BR2_cortex_a9 + depends on !BR2_ARM_EABIHF || !BR2_TOOLCHAIN_USES_GLIBC \ + || !BR2_PACKAGE_XORG7
package/nvidia-tegra23/nvidia-tegra23-binaries/Config.in new file +95 -0
95 lines not on this page · raw message
package/nvidia-tegra23/nvidia-tegra23-binaries/egl.pc new file +10 -0
@@ -0,0 +1,10 @@ +prefix=/usr +exec_prefix=${prefix} +libdir=/usr/lib +includedir=/usr/include + +Name: egl +Description: EGL implementation +Version: 1 +Cflags: -I${includedir}/EGL +Libs: -L${libdir} -lEGL
package/nvidia-tegra23/nvidia-tegra23-binaries/gles.pc new file +10 -0
@@ -0,0 +1,10 @@ +prefix=/usr +exec_prefix=${prefix} +libdir=/usr/lib +includedir=/usr/include + +Name: glesv2 +Description: OpenGL ES 1.1 implementation +Version: 1.1 +Cflags: -I${includedir}/GLES +Libs: -L${libdir} -lGLESv1_CM
package/nvidia-tegra23/nvidia-tegra23-binaries/glesv2.pc new file +10 -0
@@ -0,0 +1,10 @@ +prefix=/usr +exec_prefix=${prefix} +libdir=/usr/lib +includedir=/usr/include + +Name: glesv2 +Description: OpenGL ES 2 implementation +Version: 2 +Cflags: -I${includedir}/GLESv2 +Libs: -L${libdir} -lGLESv2
package/nvidia-tegra23/nvidia-tegra23-binaries/nvidia-tegra23-binaries.hash new file +3 -0
@@ -0,0 +1,3 @@ +# From https://developer.nvidia.com/linux-tegra-rel-16 +sha1 6b57b43f8f9c5b76fa3763144e57c0c16047b1a8 Tegra20_Linux_R16.4.0_armhf.tbz2 +sha1 44e7f84dd6e3b80d37ecddf9cc133031b2653004 Tegra30_Linux_R16.4.0_armhf.tbz2
package/nvidia-tegra23/nvidia-tegra23-binaries/nvidia-tegra23-binaries.mk new file +100 -0
100 lines not on this page · raw message
package/nvidia-tegra23/nvidia-tegra23.mk new file +17 -0
@@ -0,0 +1,17 @@ +################################################################################ +# +# nvidia-tegra23 +# +################################################################################ + +NVIDIA_TEGRA23_SITE = https://developer.nvidia.com/sites/default/files/akamai/mobile/files/L4T +NVIDIA_TEGRA23_VERSION = 16.4.0 + +ifeq ($(BR2_PACKAGE_NVIDIA_TEGRA23_TEGRA2),y) +NVIDIA_TEGRA23_BASE = Tegra20_Linux +endif +ifeq ($(BR2_PACKAGE_NVIDIA_TEGRA23_TEGRA3),y) +NVIDIA_TEGRA23_BASE = Tegra30_Linux +endif + +include $(sort $(wildcard package/nvidia-tegra23/*/*.mk))
Signature · 1 line
1.9.1
PATCH v6 12/14 package/nvidia-tegra23-binaries: new package
Hi Yann,
They are no package khronos-registry-openmax.
I replace it with khronos-registry-openmaxil.
Works fine.
Regards,
Beno?t
2015-01-24 0:24 GMT+01:00 Yann E. MORIN <[email protected]>:
Quoted 429 lines
From: Nicolas Serafini <[email protected]>
This patch adds a new package for all libraries and drivers provided by Nvidia Linux4Tegra release 16.4.0.
We have intermediate .mk and Config.in, because those values will be shared with the codecs package, to come in a follow-up patch, like we have for the Freescale stuff.
Signed-off-by Nicolas Serafini <[email protected]>[yann.morin.1998 at free.fr:
- split jpeg into its own patch
- split codecs and gstreamer plugins out into their own packages
- do not patch for .pc files, just bundle them in $(@D)
]Signed-off-by "Yann E. MORIN" <[email protected]>--- package/Config.in | 1 + package/nvidia-tegra23/Config.in | 36 ++++++++ .../nvidia-tegra23-binaries/Config.in | 95 ++++++++++++++++++++ .../nvidia-tegra23/nvidia-tegra23-binaries/egl.pc | 10 +++ .../nvidia-tegra23/nvidia-tegra23-binaries/gles.pc | 10 +++ .../nvidia-tegra23-binaries/glesv2.pc | 10 +++ .../nvidia-tegra23-binaries.hash | 3 + .../nvidia-tegra23-binaries.mk | 100 +++++++++++++++++++++ package/nvidia-tegra23/nvidia-tegra23.mk | 17 ++++ 9 files changed, 282 insertions(+) create mode 100644 package/nvidia-tegra23/Config.in create mode 100644 package/nvidia-tegra23/nvidia-tegra23-binaries/Config.in create mode 100644 package/nvidia-tegra23/nvidia-tegra23-binaries/egl.pc create mode 100644 package/nvidia-tegra23/nvidia-tegra23-binaries/gles.pc create mode 100644 package/nvidia-tegra23/nvidia-tegra23-binaries/glesv2.pc create mode 100644 package/nvidia-tegra23/nvidia-tegra23-binaries/nvidia-tegra23-binaries.hash create mode 100644 package/nvidia-tegra23/nvidia-tegra23-binaries/ nvidia-tegra23-binaries.mk create mode 100644 package/nvidia-tegra23/nvidia-tegra23.mkpackage/Config.in +1
-0@@ -353,6 +353,7 @@ endif source "package/nanocom/Config.in" source "package/neard/Config.in" source "package/nvidia-driver/Config.in" + source "package/nvidia-tegra23/Config.in" source "package/ofono/Config.in" source "package/ola/Config.in" source "package/on2-8170-modules/Config.in"package/nvidia-tegra23/Config.in new file +36
-0@@ -0,0 +1,36 @@ +menuconfig BR2_PACKAGE_NVIDIA_TEGRA23 + bool "nvidia-tegra23" + depends on BR2_cortex_a9 + depends on BR2_ARM_EABIHF && BR2_TOOLCHAIN_USES_GLIBC + depends on BR2_PACKAGE_XORG7 + help + Install NVidia proprietary blobs to drive Tegra2 or Tegra3 + GPUs found in some mobile-targeted ARM SoCs. + +if BR2_PACKAGE_NVIDIA_TEGRA23 + +choice + prompt "Tegra platform" + help + Select the SOC platform. + +config BR2_PACKAGE_NVIDIA_TEGRA23_TEGRA2 + bool "Tegra 2" + help + NVIDIA Tegra 2 is a dual-core Cortex-A9 without NEON. + +config BR2_PACKAGE_NVIDIA_TEGRA23_TEGRA3 + bool "Tegra 3" + depends on BR2_ARM_CPU_HAS_NEON + help + NVIDIA Tegra 3 is a quad-core Cortex-A9 with NEON. + +endchoice + +source "package/nvidia-tegra23/nvidia-tegra23-binaries/Config.in" +endif + +comment "nvidia-tegra23 needs Xorg and a (e)glibc toolchain w/ EABIhf" + depends on BR2_cortex_a9 + depends on !BR2_ARM_EABIHF || !BR2_TOOLCHAIN_USES_GLIBC \ + || !BR2_PACKAGE_XORG7package/nvidia-tegra23/nvidia-tegra23-binaries/Config.in new file +14
-0@@ -0,0 +1,95 @@ +config BR2_PACKAGE_NVIDIA_TEGRA23_BINARIES + bool "nvidia-tegra23 binaries" + select BR2_PACKAGE_KHRONOS_REGISTRY_KHRPLATFORM + select BR2_PACKAGE_KHRONOS_REGISTRY_OPENGL + select BR2_PACKAGE_KHRONOS_REGISTRY_OPENKODE + select BR2_PACKAGE_KHRONOS_REGISTRY_OPENMAXIL + select BR2_PACKAGE_XLIB_LIBXT + select BR2_PACKAGE_XLIB_LIBXEXT + select BR2_PACKAGE_XLIB_LIBXV + select BR2_PACKAGE_HAS_LIBEGL + select BR2_PACKAGE_HAS_LIBGLES + select BR2_PACKAGE_HAS_LIBOPENMAX + help + Those packages provide libraries, drivers and firmware thatcomes from
package/nvidia-tegra23/nvidia-tegra23-binaries/Config.in new file +81
-0+ NVIDIA Linux For Tegra. + + https://developer.nvidia.com/linux-tegra + +if BR2_PACKAGE_NVIDIA_TEGRA23_BINARIES + +config BR2_PACKAGE_PROVIDES_LIBEGL + default "nvidia-tegra23-binaries" + +config BR2_PACKAGE_PROVIDES_LIBGLES + default "nvidia-tegra23-binaries" + +config BR2_PACKAGE_PROVIDES_LIBOPENMAX + default "nvidia-tegra23-binaries" + +choice + prompt "X11 ABI version" + default BR2_PACKAGE_NVIDIA_TEGRA23_BINARIES_X11ABI_V11 + help + Select Tegra X11 ABI version. + +config BR2_PACKAGE_NVIDIA_TEGRA23_BINARIES_X11ABI_V5 + bool "X11 ABI 5" + help + Tegra X11 ABI 5. + +config BR2_PACKAGE_NVIDIA_TEGRA23_BINARIES_X11ABI_V6 + bool "X11 ABI 6" + help + Tegra X11 ABI 6. + +config BR2_PACKAGE_NVIDIA_TEGRA23_BINARIES_X11ABI_V7 + bool "X11 ABI 7" + help + Tegra X11 ABI 7. + +config BR2_PACKAGE_NVIDIA_TEGRA23_BINARIES_X11ABI_V8 + bool "X11 ABI 8" + help + Tegra X11 ABI 8. + +config BR2_PACKAGE_NVIDIA_TEGRA23_BINARIES_X11ABI_V10 + bool "X11 ABI 10" + help + Tegra X11 ABI 10. + +config BR2_PACKAGE_NVIDIA_TEGRA23_BINARIES_X11ABI_V11 + bool "X11 ABI 11" + help + Tegra X11 ABI 11. + +config BR2_PACKAGE_NVIDIA_TEGRA23_BINARIES_X11ABI_V12 + bool "X11 ABI 12" + help + Tegra X11 ABI 12. + +config BR2_PACKAGE_NVIDIA_TEGRA23_BINARIES_X11ABI_V13 + bool "X11 ABI 13" + help + Tegra X11 ABI 13. + +config BR2_PACKAGE_NVIDIA_TEGRA23_BINARIES_X11ABI_V14 + bool "X11 ABI 14" + help + Tegra X11 ABI 14. + +endchoice + +config BR2_PACKAGE_NVIDIA_TEGRA23_BINARIES_X11ABI + int + default 5 if BR2_PACKAGE_NVIDIA_TEGRA23_BINARIES_X11ABI_V5 + default 6 if BR2_PACKAGE_NVIDIA_TEGRA23_BINARIES_X11ABI_V6 + default 7 if BR2_PACKAGE_NVIDIA_TEGRA23_BINARIES_X11ABI_V7 + default 8 if BR2_PACKAGE_NVIDIA_TEGRA23_BINARIES_X11ABI_V8 + default 10 if BR2_PACKAGE_NVIDIA_TEGRA23_BINARIES_X11ABI_V10 + default 11 if BR2_PACKAGE_NVIDIA_TEGRA23_BINARIES_X11ABI_V11 + default 12 if BR2_PACKAGE_NVIDIA_TEGRA23_BINARIES_X11ABI_V12 + default 13 if BR2_PACKAGE_NVIDIA_TEGRA23_BINARIES_X11ABI_V13 + default 14 if BR2_PACKAGE_NVIDIA_TEGRA23_BINARIES_X11ABI_V14 + +endifpackage/nvidia-tegra23/nvidia-tegra23-binaries/egl.pc new file +10
-0@@ -0,0 +1,10 @@ +prefix=/usr +exec_prefix=${prefix} +libdir=/usr/lib +includedir=/usr/include + +Name: egl +Description: EGL implementation +Version: 1 +Cflags: -I${includedir}/EGL +Libs: -L${libdir} -lEGLpackage/nvidia-tegra23/nvidia-tegra23-binaries/gles.pc new file +10
-0@@ -0,0 +1,10 @@ +prefix=/usr +exec_prefix=${prefix} +libdir=/usr/lib +includedir=/usr/include + +Name: glesv2 +Description: OpenGL ES 1.1 implementation +Version: 1.1 +Cflags: -I${includedir}/GLES +Libs: -L${libdir} -lGLESv1_CMpackage/nvidia-tegra23/nvidia-tegra23-binaries/glesv2.pc new file +10
-0@@ -0,0 +1,10 @@ +prefix=/usr +exec_prefix=${prefix} +libdir=/usr/lib +includedir=/usr/include + +Name: glesv2 +Description: OpenGL ES 2 implementation +Version: 2 +Cflags: -I${includedir}/GLESv2 +Libs: -L${libdir} -lGLESv2diff --git a/package/nvidia-tegra23/nvidia-tegra23-binaries/nvidia-tegra23-binaries.hash b/package/nvidia-tegra23/nvidia-tegra23-binaries/nvidia-tegra23-binaries.hash new file mode 100644
index 0000000..8185593
---/dev/null
+++
b/package/nvidia-tegra23/nvidia-tegra23-binaries/nvidia-tegra23-binaries.hashpackage/nvidia-tegra23/nvidia-tegra23-binaries/glesv2.pc new file +2
-0@@ -0,0 +1,3 @@ +# From https://developer.nvidia.com/linux-tegra-rel-16 +sha1 6b57b43f8f9c5b76fa3763144e57c0c16047b1a8Tegra20_Linux_R16.4.0_armhf.tbz2
+sha144e7f84dd6e3b80d37ecddf9cc133031b2653004
Tegra30_Linux_R16.4.0_armhf.tbz2(quoted diff) +0
-0nvidia-tegra23-binaries.mk
b/package/nvidia-tegra23/nvidia-tegra23-binaries/
nvidia-tegra23-binaries.mk
new file mode 100644
index 0000000..5998bbfpackage/nvidia-tegra23/nvidia-tegra23-binaries/ new file +0
-0nvidia-tegra23-binaries.mk
package/nvidia-tegra23/nvidia-tegra23-binaries/ new file +9
-0@@ -0,0 +1,100 @@ +################################################################################ +# +# nvidia-tegra3-binaries +# +################################################################################ + +NVIDIA_TEGRA23_BINARIES_VERSION = $(NVIDIA_TEGRA23_VERSION) +NVIDIA_TEGRA23_BINARIES_SITE = $(NVIDIA_TEGRA23_SITE) +NVIDIA_TEGRA23_BINARIES_SOURCE =$(NVIDIA_TEGRA23_BASE)_R$(NVIDIA_TEGRA23_BINARIES_VERSION)_armhf.tbz2
package/nvidia-tegra23/nvidia-tegra23-binaries/ new file +2
-0+ +NVIDIA_TEGRA23_BINARIES_LICENSE = License For Customer Use of NVIDIASoftware
package/nvidia-tegra23/nvidia-tegra23-binaries/ new file +21
-0+NVIDIA_TEGRA23_BINARIES_LICENSE_FILES = nv_tegra/LICENSE + +NVIDIA_TEGRA23_BINARIES_INSTALL_STAGING = YES +NVIDIA_TEGRA23_BINARIES_INSTALL_TARGET = YES + +NVIDIA_TEGRA23_BINARIES_DEPENDENCIES = \ + khronos-registry-opengl khronos-registry-openkode \ + khronos-registry-openmax khronos-registry-khrplatform \ + xlib_libX11 xlib_libXext xlib_libXv + +NVIDIA_TEGRA23_BINARIES_PROVIDES = libegl libgles libopenmax + +ifeq ($(BR2_PACKAGE_NVIDIA_TEGRA23_BINARIES_TEGRA2),y) +NVIDIA_TEGRA23_BINARIES_FIRMWARE = \ + nvrm_avp.bin nvavp_vid_ucode_alt.bin nvavp_os_0ff00000.bin \ + nvavp_os_eff00000.bin +endif +ifeq ($(BR2_PACKAGE_NVIDIA_TEGRA23_BINARIES_TEGRA3),y) +NVIDIA_TEGRA23_BINARIES_FIRMWARE = \ + nvrm_avp_0ff00000.bin nvrm_avp_8e000000.bin nvrm_avp_9e000000.bin \ + nvrm_avp_be000000.bin nvrm_avp_eff00000.binnvavp_vid_ucode_alt.bin \
package/nvidia-tegra23/nvidia-tegra23-binaries/ new file +5
-0+ nvavp_os_0ff00000.bin nvavp_os_eff00000.bin +endif + +NVIDIA_TEGRA23_BINARIES_LIBRARIES = \ + libardrv_dynamic.so libcgdrv.so libEGL.so.1 libGLESv1_CM.so.1libGLESv2.so.2 \
package/nvidia-tegra23/nvidia-tegra23-binaries/ new file +3
-0+ libKD.so libnvapputil.so libnvavp.so libnvcwm.so libnvdc.so \ + libnvddk_2d.so libnvddk_2d_v2.so libnvddk_disp.so libnvddk_kbc.so \ + libnvddk_mipihsi.so libnvddk_nand.so libnvddk_se.solibnvddk_snor.so \
+ libnvddk_spif.so libnvddk_usbphy.so libnvdispatch_helper.so
libnvglsi.so \
+ libnvmedia_audio.so libnvmm_audio.so libnvmm_camera.so
libnvmm_contentpipe.so \
+ libnvmm_image.so libnvmmlite_audio.so libnvmmlite_image.so
libnvmmlite.so \
+ libnvmmlite_utils.so libnvmmlite_video.so libnvmm_manager.so
libnvmm_parser.so \
+ libnvmm_service.so libnvmm.so libnvmm_utils.so libnvmm_video.so
libnvmm_writer.so \
+ libnvodm_disp.so libnvodm_dtvtuner.so libnvodm_imager.so
libnvodm_misc.so \
+ libnvodm_query.so libnvomxilclient.so libnvomx.so libnvos.so
libnvparser.so \
+ libnvrm_graphics.so libnvrm.so libnvsm.so libnvtestio.so
libnvtestresults.so \package/nvidia-tegra23/nvidia-tegra23-binaries/ new file +12
-0+ libnvtvmr.so libnvwinsys.so libnvwsi.so + +NVIDIA_TEGRA23_BINARIES_DRV = \ + nv_tegra/nvidia_drivers/usr/lib/xorg/modules/drivers/tegra_drv.abi$(BR2_PACKAGE_NVIDIA_TEGRA23_BINARIES_X11ABI).so + +NVIDIA_TEGRA23_BINARIES_PKGCONFIG = egl.pc gles.pc glesv2.pc + +define NVIDIA_TEGRA23_BINARIES_EXTRACT_FURTHER + $(INSTALL) -d $(@D)/nv_tegra/nvidia_drivers + $(call suitable-extractor,$(@D)/nv_tegra/nvidia_drivers.tbz2) \ + $(@D)/nv_tegra/nvidia_drivers.tbz2 | \ + $(TAR) $(TAR_STRIP_COMPONENTS)=0 -C $(@D)/nv_tegra/nvidia_drivers/$(TAR_OPTIONS) -
package/nvidia-tegra23/nvidia-tegra23-binaries/ new file +2
-0+ $(INSTALL) -d $(@D)/nv_tegra/nv_sample_apps/nvgstapps + $(callsuitable-extractor,$(@D)/nv_tegra/nv_sample_apps/nvgstapps.tbz2) \
package/nvidia-tegra23/nvidia-tegra23-binaries/ new file +2
-0+ $(@D)/nv_tegra/nv_sample_apps/nvgstapps.tbz2 | \ + $(TAR) $(TAR_STRIP_COMPONENTS)=0 -C$(@D)/nv_tegra/nv_sample_apps/nvgstapps/ $(TAR_OPTIONS) -
package/nvidia-tegra23/nvidia-tegra23-binaries/ new file +2
-0+endef +NVIDIA_TEGRA23_BINARIES_POST_EXTRACT_HOOKS +=
NVIDIA_TEGRA23_BINARIES_EXTRACT_FURTHERpackage/nvidia-tegra23/nvidia-tegra23-binaries/ new file +4
-0+ +define NVIDIA_TEGRA23_BINARIES_INSTALL_LIBS + $(foreach lib,$(NVIDIA_TEGRA23_BINARIES_LIBRARIES), + $(INSTALL) -D -m 0644$(@D)/nv_tegra/nvidia_drivers/usr/lib/$(lib) \
package/nvidia-tegra23/nvidia-tegra23-binaries/ new file +13
-0+ $(1)/usr/lib/$(lib); \ + ) + (cd $(1)/usr/lib; \ + ln -sf libGLESv2.so.2 libGLESv2.so; \ + ln -sf libGLESv1_CM.so.1 libGLESv1_CM.so; \ + ln -sf libEGL.so.1 libEGL.so \ + ) +endef + +define NVIDIA_TEGRA23_BINARIES_INSTALL_STAGING_CMDS + $(call NVIDIA_TEGRA23_BINARIES_INSTALL_LIBS,$(STAGING_DIR)) + $(foreach pkgconfig,$(NVIDIA_TEGRA23_BINARIES_PKGCONFIG), + $(INSTALL) -D -m 0644package/nvidia-tegra23/nvidia-tegra23-binaries/$(pkgconfig) \
package/nvidia-tegra23/nvidia-tegra23-binaries/ new file +8
-0+ $(STAGING_DIR)/usr/lib/pkgconfig/$(pkgconfig); \ + ) +endef + +define NVIDIA_TEGRA23_BINARIES_INSTALL_TARGET_CMDS + $(call NVIDIA_TEGRA23_BINARIES_INSTALL_LIBS,$(TARGET_DIR)) + $(foreach firmware,$(NVIDIA_TEGRA23_BINARIES_FIRMWARE), + $(INSTALL) -D -m 0644$(@D)/nv_tegra/nvidia_drivers/lib/firmware/$(firmware) \
package/nvidia-tegra23/nvidia-tegra23-binaries/ new file +3
-0+ $(TARGET_DIR)/lib/firmware/$(firmware); \ + ) + $(INSTALL) -D -m 0644$(@D)/nv_tegra/nvidia_drivers/etc/nv_tegra_release \
package/nvidia-tegra23/nvidia-tegra23-binaries/ new file +6
-0+ $(TARGET_DIR)/etc/nv_tegra_release + $(INSTALL) -D -m 0644 $(@D)/$(NVIDIA_TEGRA23_BINARIES_DRV) \ + $(TARGET_DIR)/usr/lib/xorg/modules/drivers/tegra_drv.so +endef + +$(eval $(generic-package))package/nvidia-tegra23/nvidia-tegra23.mk new file +7
-0@@ -0,0 +1,17 @@ +################################################################################ +# +# nvidia-tegra23 +# +################################################################################ + +NVIDIA_TEGRA23_SITE =https://developer.nvidia.com/sites/default/files/akamai/mobile/files/L4T
package/nvidia-tegra23/nvidia-tegra23.mk new file +10
-1+NVIDIA_TEGRA23_VERSION = 16.4.0 + +ifeq ($(BR2_PACKAGE_NVIDIA_TEGRA23_TEGRA2),y) +NVIDIA_TEGRA23_BASE = Tegra20_Linux +endif +ifeq ($(BR2_PACKAGE_NVIDIA_TEGRA23_TEGRA3),y) +NVIDIA_TEGRA23_BASE = Tegra30_Linux +endif + +include $(sort $(wildcard package/nvidia-tegra23/*/*.mk)) --1.9.1
Quoted 5 lines
_______________________________________________
buildroot mailing list
buildroot at busybox.net
http://lists.busybox.net/mailman/listinfo/buildroot
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.busybox.net/pipermail/buildroot/attachments/20150126/6c198446/attachment.html>
PATCH v6 12/14 package/nvidia-tegra23-binaries: new package
Beno?t, All,
On 2015-01-26 14:31 +0100, Ben Ben spake thusly:
Quoted 2 lines
They are no package khronos-registry-openmax.
I replace it with khronos-registry-openmaxil.
Fixed, thanks for spotting.
Regards,
Yann E. MORIN.
Signature · 6 lines
.-----------------.--------------------.------------------.--------------------. | Yann E. MORIN | Real-Time Embedded | /"\ ASCII RIBBON | Erics' conspiracy: | | +33 662 376 056 | Software Designer | \ / CAMPAIGN | ___ | | +33 223 225 172 `------------.-------: X AGAINST | \e/ There is no | | http://ymorin.is-a-geek.org/ | _/*\_ | / \ HTML MAIL | v conspiracy. | '------------------------------^-------^------------------^--------------------'
PATCH v6 13/14 package.nvidia-tegra23-binaries: add gstreamer plugins
In reply to Yann E. MORINFrom: Nicolas Serafini <[email protected]>
--- .../nvidia-tegra23-binaries/Config.in | 15 +++++++++++ .../nvidia-tegra23-binaries.mk | 30 ++++++++++++++++++++++ 2 files changed, 45 insertions(+)
package/nvidia-tegra23/nvidia-tegra23-binaries/Config.in +15 -0
@@ -92,4 +92,19 @@ config BR2_PACKAGE_NVIDIA_TEGRA23_BINARIES_X11ABI default 13 if BR2_PACKAGE_NVIDIA_TEGRA23_BINARIES_X11ABI_V13 default 14 if BR2_PACKAGE_NVIDIA_TEGRA23_BINARIES_X11ABI_V14 +config BR2_PACKAGE_NVIDIA_TEGRA23_BINARIES_GSTREAMER_PLUGINS + bool "GStreamer 0.10.x plugins" + depends on BR2_PACKAGE_GSTREAMER # Run-time only + help + GStreamer 0.10.x plugins + +config BR2_PACKAGE_NVIDIA_TEGRA23_BINARIES_NV_SAMPLE_APPS + bool "NVIDIA multimedia sample apps" + depends on BR2_PACKAGE_NVIDIA_TEGRA23_BINARIES_GSTREAMER_PLUGINS + help + nvgstplayer and nvgstcapture multimedia test applications. + +comment "GStreamer 0.10.x plugins need GStreamer 0.10" + depends on !BR2_PACKAGE_GSTREAMER + endif
package/nvidia-tegra23/nvidia-tegra23-binaries/nvidia-tegra23-binaries.mk +30 -0
@@ -10,6 +10,10 @@ NVIDIA_TEGRA23_BINARIES_SOURCE = $(NVIDIA_TEGRA23_BASE)_R$(NVIDIA_TEGRA23_BINARI NVIDIA_TEGRA23_BINARIES_LICENSE = License For Customer Use of NVIDIA Software NVIDIA_TEGRA23_BINARIES_LICENSE_FILES = nv_tegra/LICENSE +ifeq ($(BR2_PACKAGE_NVIDIA_TEGRA23_BINARIES_GSTREAMER_PLUGINS),y) +NVIDIA_TEGRA23_BINARIES_LICENSE += LGPLv2.1 +NVIDIA_TEGRA23_BINARIES_LICENSE_FILES += nv_tegra/nv_sample_apps/LICENSE.gst-openmax +endif NVIDIA_TEGRA23_BINARIES_INSTALL_STAGING = YES NVIDIA_TEGRA23_BINARIES_INSTALL_TARGET = YES
@@ -51,6 +55,11 @@ NVIDIA_TEGRA23_BINARIES_LIBRARIES = \ NVIDIA_TEGRA23_BINARIES_DRV = \ nv_tegra/nvidia_drivers/usr/lib/xorg/modules/drivers/tegra_drv.abi$(BR2_PACKAGE_NVIDIA_TEGRA23_BINARIES_X11ABI).so +NVIDIA_TEGRA23_BINARIES_GSTREAMER_PLUGINS = \ + libgstnv4l2.so libgstnvvidconv.so libgstnvxvimagesink.so libgstomx.so + +NVIDIA_TEGRA23_BINARIES_MULTIMEDIA_APPS = nvgstplayer nvgstcapture + NVIDIA_TEGRA23_BINARIES_PKGCONFIG = egl.pc gles.pc glesv2.pc define NVIDIA_TEGRA23_BINARIES_EXTRACT_FURTHER
@@ -77,12 +86,31 @@ define NVIDIA_TEGRA23_BINARIES_INSTALL_LIBS ) endef +ifeq ($(BR2_PACKAGE_NVIDIA_TEGRA23_BINARIES_GSTREAMER_PLUGINS),y) +define NVIDIA_TEGRA23_BINARIES_INSTALL_GST_PLUGINS + $(foreach gst_plug,$(NVIDIA_TEGRA23_BINARIES_GSTREAMER_PLUGINS), + $(INSTALL) -D -m 0644 $(@D)/nv_tegra/nv_sample_apps/nvgstapps/usr/lib/gstreamer-0.10/$(gst_plug) \ + $(1)/usr/lib/gstreamer-0.10/$(gst_plug); \ + ) +endef +endif + +ifeq ($(BR2_PACKAGE_NVIDIA_TEGRA23_BINARIES_NV_SAMPLE_APPS),y) +define NVIDIA_TEGRA23_BINARIES_INSTALL_APPS + $(foreach apps,$(NVIDIA_TEGRA23_BINARIES_MULTIMEDIA_APPS), + $(INSTALL) -D -m 0755 $(@D)/nv_tegra/nv_sample_apps/nvgstapps/usr/bin/$(apps) \ + $(TARGET_DIR)/usr/bin/$(apps); \ + ) +endef +endif + define NVIDIA_TEGRA23_BINARIES_INSTALL_STAGING_CMDS $(call NVIDIA_TEGRA23_BINARIES_INSTALL_LIBS,$(STAGING_DIR)) $(foreach pkgconfig,$(NVIDIA_TEGRA23_BINARIES_PKGCONFIG), $(INSTALL) -D -m 0644 package/nvidia-tegra23/nvidia-tegra23-binaries/$(pkgconfig) \ $(STAGING_DIR)/usr/lib/pkgconfig/$(pkgconfig); \ ) + $(call NVIDIA_TEGRA23_BINARIES_INSTALL_GST_PLUGINS,$(STAGING_DIR)) endef define NVIDIA_TEGRA23_BINARIES_INSTALL_TARGET_CMDS
@@ -95,6 +123,8 @@ define NVIDIA_TEGRA23_BINARIES_INSTALL_TARGET_CMDS $(TARGET_DIR)/etc/nv_tegra_release $(INSTALL) -D -m 0644 $(@D)/$(NVIDIA_TEGRA23_BINARIES_DRV) \ $(TARGET_DIR)/usr/lib/xorg/modules/drivers/tegra_drv.so + $(call NVIDIA_TEGRA23_BINARIES_INSTALL_GST_PLUGINS,$(TARGET_DIR)) + $(NVIDIA_TEGRA23_BINARIES_INSTALL_APPS) endef $(eval $(generic-package))
Signature · 1 line
1.9.1
PATCH v6 14/14 package/nvidia-tegra23-codecs: new package
In reply to Yann E. MORINFrom: Nicolas Serafini <[email protected]>
nvidia-tegra23-codecs provides various HW-accelerated media codecs, such
as: AAC3, h264, jpeg, MP3...
[me:
- split codecs from binaries into this patch
- use our extractor helpers
]
--- package/nvidia-tegra23/Config.in | 1 + .../nvidia-tegra23/nvidia-tegra23-codecs/Config.in | 7 ++++ .../nvidia-tegra23-codecs.hash | 3 ++ .../nvidia-tegra23-codecs/nvidia-tegra23-codecs.mk | 41 ++++++++++++++++++++++ 4 files changed, 52 insertions(+) create mode 100644 package/nvidia-tegra23/nvidia-tegra23-codecs/Config.in create mode 100644 package/nvidia-tegra23/nvidia-tegra23-codecs/nvidia-tegra23-codecs.hash create mode 100644 package/nvidia-tegra23/nvidia-tegra23-codecs/nvidia-tegra23-codecs.mk
package/nvidia-tegra23/Config.in +1 -0
@@ -28,6 +28,7 @@ config BR2_PACKAGE_NVIDIA_TEGRA23_TEGRA3 endchoice source "package/nvidia-tegra23/nvidia-tegra23-binaries/Config.in" +source "package/nvidia-tegra23/nvidia-tegra23-codecs/Config.in" endif comment "nvidia-tegra23 needs Xorg and a (e)glibc toolchain w/ EABIhf"
package/nvidia-tegra23/nvidia-tegra23-codecs/Config.in new file +7 -0
@@ -0,0 +1,7 @@ +config BR2_PACKAGE_NVIDIA_TEGRA23_CODECS + bool "nvidia-tegra23 codecs" + depends on BR2_PACKAGE_NVIDIA_TEGRA23_BINARIES + help + NVIDIA Tegra restricted codecs from Linux For Tegra 16.4.0 + + https://developer.nvidia.com/linux-tegra-rel-16
package/nvidia-tegra23/nvidia-tegra23-codecs/nvidia-tegra23-codecs.hash new file +3 -0
@@ -0,0 +1,3 @@ +# From https://developer.nvidia.com/linux-tegra-rel-16 +sha1 d0889bf0ca408583a1e88657c6fd18f3659ef1bb Tegra20_Linux-codecs_R16.4.0_armhf.tbz2 +sha1 a9f298222d3b6a618ef96a6bed9641929b152c8a Tegra30_Linux-codecs_R16.4.0_armhf.tbz2
package/nvidia-tegra23/nvidia-tegra23-codecs/nvidia-tegra23-codecs.mk new file +41 -0
41 lines not on this page · raw message
Signature · 1 line
1.9.1