From patchwork Wed May 16 15:51:59 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Gary Bisson X-Patchwork-Id: 914714 Return-Path: X-Original-To: incoming-buildroot@patchwork.ozlabs.org Delivered-To: patchwork-incoming-buildroot@bilbo.ozlabs.org Authentication-Results: ozlabs.org; spf=pass (mailfrom) smtp.mailfrom=busybox.net (client-ip=140.211.166.138; helo=whitealder.osuosl.org; envelope-from=buildroot-bounces@busybox.net; receiver=) Authentication-Results: ozlabs.org; dmarc=none (p=none dis=none) header.from=boundarydevices.com Authentication-Results: ozlabs.org; dkim=fail reason="signature verification failed" (2048-bit key; unprotected) header.d=boundarydevices-com.20150623.gappssmtp.com header.i=@boundarydevices-com.20150623.gappssmtp.com header.b="eJpT1Tjb"; dkim-atps=neutral Received: from whitealder.osuosl.org (smtp1.osuosl.org [140.211.166.138]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id 40mJpx3WwRz9s33 for ; Thu, 17 May 2018 01:52:25 +1000 (AEST) Received: from localhost (localhost [127.0.0.1]) by whitealder.osuosl.org (Postfix) with ESMTP id 5884F86372; Wed, 16 May 2018 15:52:22 +0000 (UTC) X-Virus-Scanned: amavisd-new at osuosl.org Received: from whitealder.osuosl.org ([127.0.0.1]) by localhost (.osuosl.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id I1J4p1mQ4J8G; Wed, 16 May 2018 15:52:17 +0000 (UTC) Received: from ash.osuosl.org (ash.osuosl.org [140.211.166.34]) by whitealder.osuosl.org (Postfix) with ESMTP id E815B86356; Wed, 16 May 2018 15:52:15 +0000 (UTC) X-Original-To: buildroot@lists.busybox.net Delivered-To: buildroot@osuosl.org Received: from fraxinus.osuosl.org (smtp4.osuosl.org [140.211.166.137]) by ash.osuosl.org (Postfix) with ESMTP id 9D61E1C14DD for ; Wed, 16 May 2018 15:52:12 +0000 (UTC) Received: from localhost (localhost [127.0.0.1]) by fraxinus.osuosl.org (Postfix) with ESMTP id 9A1B485ED0 for ; Wed, 16 May 2018 15:52:12 +0000 (UTC) X-Virus-Scanned: amavisd-new at osuosl.org Received: from fraxinus.osuosl.org ([127.0.0.1]) by localhost (.osuosl.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id L-xBF4j_zAfy for ; Wed, 16 May 2018 15:52:11 +0000 (UTC) X-Greylist: from auto-whitelisted by SQLgrey-1.7.6 Received: from mail-wr0-f171.google.com (mail-wr0-f171.google.com [209.85.128.171]) by fraxinus.osuosl.org (Postfix) with ESMTPS id 8FAC385E03 for ; Wed, 16 May 2018 15:52:11 +0000 (UTC) Received: by mail-wr0-f171.google.com with SMTP id p5-v6so1958793wre.12 for ; Wed, 16 May 2018 08:52:11 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=boundarydevices-com.20150623.gappssmtp.com; s=20150623; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=0IEWRoklmiAJTRAZdkBe6ST5nDhdRzB7AKqvPRFfdr8=; b=eJpT1TjbwmkdLoW98NPHT9xqHzzJYxbdQhKt0Yaxc+AszC3WNqCwTAFzrANbJc2zdL Y1AH0u7yYVOhPmhuJLy/cs3CuBJoFDhLqMhn3im7pUo9TtT6DTlhVEj5n8nMUwOIa8V6 FtCTzE/RhSN2p0YStyDa23jdSK4ZWiOwWFpWRKwFSQr/TPguR4bv/MCa7w0nOqkwQgxx IGLBjgKp9grEza/FisHDTj5cFFeEZFK4y/AT4y7OfesMCZas3uQD7OYT/a/+fTrhkgzY CparWbw2jVCYmaCUM3UJKIAmcxho2zecF2iYZWIfDWoUlAaubOMA2ndtC4Alm2Fri0VR hkUQ== 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; bh=0IEWRoklmiAJTRAZdkBe6ST5nDhdRzB7AKqvPRFfdr8=; b=Ysr0oY3EeurPmKeKJtjs1CXwU24wYq7d6FPEK/46G/vnQvZVT2GiWKl/AZs8GKhsWZ pUAhae4YJPKhJMuYMRa7Jb1squ3bj4r3oPqiKlPJ7tpou+I5Bow5UEsv0/OWPDBBdpDM 1nv08UpDX0wkX7/C+Y6RJPr3F/+nEeMLZqLPWV2l4YL+ygdB/TsTsBzC5l1bjwx7WizP CmRTJk3n3VtfQrcHLNgUCaOtC2YjKGvjY8DVxw+j7tfGpRiK/bb/OCo6AYwD3Ls1LVGk XJmRNzlL2auVgQ0BoUlUOje4yEZv7tepG/tBzyYGrfEJN8bi0yCIidGLBUjjQty0Q1Qk YfvQ== X-Gm-Message-State: ALKqPwcBTSmbo+3oiEaTbH8zrYZ1ELumTkeXx0umGPfDxCmCvjDRqzqE mICgRVCfFepdlFIJOEn+kk7pkTfV X-Google-Smtp-Source: AB8JxZrcL3J5cU6S9O3KU0vC78wK/2ep7zAKk5ZkAq2jU6RDp8MeQ6y5Q+8kYNRwEpS+6lqornnmKQ== X-Received: by 2002:adf:e147:: with SMTP id f7-v6mr1171783wri.271.1526485929895; Wed, 16 May 2018 08:52:09 -0700 (PDT) Received: from g751.home (2a01cb040a78e300dd7a6b7c9b688048.ipv6.abo.wanadoo.fr. [2a01:cb04:a78:e300:dd7a:6b7c:9b68:8048]) by smtp.googlemail.com with ESMTPSA id a10-v6sm3214935wri.10.2018.05.16.08.52.09 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Wed, 16 May 2018 08:52:09 -0700 (PDT) From: Gary Bisson To: buildroot@buildroot.org Date: Wed, 16 May 2018 17:51:59 +0200 Message-Id: <20180516155201.10279-2-gary.bisson@boundarydevices.com> X-Mailer: git-send-email 2.17.0 In-Reply-To: <20180516155201.10279-1-gary.bisson@boundarydevices.com> References: <20180516155201.10279-1-gary.bisson@boundarydevices.com> Subject: [Buildroot] [PATCH 1/3] imx-gpu-viv: add Wayland backend option X-BeenThere: buildroot@busybox.net X-Mailman-Version: 2.1.24 Precedence: list List-Id: Discussion and development of buildroot List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: "Yann E . MORIN" , Thomas Petazzoni MIME-Version: 1.0 Errors-To: buildroot-bounces@busybox.net Sender: "buildroot" This package has been tested with Wayland back-end using weston-imx repository on a i.MX6Q Nitrogen6x: https://source.codeaurora.org/external/imx/weston-imx/ (tag rel_imx_4.9.51_8mq_ga to work with both i.MX6 and i.MX8MQ) Weston was started as follows: # export XDG_RUNTIME_DIR=/tmp # weston --tty=1 --device=/dev/fb0 Finally the Vivante sample apps were started from weston-terminal: # cd /usr/share/examples/viv_samples/vdk/ # ./tutorial7 Signed-off-by: Gary Bisson --- package/freescale-imx/imx-gpu-viv/Config.in | 10 +++++++++- package/freescale-imx/imx-gpu-viv/imx-gpu-viv.mk | 10 ++++++++++ 2 files changed, 19 insertions(+), 1 deletion(-) diff --git a/package/freescale-imx/imx-gpu-viv/Config.in b/package/freescale-imx/imx-gpu-viv/Config.in index cf58ad475c..4e753a41f3 100644 --- a/package/freescale-imx/imx-gpu-viv/Config.in +++ b/package/freescale-imx/imx-gpu-viv/Config.in @@ -12,7 +12,7 @@ config BR2_PACKAGE_IMX_GPU_VIV select BR2_PACKAGE_HAS_LIBGLES select BR2_PACKAGE_HAS_LIBOPENVG help - Userspace libraries for Vivante GPU on i.MX6 platforms + Userspace libraries for Vivante GPU on i.MX platforms It contains libraries and headers for GLES, OpenCL, and OpenVG. It also contains a DRI plugin for X11. It also @@ -44,12 +44,20 @@ comment "X11 backend needs Xorg package" config BR2_PACKAGE_IMX_GPU_VIV_OUTPUT_FB bool "Framebuffer" +config BR2_PACKAGE_IMX_GPU_VIV_OUTPUT_WL + bool "Wayland" + # libdrm needed by gbm_viv.so + select BR2_PACKAGE_LIBDRM + select BR2_PACKAGE_WAYLAND + select BR2_PACKAGE_HAS_LIBEGL_WAYLAND + endchoice config BR2_PACKAGE_IMX_GPU_VIV_OUTPUT string default "x11" if BR2_PACKAGE_IMX_GPU_VIV_OUTPUT_X11 default "fb" if BR2_PACKAGE_IMX_GPU_VIV_OUTPUT_FB + default "wl" if BR2_PACKAGE_IMX_GPU_VIV_OUTPUT_WL config BR2_PACKAGE_PROVIDES_LIBEGL default "imx-gpu-viv" diff --git a/package/freescale-imx/imx-gpu-viv/imx-gpu-viv.mk b/package/freescale-imx/imx-gpu-viv/imx-gpu-viv.mk index 0dc2072984..a339c22978 100644 --- a/package/freescale-imx/imx-gpu-viv/imx-gpu-viv.mk +++ b/package/freescale-imx/imx-gpu-viv/imx-gpu-viv.mk @@ -25,6 +25,10 @@ ifeq ($(IMX_GPU_VIV_LIB_TARGET),x11) IMX_GPU_VIV_DEPENDENCIES += xlib_libXdamage xlib_libXext xlib_libXfixes endif +ifeq ($(IMX_GPU_VIV_LIB_TARGET),wl) +IMX_GPU_VIV_DEPENDENCIES += libdrm wayland +endif + define IMX_GPU_VIV_EXTRACT_CMDS $(call FREESCALE_IMX_EXTRACT_HELPER,$(IMX_GPU_VIV_DL_DIR)/$(IMX_GPU_VIV_SOURCE)) endef @@ -62,6 +66,12 @@ define IMX_GPU_VIV_FIXUP_PKGCONFIG endef endif +ifeq ($(IMX_GPU_VIV_LIB_TARGET),wl) +define IMX_GPU_VIV_FIXUP_PKGCONFIG + ln -sf egl_wayland.pc $(@D)/gpu-core/usr/lib/pkgconfig/egl.pc +endef +endif + ifeq ($(IMX_GPU_VIV_LIB_TARGET),x11) define IMX_GPU_VIV_FIXUP_PKGCONFIG for lib in egl gbm glesv1_cm glesv2 vg; do \