From patchwork Sat Feb 9 19:04:47 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Khem Raj X-Patchwork-Id: 157936 Delivered-To: patch@linaro.org Received: by 2002:a02:48:0:0:0:0:0 with SMTP id 69csp929896jaa; Sat, 9 Feb 2019 11:05:04 -0800 (PST) X-Google-Smtp-Source: AHgI3Ibl74C/zvvhUhKzjHn0ozAqzIp3+vH0LpTukR7ZyurtZUBbkaXN8JJeik/Tq3AaT22KhCkn X-Received: by 2002:a63:4618:: with SMTP id t24mr11595871pga.316.1549739104467; Sat, 09 Feb 2019 11:05:04 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1549739104; cv=none; d=google.com; s=arc-20160816; b=kJ2APx3/PuMYb2zAYFm7xUEkYp5MLgiVhGA/JQiCHMVWWDYVqD3QAYewJq+lv+zvrp IpVq63CbyX8c4DqiVFjLnzImW7sGA1qqpKeu30vhUdiBOadSH140SLvY+rBI8cC1tvG0 4npkPCO188L6osyd8t7umSer6WEEO0K0JD5PJTr7sXxFbJ2RRSpzPZ6aD3VGoygXCfEq VM78vxTzL+LlB8bOkMEbCEyby2JcyrhSdfGUKGJZ3rMz67jbLWS8Loxogn6muS8fwHOA z0O2qHMu+7n25GVPknf3DZFxv3iv/QOgxowrdFPm+5G/EikTvWZ7TZ5Wqi6BXHFkTZb7 ZHiQ== 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; bh=x8P2YFW9Ba+8A/ahpBO3FexaTeq/5HY+FldsuhPCdqQ=; b=JEzAVo/9vY5xbJ1l4CPefKCvU/WDvPNxBU+4P+35zbP5+Y/hiTsieRcaCe8e9tEDne Q8XWost5IOZHxRosbj/Pi66ZjKVU/OLPCwllcsCd/f8n9PUa4AmxZvygTqdhHSthnKGJ A1wdKLxDJKh/8a+vM/CRlbExSS7/5xQR3Blru3xHpCzXCXX2MoPUFuJa8p3dAgS6/sP0 ZaKow5ly1mHzm4l2woyqMuYHyhhQbv7eEPAx6YBUVNKG4WuASDyDnkDk2VvfQky2rfGu QFBuz2xy+pMf4tkdltFhmMlFyn6ImNLFYyx0vqePHEAG2MzWeGeuSZXHMHWg7KMF2M8r a7wA== ARC-Authentication-Results: i=1; mx.google.com; dkim=neutral (body hash did not verify) header.i=@gmail.com header.s=20161025 header.b=T7a3x+4A; spf=pass (google.com: best guess record for domain of openembedded-devel-bounces@lists.openembedded.org designates 140.211.169.62 as permitted sender) smtp.mailfrom=openembedded-devel-bounces@lists.openembedded.org; dmarc=fail (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Return-Path: Received: from mail.openembedded.org (mail.openembedded.org. [140.211.169.62]) by mx.google.com with ESMTP id 59si1554277plf.72.2019.02.09.11.05.04; Sat, 09 Feb 2019 11:05:04 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of openembedded-devel-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=@gmail.com header.s=20161025 header.b=T7a3x+4A; spf=pass (google.com: best guess record for domain of openembedded-devel-bounces@lists.openembedded.org designates 140.211.169.62 as permitted sender) smtp.mailfrom=openembedded-devel-bounces@lists.openembedded.org; dmarc=fail (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Received: from ec2-34-214-78-129.us-west-2.compute.amazonaws.com (localhost [127.0.0.1]) by mail.openembedded.org (Postfix) with ESMTP id 344A57C5E3; Sat, 9 Feb 2019 19:05:01 +0000 (UTC) X-Original-To: openembedded-devel@lists.openembedded.org Delivered-To: openembedded-devel@lists.openembedded.org Received: from mail-pf1-f173.google.com (mail-pf1-f173.google.com [209.85.210.173]) by mail.openembedded.org (Postfix) with ESMTP id 57DE47C5C8 for ; Sat, 9 Feb 2019 19:04:55 +0000 (UTC) Received: by mail-pf1-f173.google.com with SMTP id j18so3236829pfe.1 for ; Sat, 09 Feb 2019 11:04:56 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=2+k5+z53UV7eDGN3z5MogCivHokon5L/+QcYWnkk9D8=; b=T7a3x+4A1MwqL0SkKwcPQbjqpB5SZN5DZGgHZ4J2tgW0jgButBib99wC1W0K6CkuBl P65LggvLACroFzfTxl6i7hDtXlf2t5Ho+krQek0qjVuB5enkwcl/bQiBo3qKt70PZLh/ 5ocWFDzNdp9YsegDxG+o0o+uU9UTHmCNCjK8IZqKIBRaPHzuDyfu3n08C/B0ay+SnznG cSU4tvxqvtZZYaQGW1O/WcUXj2TZFx9UDHOzMOSG8htrpCr2uUQ8DnshUbDkNEM/0sBj EZAoRuJml1oMkXgOB7DynkILNH3B/+ZfjLpumbAs6xQ7hNOH6uRf/6oXpMlDm84JHBg+ ebMQ== 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=2+k5+z53UV7eDGN3z5MogCivHokon5L/+QcYWnkk9D8=; b=GCebFNKi55fZiVsgjjeDsRASXGf5MyyFDd/l/acImtGSIkbnp82A1oS7dPIqSLcm97 l1V8hphHDmSRWYlRBwfPWUajvcU5V44H0suaDX9uA0+WJ/u/0BG2oOecwivVPcN3zUwf zVKrf4l6wRIqVPfQvYRsCvovGsq31d7aqrHStdI4T8OazmU6PsiUnJgONcXUFtwYK4j9 syYCaZZ6Y1Q7Ez5Cm77Q0gPNEDHeyUIrmtq1eTcsD5HwxOh5LFbd2PAFHqnhnvLPvpZI YNCKIws7/GdNH9jhlGwjGw0Hwju6DBGapeuOtm7A8RCBof6JeTy9o0jLk+MDE5Gcv3aD vNrA== X-Gm-Message-State: AHQUAuZ2KTVAenfXRuXl+vA5k/zPoXK++8PEZKjuitxsZG9mxyS+EFSm zBF1qcpVt193Q5x8snE4ptaQwHcj X-Received: by 2002:a62:f517:: with SMTP id n23mr226828pfh.209.1549739095888; Sat, 09 Feb 2019 11:04:55 -0800 (PST) Received: from apollo.hsd1.ca.comcast.net ([2601:646:8500:6bc6::dc44]) by smtp.gmail.com with ESMTPSA id e21sm27709493pfh.45.2019.02.09.11.04.55 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Sat, 09 Feb 2019 11:04:55 -0800 (PST) From: Khem Raj To: openembedded-devel@lists.openembedded.org Date: Sat, 9 Feb 2019 11:04:47 -0800 Message-Id: <20190209190447.23092-2-raj.khem@gmail.com> X-Mailer: git-send-email 2.20.1 In-Reply-To: <20190209190447.23092-1-raj.khem@gmail.com> References: <20190209190447.23092-1-raj.khem@gmail.com> MIME-Version: 1.0 Subject: [oe] [meta-oe][PATCH 2/2] ftgl: Fix build errors with clang X-BeenThere: openembedded-devel@lists.openembedded.org X-Mailman-Version: 2.1.12 Precedence: list List-Id: Using the OpenEmbedded metadata to build Distributions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: openembedded-devel-bounces@lists.openembedded.org Errors-To: openembedded-devel-bounces@lists.openembedded.org Signed-off-by: Khem Raj --- ...t-to-avoid-implicit-double-to-float-.patch | 38 +++++++++++++++++++ .../recipes-graphics/ftgl/ftgl_2.1.3-rc5.bb | 1 + 2 files changed, 39 insertions(+) create mode 100644 meta-oe/recipes-graphics/ftgl/ftgl/0001-Explicit-typecast-to-avoid-implicit-double-to-float-.patch -- 2.20.1 -- _______________________________________________ Openembedded-devel mailing list Openembedded-devel@lists.openembedded.org http://lists.openembedded.org/mailman/listinfo/openembedded-devel diff --git a/meta-oe/recipes-graphics/ftgl/ftgl/0001-Explicit-typecast-to-avoid-implicit-double-to-float-.patch b/meta-oe/recipes-graphics/ftgl/ftgl/0001-Explicit-typecast-to-avoid-implicit-double-to-float-.patch new file mode 100644 index 0000000000..385bff8dd1 --- /dev/null +++ b/meta-oe/recipes-graphics/ftgl/ftgl/0001-Explicit-typecast-to-avoid-implicit-double-to-float-.patch @@ -0,0 +1,38 @@ +From e3bce98a60d6db3b719bbf5d71f732f9b86cb566 Mon Sep 17 00:00:00 2001 +From: Khem Raj +Date: Sat, 9 Feb 2019 08:28:09 -0800 +Subject: [PATCH] Explicit typecast to avoid implicit double to float + conversion + +fixes compile errors e.g. + +../../ftgl-2.1.3~rc5/demo/simple.cpp:110:27: error: non-constant-expression cannot be narrowed from type 'double' to + 'float' in initializer list [-Wc++11-narrowing] + (t3 + 2.0) / 3, 0.3 }; + ^~~~~~~~~~~~~~ +Upstream-Status: Pending +Signed-off-by: Khem Raj +--- + demo/simple.cpp | 6 +++--- + 1 file changed, 3 insertions(+), 3 deletions(-) + +diff --git a/demo/simple.cpp b/demo/simple.cpp +index 532e862..aba55b4 100644 +--- a/demo/simple.cpp ++++ b/demo/simple.cpp +@@ -105,9 +105,9 @@ static void RenderScene(void) + float t2 = sin(n / 50 + 1); + float t3 = sin(n / 30 + 2); + +- float ambient[4] = { (t1 + 2.0) / 3, +- (t2 + 2.0) / 3, +- (t3 + 2.0) / 3, 0.3 }; ++ float ambient[4] = { float(t1 + 2.0) / 3, ++ float(t2 + 2.0) / 3, ++ float(t3 + 2.0) / 3, 0.3 }; + float diffuse[4] = { 1.0, 0.9, 0.9, 1.0 }; + float specular[4] = { 1.0, 0.7, 0.7, 1.0 }; + float position[4] = { 100.0, 100.0, 0.0, 1.0 }; +-- +2.20.1 + diff --git a/meta-oe/recipes-graphics/ftgl/ftgl_2.1.3-rc5.bb b/meta-oe/recipes-graphics/ftgl/ftgl_2.1.3-rc5.bb index 4af3803f1a..b2911595cc 100644 --- a/meta-oe/recipes-graphics/ftgl/ftgl_2.1.3-rc5.bb +++ b/meta-oe/recipes-graphics/ftgl/ftgl_2.1.3-rc5.bb @@ -14,6 +14,7 @@ SRC_URI = " \ ${SOURCEFORGE_MIRROR}/${BPN}/${BPN}-${PV}.tar.bz2 \ file://0001-use-pkg-config-to-find-freetype2.patch \ file://0002-Makefile.am-remove-useless-and-breaking-code.patch \ + file://0001-Explicit-typecast-to-avoid-implicit-double-to-float-.patch \ " SRC_URI[md5sum] = "c7879018cde844059495b3029b0b6503" SRC_URI[sha256sum] = "521ff7bd62c459ff5372e269c223e2a6107a6a99a36afdc2ae634a973af70c59"