From patchwork Thu May 18 18:22:35 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?Daniel_D=C3=ADaz?= X-Patchwork-Id: 100118 Delivered-To: patch@linaro.org Received: by 10.182.142.97 with SMTP id rv1csp803963obb; Thu, 18 May 2017 11:22:49 -0700 (PDT) X-Received: by 10.99.56.81 with SMTP id h17mr5907864pgn.171.1495131769842; Thu, 18 May 2017 11:22:49 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1495131769; cv=none; d=google.com; s=arc-20160816; b=tSGKF+VyXX6nVPqNdRQ1doWkOxFbcp4xvQ6PQrlybUY85ezR5bs/JHsHhmWkxH4dfy xtX1e4/YaYy7iZz3lNHvu6rzQW+U6Dl2dgQgw4J+74IjbLAD+JCbTq1XOGtL9vnmacRI S7FdnSLr15hRdQBtSg/2u9xnF9jubJuvI7RIar+peMqDg0n1v+D5YbwI8ubbZ2k3Zmwt w0CwiAPhPorExdtrk1lfgTyUvBJHrGPMIYm0skdcBGyXCJ/cVp6fX9bVOlpb3vVdqUbC WX0u9BKnsZld19IGYCzjdsW7pbxXNCgqMZ0nokxRR0NCVKA2JryxM9kJkoi89z7miVL1 PT5g== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=errors-to:sender:content-transfer-encoding:list-subscribe:list-help :list-post:list-archive:list-unsubscribe:list-id:precedence:subject :mime-version:message-id:date:to:from:dkim-signature:delivered-to :arc-authentication-results; bh=TIon/aj6lbxhoH+th4WhKwP1o697JBBTl849BH0wh0M=; b=m85388QwsbMrRc1I3yjNoo65up9mrcH/c+YU8OeOm0GbyVn1PsrUp6Jb9Z3Zu5vf5A LzVB9Azk3YNlc4fRFOr9n7GAfFQ8W0dsgUhNEi18I/WpFOyIo6/zLBec3d/52qEoAbxc 0dqv68jsUeXQSOz5qmU0w/ns+pe9ECOCVnhlkTdjRAMdp0AINIBYegQ56/GyARl7jqcr FIUb1W9iMPDvK1/F0ASYmrgilFB2KwLNZhpQ6ldlWOBC8BebRuMLKyaOaKIct+7ofZ5y NaLo635E5HX3q/fGgv69A2c67c3FFk0/kX5DyNoCMs+t2c0qT/sF88dQQ+qXLTk27oA8 ZYtQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=neutral (body hash did not verify) header.i=@linaro.org; spf=pass (google.com: best guess record for domain of openembedded-core-bounces@lists.openembedded.org designates 140.211.169.62 as permitted sender) smtp.mailfrom=openembedded-core-bounces@lists.openembedded.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from mail.openembedded.org (mail.openembedded.org. [140.211.169.62]) by mx.google.com with ESMTP id 62si6303868ple.100.2017.05.18.11.22.49; Thu, 18 May 2017 11:22:49 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of openembedded-core-bounces@lists.openembedded.org designates 140.211.169.62 as permitted sender) client-ip=140.211.169.62; Authentication-Results: mx.google.com; dkim=neutral (body hash did not verify) header.i=@linaro.org; spf=pass (google.com: best guess record for domain of openembedded-core-bounces@lists.openembedded.org designates 140.211.169.62 as permitted sender) smtp.mailfrom=openembedded-core-bounces@lists.openembedded.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from review.yoctoproject.org (localhost [127.0.0.1]) by mail.openembedded.org (Postfix) with ESMTP id 299A078082; Thu, 18 May 2017 18:22:45 +0000 (UTC) X-Original-To: openembedded-core@lists.openembedded.org Delivered-To: openembedded-core@lists.openembedded.org Received: from mail-oi0-f43.google.com (mail-oi0-f43.google.com [209.85.218.43]) by mail.openembedded.org (Postfix) with ESMTP id 36BE77807E for ; Thu, 18 May 2017 18:22:43 +0000 (UTC) Received: by mail-oi0-f43.google.com with SMTP id w10so65141109oif.0 for ; Thu, 18 May 2017 11:22:45 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id:mime-version :content-transfer-encoding; bh=t22SN/Mi5qMM4duCzsAJsKbLiC9LzWNfowoacKODTCI=; b=TrnOrb76JFoe+GG2z8FWZmHrPbw6Wl4Ks3flp2z9G4rQDxm7fb+7BeWYLCWzkTNpAY KhqP61lLoeyrLjDTrkU3G66KfBk5OSjPXUrFy+Ktmw2hqPET37NmlcFg79H4UYPj8HIK 3ctqluL4BxiF3r9Q6eDlextQ1r0/XmIdbG9D4= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:mime-version :content-transfer-encoding; bh=t22SN/Mi5qMM4duCzsAJsKbLiC9LzWNfowoacKODTCI=; b=lmLsLOUD4eGmowPUC86VBOLJUN4Fmmsu4iyzl4QxnW+EtgKGyRBBLoL/71lOh4RmFM H3agluiU1XiaF2c+cWQWb95PVhHY968Zbp7xnSFt8lSbsfmMAZC23OHexd/hi4yc1Xi+ 772PGj6Vp0nP8mEe6+esB/8mY+AgINjVUkaukt9OiJDeF4DZpGPX33JOw6oIc4MkTytT gLln1TCRyiNdfT0x93/ENyqszcZuZtnYThO/bdT9K7opOORR/hM7s14HBO9rq1o+Y+w+ E2qke19MmxGjWl/TntekDunaPq7VFzndLoD/ylWCANPi0mZ1fPZJhbmMB7SvSwpfp93V 7BDg== X-Gm-Message-State: AODbwcDClqK00pZxLdlnM8eDKOt8umy+yK4eMj87XqkCJ3bSDSM2Icbq YB1rKAcYrxyofAzN X-Received: by 10.157.48.116 with SMTP id w49mr3482169otd.142.1495131765152; Thu, 18 May 2017 11:22:45 -0700 (PDT) Received: from aura.cortijodelrio.net (CableLink67-82.telefonia.InterCable.net. [201.172.67.82]) by smtp.googlemail.com with ESMTPSA id c10sm2863501otb.38.2017.05.18.11.22.44 (version=TLS1_2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Thu, 18 May 2017 11:22:44 -0700 (PDT) From: =?utf-8?q?Daniel_D=C3=ADaz?= To: openembedded-core@lists.openembedded.org Date: Thu, 18 May 2017 13:22:35 -0500 Message-Id: <1495131757-7261-1-git-send-email-daniel.diaz@linaro.org> X-Mailer: git-send-email 1.9.1 MIME-Version: 1.0 Subject: [OE-core] [PATCH 1/3] piglit: depend on virtual/egl X-BeenThere: openembedded-core@lists.openembedded.org X-Mailman-Version: 2.1.12 Precedence: list List-Id: Patches and discussions about the oe-core layer List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: openembedded-core-bounces@lists.openembedded.org Errors-To: openembedded-core-bounces@lists.openembedded.org While building for Hikey using Mali 450 driver (r6p0), an error like the following appears while linking: [ 1%] Linking C shared library ../../../../lib/libpiglitutil.so [...] [...]/aarch64-linaro-linux/gcc/aarch64-linaro-linux/6.3.1/ld: cannot find -lEGL collect2: error: ld returned 1 exit status make[2]: *** [lib/libpiglitutil.so.0] Error 1 Mesa generally provides virtual/egl (along with virtual/libgl, which satisfies Piglit's current DEPENDS) but that is not the implementation to use with Mali. Signed-off-by: Daniel Díaz --- meta/recipes-graphics/piglit/piglit_git.bb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/meta/recipes-graphics/piglit/piglit_git.bb b/meta/recipes-graphics/piglit/piglit_git.bb index d6bfb14..eae3eed 100644 --- a/meta/recipes-graphics/piglit/piglit_git.bb +++ b/meta/recipes-graphics/piglit/piglit_git.bb @@ -14,7 +14,7 @@ PV = "1.0+gitr${SRCPV}" S = "${WORKDIR}/git" -DEPENDS = "libpng virtual/libx11 libxkbcommon libxrender waffle virtual/libgl libglu python3-mako-native python3-numpy-native python3-six-native" +DEPENDS = "libpng virtual/libx11 libxkbcommon libxrender waffle virtual/libgl libglu python3-mako-native python3-numpy-native python3-six-native virtual/egl" inherit cmake python3native distro_features_check bash-completion # depends on virtual/libx11 From patchwork Thu May 18 18:22:36 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?Daniel_D=C3=ADaz?= X-Patchwork-Id: 100119 Delivered-To: patch@linaro.org Received: by 10.182.142.97 with SMTP id rv1csp804007obb; Thu, 18 May 2017 11:22:55 -0700 (PDT) X-Received: by 10.99.120.206 with SMTP id t197mr6034822pgc.64.1495131775338; Thu, 18 May 2017 11:22:55 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1495131775; cv=none; d=google.com; s=arc-20160816; b=gCLg59X3RanZ3rwWCGSj6cdxH8O1oYftwCtox2Pi69GbOO3Y8u5o/3GMfLOw6i7TqO o216khI81r7ZrtS4JtqKrktfrYS5I9wrTOkdFeTZfCi1gAiGzbw+LLoPUwaTalX5UGJv vBKxAg/XsfIQ3OmWgcGxKS8MixRLfy6PJRGFPmCjJbMF4a0ACLaF7zlCBDPqFNllNe02 bdh5hhv9Jkf/N5crTqAhgPP1Zq5wUg2Dgp9JzyJ6KDdWxH4V1+KWwQhbYy3/Wqm4JnIf 600kOVE+/KF/t13TPWO/KZ2McW6ivRqQdR8Xfzyt/aTA4riU0jI+MaYWY3LBq9OlchOg iGyw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=errors-to:sender:content-transfer-encoding:list-subscribe:list-help :list-post:list-archive:list-unsubscribe:list-id:precedence:subject :mime-version:references:in-reply-to:message-id:date:to:from :dkim-signature:delivered-to:arc-authentication-results; bh=GeD0LJWO+q+2OJPj/zWBG5C0lP+JV2RFWHGpRz5a8gM=; b=JW2e1+FujN/JGnchjvDyLKYAqbP0t7PFqIYd7lwrSeLIbLRG9zy6ue3UIqcMPcbxtf oKSaFheAmiQgVbZaCLRJfL1bKrcsH9hfkx3/8//kVuD+CaaELfdwIuSe5rZoTYjcxaE5 ct+T0FrnSXF6uPY4RRkhYxHKt1l1EdzK29qMn5XpIx7XRvx9bGl8r2yiu47B/AnWQhDL nh0Pex3Gpo0Yy3fI6gWto6T0WkOyBRVlX50b9O1y9x0DAEk44ackurauxF70fQ7GU0zh BxycHzIjL3OFYwchML5+TZkUKtIhxa3wNrENH7GOsmCLRbqd9aT605Ha9PJPKf1riMe+ 6p4Q== ARC-Authentication-Results: i=1; mx.google.com; dkim=neutral (body hash did not verify) header.i=@linaro.org; spf=pass (google.com: best guess record for domain of openembedded-core-bounces@lists.openembedded.org designates 140.211.169.62 as permitted sender) smtp.mailfrom=openembedded-core-bounces@lists.openembedded.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from mail.openembedded.org (mail.openembedded.org. [140.211.169.62]) by mx.google.com with ESMTP id f12si6020895plm.262.2017.05.18.11.22.55; Thu, 18 May 2017 11:22:55 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of openembedded-core-bounces@lists.openembedded.org designates 140.211.169.62 as permitted sender) client-ip=140.211.169.62; Authentication-Results: mx.google.com; dkim=neutral (body hash did not verify) header.i=@linaro.org; spf=pass (google.com: best guess record for domain of openembedded-core-bounces@lists.openembedded.org designates 140.211.169.62 as permitted sender) smtp.mailfrom=openembedded-core-bounces@lists.openembedded.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from review.yoctoproject.org (localhost [127.0.0.1]) by mail.openembedded.org (Postfix) with ESMTP id BF92378094; Thu, 18 May 2017 18:22:52 +0000 (UTC) X-Original-To: openembedded-core@lists.openembedded.org Delivered-To: openembedded-core@lists.openembedded.org Received: from mail-oi0-f47.google.com (mail-oi0-f47.google.com [209.85.218.47]) by mail.openembedded.org (Postfix) with ESMTP id 9910678088 for ; Thu, 18 May 2017 18:22:51 +0000 (UTC) Received: by mail-oi0-f47.google.com with SMTP id l18so64981679oig.2 for ; Thu, 18 May 2017 11:22:53 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=b9/zWubDRqwIIfH+ecj3X1nA0ZPChi53fOfdY7IkJ50=; b=jmwgOgd/XT/EA97J8fJr1wrqlu9wlbAVlhHJn8aCwo2QTQZqdVUaTsnw44KO1h5+GU 7AMHMPdcQ9Nz5/Kdn2QOfsh1uB63baiyJkqRkFUcQigL8qZpYrn78ChApbo/CKiDV2fP eRY640LOkwXZ3y6tnV7QYMYlLUHzCtFFnRwow= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=b9/zWubDRqwIIfH+ecj3X1nA0ZPChi53fOfdY7IkJ50=; b=XMPvdZ+gmvuKLnmRlyHu+fJfN9tzeeHvY8zWDLhm9hRlhQT4TFi5zCp/BZPX/iXFdV BoQI9lERgrc/PDJTEKRb0PDnlkkd2oVX9UTjpfQNLX4GkwjaAiPsPDtyRpHwRE71qsKA jg/4tQfP9UlRRXlO2BQlwEc6B7ZQj+PyIaNdHJw3aAeJkx/+1s9jmKQf7U05QWLwu6Nd HnPdvBXEPs320NmF0dioBns0O1vaUgnUQtskkzkIvsCPOEcENBkUFbcVtIXiYNo0dTST 73KSXot/HV972Ts1aM+9PvgJIavau0W/YIuCawuQ3TDCtGUq3y/++m3mfdRz8EBNsMQm NmuQ== X-Gm-Message-State: AODbwcA8oi43EWLpFdq0AZ8zDdapLxbdJ8xE4diQZCs4cdJLbynv356c zrdb/R3ofin8Oehg X-Received: by 10.157.12.193 with SMTP id o1mr3299657otd.154.1495131772636; Thu, 18 May 2017 11:22:52 -0700 (PDT) Received: from aura.cortijodelrio.net (CableLink67-82.telefonia.InterCable.net. [201.172.67.82]) by smtp.googlemail.com with ESMTPSA id c10sm2863501otb.38.2017.05.18.11.22.51 (version=TLS1_2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Thu, 18 May 2017 11:22:52 -0700 (PDT) From: =?utf-8?q?Daniel_D=C3=ADaz?= To: openembedded-core@lists.openembedded.org Date: Thu, 18 May 2017 13:22:36 -0500 Message-Id: <1495131757-7261-2-git-send-email-daniel.diaz@linaro.org> X-Mailer: git-send-email 1.9.1 In-Reply-To: <1495131757-7261-1-git-send-email-daniel.diaz@linaro.org> References: <1495131757-7261-1-git-send-email-daniel.diaz@linaro.org> MIME-Version: 1.0 Subject: [OE-core] [PATCH 2/3] piglit: add patch for lack of gbm_bo_map X-BeenThere: openembedded-core@lists.openembedded.org X-Mailman-Version: 2.1.12 Precedence: list List-Id: Patches and discussions about the oe-core layer List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: openembedded-core-bounces@lists.openembedded.org Errors-To: openembedded-core-bounces@lists.openembedded.org [Piglit Bug #100978] -- https://bugs.freedesktop.org/show_bug.cgi?id=100978 When linking against Mali 450 r6, errors like the following can be seen: ../../../../lib/libpiglitutil_gl.so.0: undefined reference to `gbm_bo_unmap' ../../../../lib/libpiglitutil_gl.so.0: undefined reference to `gbm_bo_map' collect2: error: ld returned 1 exit status make[2]: *** [bin/point-sprite] Error 1 This is due to gbm_bo_map() and gbm_bo_unmap() being recently added but not yet implemented by all graphics drivers. Instead of relying on GBM's version, actually try to link against those symbols. Upstream-Status: Submitted [piglit@lists.freedesktop.org] Signed-off-by: Daniel Díaz --- ...fine-GBM_BO_MAP-only-when-symbol-is-found.patch | 48 ++++++++++++++++++++++ 1 file changed, 48 insertions(+) create mode 100644 meta/recipes-graphics/piglit/piglit/0001-CMake-define-GBM_BO_MAP-only-when-symbol-is-found.patch diff --git a/meta/recipes-graphics/piglit/piglit/0001-CMake-define-GBM_BO_MAP-only-when-symbol-is-found.patch b/meta/recipes-graphics/piglit/piglit/0001-CMake-define-GBM_BO_MAP-only-when-symbol-is-found.patch new file mode 100644 index 0000000..0750676 --- /dev/null +++ b/meta/recipes-graphics/piglit/piglit/0001-CMake-define-GBM_BO_MAP-only-when-symbol-is-found.patch @@ -0,0 +1,48 @@ +From 6b6acee8841d092e5066b1bec2ba1c49cce4f91f Mon Sep 17 00:00:00 2001 +From: =?UTF-8?q?Daniel=20D=C3=ADaz?= +Date: Thu, 4 May 2017 00:57:39 -0500 +Subject: [PATCH 1/4] CMake: define GBM_BO_MAP only when symbol is found +MIME-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit + +gbm_bo_map() and _unmap() have been added recently to Mesa, +and this update may not have reached all implementations of +GBM, such as the one provided by Mali r6, where said +definitions can be found in the header file but not in the +library itself. This leads to errors like the following when +linking: + ../../../../lib/libpiglitutil_gl.so.0: undefined reference to `gbm_bo_unmap' + ../../../../lib/libpiglitutil_gl.so.0: undefined reference to `gbm_bo_map' + collect2: error: ld returned 1 exit status + make[2]: *** [bin/point-sprite] Error 1 + +Instead of relying on the header file, actually try to link +using that symbol to determine if PIGLIT_HAS_GBM_BO_MAP +should be defined. + +Signed-off-by: Daniel Díaz +Reviewed-by: Jan Vesely +--- + CMakeLists.txt | 5 +++-- + 1 file changed, 3 insertions(+), 2 deletions(-) + +diff --git a/CMakeLists.txt b/CMakeLists.txt +index a4ff99e..cc26fa8 100644 +--- a/CMakeLists.txt ++++ b/CMakeLists.txt +@@ -141,8 +141,9 @@ IF(${CMAKE_SYSTEM_NAME} MATCHES "Linux") + if(GBM_FOUND) + set(PIGLIT_HAS_GBM True) + add_definitions(-DPIGLIT_HAS_GBM) +- if (GBM_VERSION VERSION_EQUAL "12.1" OR GBM_VERSION VERSION_GREATER "12.1") +- set(PIGLIT_HAS_GBM_BO_MAP True) ++ set(CMAKE_REQUIRED_LIBRARIES ${CMAKE_REQUIRED_LIBRARIES} ${GBM_LIBRARIES}) ++ CHECK_FUNCTION_EXISTS(gbm_bo_map PIGLIT_HAS_GBM_BO_MAP) ++ if (PIGLIT_HAS_GBM_BO_MAP) + add_definitions(-DPIGLIT_HAS_GBM_BO_MAP) + endif() + endif(GBM_FOUND) +-- +1.9.1 + From patchwork Thu May 18 18:22:37 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?Daniel_D=C3=ADaz?= X-Patchwork-Id: 100120 Delivered-To: patch@linaro.org Received: by 10.182.142.97 with SMTP id rv1csp804035obb; Thu, 18 May 2017 11:22:59 -0700 (PDT) X-Received: by 10.84.233.199 with SMTP id m7mr6507717pln.108.1495131779689; Thu, 18 May 2017 11:22:59 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1495131779; cv=none; d=google.com; s=arc-20160816; b=WA6LvQVj6FgVKV7zojnf1fCcKAXawN8Txxil9SRQ4jQXx29fNT+8PsyVTXsCqza/R5 SHVwPmbPq3bLofxCeJeqzSOvKA3hmCRM6C3IsuFS09HK699SepYydPU134A6es4NxSIL QOlry6qHKI/014O+mmvy8sfSrRb90gu3VKxGmVrH5OeBaB2bj8Rzvqsd5pYgcMeVmfeg 80sHirsAibBevELKTmpBovqeFnXKLaT2zUwlK7Nl6pHSdWGQMEa6dD/7MS5hTmb25jEi l8nVb3VOq268ItdeWL1+24Djso2EvQKjMXiB/TQnjIV0OYfY0CjQq3tMaXtldeFGF7/R KvCQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=errors-to:sender:content-transfer-encoding:list-subscribe:list-help :list-post:list-archive:list-unsubscribe:list-id:precedence:subject :mime-version:references:in-reply-to:message-id:date:to:from :dkim-signature:delivered-to:arc-authentication-results; bh=AXKltyQ+CDXE3ZuFGIP4dRalLui70hD+SxBTkaeaLak=; b=Tt6eaJO10anB72VtxF0hX/IqFif2IJtXvi17y15JWMftcX7V+yHBbduTcdg67zY4b3 ykiAmH83BNcvNNyTq/PSJuIqiqzlVWr+uF8VeO0bQH3WgTLelhdBcgn/tzojYorJ8yfX bwHV8ybAiyOlorxf++yNdk1J3lGtLPrzgsREHE5BKFm+E7Blz60aHfyEb3va6J+jJ9Gh rAIiVwKLXBpGeJi07SEmHTIR1CKrN6vXn//bRi75ay9xEGTJOVplHwFFjkYLkvINT/p0 gSIKrHAIxpecCGhYrj4Y3ns/1EhgSxk9Zy2iV0hRCY1VLiL+2AaRSwycHLtE9QO0g/+y FMPQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=neutral (body hash did not verify) header.i=@linaro.org; spf=pass (google.com: best guess record for domain of openembedded-core-bounces@lists.openembedded.org designates 140.211.169.62 as permitted sender) smtp.mailfrom=openembedded-core-bounces@lists.openembedded.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from mail.openembedded.org (mail.openembedded.org. [140.211.169.62]) by mx.google.com with ESMTP id d9si5980489plj.252.2017.05.18.11.22.59; Thu, 18 May 2017 11:22:59 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of openembedded-core-bounces@lists.openembedded.org designates 140.211.169.62 as permitted sender) client-ip=140.211.169.62; Authentication-Results: mx.google.com; dkim=neutral (body hash did not verify) header.i=@linaro.org; spf=pass (google.com: best guess record for domain of openembedded-core-bounces@lists.openembedded.org designates 140.211.169.62 as permitted sender) smtp.mailfrom=openembedded-core-bounces@lists.openembedded.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from review.yoctoproject.org (localhost [127.0.0.1]) by mail.openembedded.org (Postfix) with ESMTP id C03AD780A1; Thu, 18 May 2017 18:22:54 +0000 (UTC) X-Original-To: openembedded-core@lists.openembedded.org Delivered-To: openembedded-core@lists.openembedded.org Received: from mail-oi0-f44.google.com (mail-oi0-f44.google.com [209.85.218.44]) by mail.openembedded.org (Postfix) with ESMTP id 16D427809B for ; Thu, 18 May 2017 18:22:52 +0000 (UTC) Received: by mail-oi0-f44.google.com with SMTP id h4so64969194oib.3 for ; Thu, 18 May 2017 11:22:54 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=0WjNzfrnfKS+I0xhE6IJZh10Fa8UYubJPqrM/FeGeVk=; b=IZ0W9fK1v0NJbMwLRdoHvnUV4MN43kR0wOwm0QLTiOZEv96imjpdARr/3WHRWRbbUe wImb45g7cdgrbu3FZMom0Opz84i0ya6M9FjsNZUQZ5VZAqaBhwh0aXC5hB+03E3qcBEu 0Uf8r2z9w0gYMj62irfMg8CKzFdIaGWToL1eI= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=0WjNzfrnfKS+I0xhE6IJZh10Fa8UYubJPqrM/FeGeVk=; b=s9Jk/fSDoWko4XNLeKQliqLT4EzNifv48jakSdURgrgoo6rg7uRDTmaRXs88x5XcV3 OS3YtAl1c1jhDNKVJ8zwQGgKtlvqrEDjYx0kzL1czAZY8R1cbjxrLCvkuOBBqNQCy/nW T/ff7k9txr6KSWlNReyFdP+eDF6vOe/2PjhMjTP/4yPMWYDoz/VNh5dTL6VvdoUxbfDo dOneEfXql7ZUFZIXhelKxckA3ai/jo1l98Cp5bJnJyY/byelW6TatFkdNJamLVH7Ba91 nlfMSbVMXqnoff33qDjKQLlnxA8Eh+/9WSxS0CBpEND25Obb/xJE9c6yO3BnbVttbDtl srsg== X-Gm-Message-State: AODbwcByptJ+WMT7i9o1tGNpBKlhFfEgArvRna7263UFS22c7b9mxgV9 Abl61r9fPVqoIgfX X-Received: by 10.202.98.68 with SMTP id w65mr3072292oib.173.1495131774045; Thu, 18 May 2017 11:22:54 -0700 (PDT) Received: from aura.cortijodelrio.net (CableLink67-82.telefonia.InterCable.net. [201.172.67.82]) by smtp.googlemail.com with ESMTPSA id c10sm2863501otb.38.2017.05.18.11.22.53 (version=TLS1_2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Thu, 18 May 2017 11:22:53 -0700 (PDT) From: =?utf-8?q?Daniel_D=C3=ADaz?= To: openembedded-core@lists.openembedded.org Date: Thu, 18 May 2017 13:22:37 -0500 Message-Id: <1495131757-7261-3-git-send-email-daniel.diaz@linaro.org> X-Mailer: git-send-email 1.9.1 In-Reply-To: <1495131757-7261-1-git-send-email-daniel.diaz@linaro.org> References: <1495131757-7261-1-git-send-email-daniel.diaz@linaro.org> MIME-Version: 1.0 Subject: [OE-core] [PATCH 3/3] piglit: add patches for unbuildable surfaceless Mesa test X-BeenThere: openembedded-core@lists.openembedded.org X-Mailman-Version: 2.1.12 Precedence: list List-Id: Patches and discussions about the oe-core layer List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: openembedded-core-bounces@lists.openembedded.org Errors-To: openembedded-core-bounces@lists.openembedded.org Some EGL implementations do not actually ship all Khronos- extensions. As it turns out, the Mali 450 driver does not include any of the following symbols, used by the egl_mesa_platform_surfaceless.c spec test: * eglGetPlatformDisplay * eglCreatePlatformPixmapSurface * eglCreatePlatformWindowSurface The Right Thing To Do was to obtain the implementation of these functions (via eglGetProcAddress), as is provided by their EXT counterparts. These are guaranteed to exist since they are required by EGL_EXT_platform_base. Upstream-Status: Submitted [piglit@lists.freedesktop.org] Signed-off-by: Daniel Díaz --- ...nour-Surfaceless-MESA-in-get_default_disp.patch | 48 ++++++++++++++ ...atform_surfaceless-Don-t-use-eglGetPlatfo.patch | 30 +++++++++ ...atform_surfaceless-Use-EXT-functions-for-.patch | 75 ++++++++++++++++++++++ 3 files changed, 153 insertions(+) create mode 100644 meta/recipes-graphics/piglit/piglit/0002-util-egl-Honour-Surfaceless-MESA-in-get_default_disp.patch create mode 100644 meta/recipes-graphics/piglit/piglit/0003-egl_mesa_platform_surfaceless-Don-t-use-eglGetPlatfo.patch create mode 100644 meta/recipes-graphics/piglit/piglit/0004-egl_mesa_platform_surfaceless-Use-EXT-functions-for-.patch diff --git a/meta/recipes-graphics/piglit/piglit/0002-util-egl-Honour-Surfaceless-MESA-in-get_default_disp.patch b/meta/recipes-graphics/piglit/piglit/0002-util-egl-Honour-Surfaceless-MESA-in-get_default_disp.patch new file mode 100644 index 0000000..734de2b --- /dev/null +++ b/meta/recipes-graphics/piglit/piglit/0002-util-egl-Honour-Surfaceless-MESA-in-get_default_disp.patch @@ -0,0 +1,48 @@ +From aa6728cc4941a87e3933c2aa770ab8ae3080b870 Mon Sep 17 00:00:00 2001 +From: =?UTF-8?q?Daniel=20D=C3=ADaz?= +Date: Tue, 16 May 2017 12:37:07 -0500 +Subject: [PATCH 2/4] util/egl: Honour Surfaceless MESA in get_default_display +MIME-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit + +Signed-off-by: Daniel Díaz +--- + tests/util/piglit-util-egl.c | 7 +++++++ + 1 file changed, 7 insertions(+) + +diff --git a/tests/util/piglit-util-egl.c b/tests/util/piglit-util-egl.c +index 106c735..389fe12 100644 +--- a/tests/util/piglit-util-egl.c ++++ b/tests/util/piglit-util-egl.c +@@ -85,6 +85,7 @@ piglit_egl_get_default_display(EGLenum platform) + static bool has_x11 = false; + static bool has_wayland = false; + static bool has_gbm = false; ++ static bool has_surfaceless_mesa = false; + + static EGLDisplay (*peglGetPlatformDisplayEXT)(EGLenum platform, void *native_display, const EGLint *attrib_list); + +@@ -99,6 +100,7 @@ piglit_egl_get_default_display(EGLenum platform) + has_x11 = piglit_is_egl_extension_supported(EGL_NO_DISPLAY, "EGL_EXT_platform_x11"); + has_wayland = piglit_is_egl_extension_supported(EGL_NO_DISPLAY, "EGL_EXT_platform_wayland"); + has_gbm = piglit_is_egl_extension_supported(EGL_NO_DISPLAY, "EGL_EXT_platform_gbm"); ++ has_surfaceless_mesa = piglit_is_egl_extension_supported(EGL_NO_DISPLAY, "EGL_MESA_platform_surfaceless"); + + peglGetPlatformDisplayEXT = (void*) eglGetProcAddress("eglGetPlatformDisplayEXT"); + } +@@ -123,6 +125,11 @@ piglit_egl_get_default_display(EGLenum platform) + return EGL_NO_DISPLAY; + } + break; ++ case EGL_PLATFORM_SURFACELESS_MESA: ++ if (!has_surfaceless_mesa) { ++ return EGL_NO_DISPLAY; ++ } ++ break; + default: + fprintf(stderr, "%s: unrecognized platform %#x\n", __func__, platform); + return EGL_NO_DISPLAY; +-- +1.9.1 + diff --git a/meta/recipes-graphics/piglit/piglit/0003-egl_mesa_platform_surfaceless-Don-t-use-eglGetPlatfo.patch b/meta/recipes-graphics/piglit/piglit/0003-egl_mesa_platform_surfaceless-Don-t-use-eglGetPlatfo.patch new file mode 100644 index 0000000..7ec71dd --- /dev/null +++ b/meta/recipes-graphics/piglit/piglit/0003-egl_mesa_platform_surfaceless-Don-t-use-eglGetPlatfo.patch @@ -0,0 +1,30 @@ +From b02bdbfdba3464ce47f87c04bcd1d35a8fef3f54 Mon Sep 17 00:00:00 2001 +From: =?UTF-8?q?Daniel=20D=C3=ADaz?= +Date: Wed, 17 May 2017 17:53:10 -0500 +Subject: [PATCH 3/4] egl_mesa_platform_surfaceless: Don't use + eglGetPlatformDisplay directly +MIME-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit + +Signed-off-by: Daniel Díaz +--- + .../spec/egl_mesa_platform_surfaceless/egl_mesa_platform_surfaceless.c | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/tests/egl/spec/egl_mesa_platform_surfaceless/egl_mesa_platform_surfaceless.c b/tests/egl/spec/egl_mesa_platform_surfaceless/egl_mesa_platform_surfaceless.c +index 3bbd6aa..81a3919 100644 +--- a/tests/egl/spec/egl_mesa_platform_surfaceless/egl_mesa_platform_surfaceless.c ++++ b/tests/egl/spec/egl_mesa_platform_surfaceless/egl_mesa_platform_surfaceless.c +@@ -31,7 +31,7 @@ test_setup(EGLDisplay *dpy) + + piglit_require_egl_extension(EGL_NO_DISPLAY, "EGL_MESA_platform_surfaceless"); + +- *dpy = eglGetPlatformDisplay(EGL_PLATFORM_SURFACELESS_MESA, NULL, NULL); ++ *dpy = piglit_egl_get_default_display(EGL_PLATFORM_SURFACELESS_MESA); + if (*dpy == EGL_NO_DISPLAY) { + printf("failed to get EGLDisplay\n"); + piglit_report_result(PIGLIT_SKIP); +-- +1.9.1 + diff --git a/meta/recipes-graphics/piglit/piglit/0004-egl_mesa_platform_surfaceless-Use-EXT-functions-for-.patch b/meta/recipes-graphics/piglit/piglit/0004-egl_mesa_platform_surfaceless-Use-EXT-functions-for-.patch new file mode 100644 index 0000000..b3931dd --- /dev/null +++ b/meta/recipes-graphics/piglit/piglit/0004-egl_mesa_platform_surfaceless-Use-EXT-functions-for-.patch @@ -0,0 +1,75 @@ +From f3bb10947a87cc3a59619847f53d47708e10fbb7 Mon Sep 17 00:00:00 2001 +From: =?UTF-8?q?Daniel=20D=C3=ADaz?= +Date: Wed, 17 May 2017 10:51:48 -0500 +Subject: [PATCH 4/4] egl_mesa_platform_surfaceless: Use EXT functions for + surfaces +MIME-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit + +These EXT symbols are guaranteed to exist since they require +EGL_EXT_platform_base. + +Signed-off-by: Daniel Díaz +--- + .../egl_mesa_platform_surfaceless.c | 23 ++++++++++++++++++++-- + 1 file changed, 21 insertions(+), 2 deletions(-) + +diff --git a/tests/egl/spec/egl_mesa_platform_surfaceless/egl_mesa_platform_surfaceless.c b/tests/egl/spec/egl_mesa_platform_surfaceless/egl_mesa_platform_surfaceless.c +index 81a3919..264ed71 100644 +--- a/tests/egl/spec/egl_mesa_platform_surfaceless/egl_mesa_platform_surfaceless.c ++++ b/tests/egl/spec/egl_mesa_platform_surfaceless/egl_mesa_platform_surfaceless.c +@@ -24,6 +24,24 @@ + #include "piglit-util.h" + #include "piglit-util-egl.h" + ++/* Extension function pointers. ++ * ++ * Use prefix 'pegl' (piglit egl) instead of 'egl' to avoid collisions with ++ * prototypes in eglext.h. */ ++EGLSurface (*peglCreatePlatformPixmapSurfaceEXT)(EGLDisplay display, EGLConfig config, ++ NativePixmapType native_pixmap, const EGLint *attrib_list); ++EGLSurface (*peglCreatePlatformWindowSurfaceEXT)(EGLDisplay display, EGLConfig config, ++ NativeWindowType native_window, const EGLint *attrib_list); ++ ++static void ++init_egl_extension_funcs(void) ++{ ++ peglCreatePlatformPixmapSurfaceEXT = (void*) ++ eglGetProcAddress("eglCreatePlatformPixmapSurfaceEXT"); ++ peglCreatePlatformWindowSurfaceEXT = (void*) ++ eglGetProcAddress("eglCreatePlatformWindowSurfaceEXT"); ++} ++ + static void + test_setup(EGLDisplay *dpy) + { +@@ -72,7 +90,7 @@ test_create_window(void *test_data) + + test_setup(&dpy); + +- surf = eglCreatePlatformWindowSurface(dpy, EGL_NO_CONFIG_KHR, ++ surf = peglCreatePlatformWindowSurfaceEXT(dpy, EGL_NO_CONFIG_KHR, + /*native_window*/ NULL, + /*attrib_list*/ NULL); + if (surf) { +@@ -103,7 +121,7 @@ test_create_pixmap(void *test_data) + + test_setup(&dpy); + +- surf = eglCreatePlatformPixmapSurface(dpy, EGL_NO_CONFIG_KHR, ++ surf = peglCreatePlatformPixmapSurfaceEXT(dpy, EGL_NO_CONFIG_KHR, + /*native_window*/ NULL, + /*attrib_list*/ NULL); + if (surf) { +@@ -205,6 +223,7 @@ main(int argc, char **argv) + piglit_report_result(PIGLIT_FAIL); + } + ++ init_egl_extension_funcs(); + result = piglit_run_selected_subtests(subtests, selected_names, + num_selected, result); + piglit_report_result(result); +-- +1.9.1 +