[meta-intel] [PATCH 1/8] Separate packagedir for GL components of EMGD BSPs

nitin.a.kamble at intel.com nitin.a.kamble at intel.com
Tue Sep 17 17:05:55 PDT 2013


From: Richard Purdie <richard.purdie at linuxfoundation.org>

When multiple BSPs of the same arch are built in a build directory,
the differences in GL providers such as emgd-driver and mesa causes
rebuild of large set of recipes, as they collide on each other's space
for multiple BSPs. Although this does not impact correctness, it
impacts build performance negatively.

 Richard had an idea of providing separate PACKAGE_DIR to the
colliding recipes to avoid the build area collision. And this approach
significantly reduces the negative impact on the build performance.

Signed-off-by: Nitin A Kamble <nitin.a.kamble at intel.com>
Signed-off-by: Richard Purdie <richard.purdie at linuxfoundation.org>
---
 classes/emgd-gl.bbclass                  | 11 +++++++++++
 conf/machine/include/meta-intel-emgd.inc |  3 +++
 2 files changed, 14 insertions(+)
 create mode 100644 classes/emgd-gl.bbclass
 create mode 100644 conf/machine/include/meta-intel-emgd.inc

diff --git a/classes/emgd-gl.bbclass b/classes/emgd-gl.bbclass
new file mode 100644
index 0000000..ef1df69
--- /dev/null
+++ b/classes/emgd-gl.bbclass
@@ -0,0 +1,11 @@
+# give a different PACKAGE_ARCH to the recipes involved with opengl
+python __anonymous () {
+    provides = set((d.getVar("PROVIDES", True) or "").split())
+    depends = set((d.getVar("DEPENDS", True) or "").split())
+
+    glp = set([ "virtual/libgles1", "virtual/libgles2", "virtual/egl", "virtual/mesa" , "virtual/libgl"])
+    if list(glp & (provides | depends)): # set union & intersection operations
+        # matched
+        d.appendVar("PACKAGE_ARCH", "${GLSUFFIX}")
+    return
+}
diff --git a/conf/machine/include/meta-intel-emgd.inc b/conf/machine/include/meta-intel-emgd.inc
new file mode 100644
index 0000000..7334909
--- /dev/null
+++ b/conf/machine/include/meta-intel-emgd.inc
@@ -0,0 +1,3 @@
+INHERIT += "emgd-gl"
+GLSUFFIX = "-emgd"
+PACKAGE_EXTRA_ARCHS_append = " ${TUNE_PKGARCH}${GLSUFFIX}"
-- 
1.8.1.4




More information about the meta-intel mailing list