From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mga02.intel.com (mga02.intel.com [134.134.136.20]) by yocto-www.yoctoproject.org (Postfix) with ESMTP id 514FCE0027E for ; Mon, 15 Oct 2012 09:11:11 -0700 (PDT) Received: from orsmga001.jf.intel.com ([10.7.209.18]) by orsmga101.jf.intel.com with ESMTP; 15 Oct 2012 09:11:11 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="4.80,588,1344236400"; d="scan'208";a="205845173" Received: from unknown (HELO envy.home) ([10.7.199.53]) by orsmga001.jf.intel.com with ESMTP; 15 Oct 2012 09:11:10 -0700 Message-ID: <507C3568.1010302@intel.com> Date: Mon, 15 Oct 2012 09:10:16 -0700 From: Darren Hart User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:15.0) Gecko/20120911 Thunderbird/15.0.1 MIME-Version: 1.0 To: nitin.a.kamble@intel.com References: <0ef1ee65497461228a3b9da87ba40e120ab9818e.1349998086.git.nitin.a.kamble@intel.com> In-Reply-To: <0ef1ee65497461228a3b9da87ba40e120ab9818e.1349998086.git.nitin.a.kamble@intel.com> Cc: yocto@yoctoproject.org Subject: Re: [PATCHv4 6/8] mesa-dri.bbappend: avoid conflict with emgd-driver-bin X-BeenThere: yocto@yoctoproject.org X-Mailman-Version: 2.1.13 Precedence: list List-Id: Discussion of all things Yocto List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 15 Oct 2012 16:11:11 -0000 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit On 10/11/2012 04:31 PM, nitin.a.kamble@intel.com wrote: > From: Nitin A Kamble > > Extend the mesa-dri recipe from oecore to avoid conflict with > files generated by emgd-driver-bin recipe. > > This extention is needed only when emgd-driver-bin recipe is > included in the target image, so the code is conditional to > run only on the machine with emgd graphics driver. > > The emgd binary driver also provides egl, gles1, gles2 library & headers. > To avoid conflict disable egl, gles1, gles2 from meta-dri if the BSP image > is bundling the emgd driver. > > This commits avoids these build warning > > WARNING: The recipe is trying to install files into a shared area when those files already exist. Those files are: > /srv/home/nitin/build-test-bsps/build-crownbay/tmp/sysroots/crownbay/usr/include/KHR/khrplatform.h > /srv/home/nitin/build-test-bsps/build-crownbay/tmp/sysroots/crownbay/usr/include/EGL/eglplatform.h > /srv/home/nitin/build-test-bsps/build-crownbay/tmp/sysroots/crownbay/usr/include/EGL/eglext.h > /srv/home/nitin/build-test-bsps/build-crownbay/tmp/sysroots/crownbay/usr/include/EGL/egl.h > /srv/home/nitin/build-test-bsps/build-crownbay/tmp/sysroots/crownbay/usr/include/GLES/glplatform.h > /srv/home/nitin/build-test-bsps/build-crownbay/tmp/sysroots/crownbay/usr/include/GLES/gl.h > /srv/home/nitin/build-test-bsps/build-crownbay/tmp/sysroots/crownbay/usr/include/GLES/glext.h > /srv/home/nitin/build-test-bsps/build-crownbay/tmp/sysroots/crownbay/usr/include/GLES2/gl2ext.h > /srv/home/nitin/build-test-bsps/build-crownbay/tmp/sysroots/crownbay/usr/include/GLES2/gl2.h > /srv/home/nitin/build-test-bsps/build-crownbay/tmp/sysroots/crownbay/usr/include/GLES2/gl2platform.h > > This resolves part of the issue reported on the bug: > [Yocto #3238] > > Signed-off-by: Nitin A Kamble > --- > .../recipes-graphics/mesa/mesa-dri_8.0.4.bbappend | 24 ++++++++++++++++++++ > 1 files changed, 24 insertions(+), 0 deletions(-) > create mode 100644 common/recipes-graphics/mesa/mesa-dri_8.0.4.bbappend > > diff --git a/common/recipes-graphics/mesa/mesa-dri_8.0.4.bbappend b/common/recipes-graphics/mesa/mesa-dri_8.0.4.bbappend > new file mode 100644 > index 0000000..6bfa968 > --- /dev/null > +++ b/common/recipes-graphics/mesa/mesa-dri_8.0.4.bbappend > @@ -0,0 +1,24 @@ > + > +# The emgd binary driver also provides egl, gles1, gles2 library & headers. > +# To avoid conflict disable egl, gles1, gles2 from meta-dri if the BSP image > +# is bundling the emgd driver. > + > +python __anonymous () { > + import re > + xserver = d.getVar('XSERVER', True) > + if 'emgd-driver-bin' in xserver.split(' '): > + extra_oeconf = d.getVar('EXTRA_OECONF', True).split() > + take_out = ["--enable-egl", "--enable-gles1", "--enable-gles2"] > + put_in = ["--disable-egl", "--disable-gles1", "--disable-gles2"] > + pattern = re.compile("--with-egl-platforms") > + new_extra_oeconf = [ ] > + for i in extra_oeconf: > + if ( i not in take_out ) and ( not pattern.match(i)): > + new_extra_oeconf.append(i) > + for i in put_in: > + new_extra_oeconf.append(i) > + > + d.setVar('EXTRA_OECONF', ' '.join(new_extra_oeconf)) > + depends = d.getVar('DEPENDS', True) > + d.setVar('DEPENDS', depends + " emgd-driver-bin") Odd mix of whitespace and tabs above. Also, I have to agree with Ross. This places very specific knowledge of an external package in the general purpose recipe. This is opposite of how these things should be built up. -- Darren Hart Intel Open Source Technology Center Yocto Project - Linux Kernel