From patchwork Mon Sep 10 05:06:20 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Khem Raj X-Patchwork-Id: 146269 Delivered-To: patch@linaro.org Received: by 2002:a2e:1648:0:0:0:0:0 with SMTP id 8-v6csp2077950ljw; Sun, 9 Sep 2018 22:07:02 -0700 (PDT) X-Google-Smtp-Source: ANB0VdbwO+e698NlruJ9ZTopeCbEVVuByaecrexxm2ROoVwQF/mtzVy7XuUFGa4bWjFQJGJHeZto X-Received: by 2002:a63:da04:: with SMTP id c4-v6mr20954651pgh.398.1536556022299; Sun, 09 Sep 2018 22:07:02 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1536556022; cv=none; d=google.com; s=arc-20160816; b=ITuZHZwB7XpWYfrIThH+OMZJNQHzpWYfdz35MdZKWisDeQm0VFu+lORIZ06YxX6A1s xjRQ625hYiaIq5lkRlQYejALuSraPRwZcwC0AqIe9A9Z/5SBY8CQP7ko3SvBHEqLX5Od 9N2gR6bpZm5vEZXkf595PrqsF+qeaYrl8Pqi7sud+iQfWVT/+5j2otjhr0ml5ZvzF4zQ e4XN4Uwg8uJAl8CvTk+gHArbmb7MpWwquQhD///ExzPJNM83Fmw76iRMj6ktH9Z4BdRd HnYlUoZEKYyhT6qvSbXwb/xlXKN9BDNMoxv9XDknAhUmk3hdLbYgFxJtiMTQNUjNGynm WqWQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=errors-to:sender:content-transfer-encoding:mime-version :list-subscribe:list-help:list-post:list-archive:list-unsubscribe :list-id:precedence:subject:message-id:date:to:from:dkim-signature :delivered-to; bh=7vGpxBj2OvNDf3MpcU8Arxz1VQlgH/xUkVfei1FtAOM=; b=yYCAUXjVwW3p/ehxioKcdjefYEpWCyCKaA++uA+2qfRhcRExLaOZzRHjSM//lqd4V2 ZD+o2gVEtx5fCGnKPLI5o26P9+vemdW8umKsr/ZEgXAyP8XjabteuTU+u49q7O2lQfFI cpyZjKIcpPqIQnPUENLleKkFTCdU+GTXislbjmjAS/IYFzJLMmyj2YrV8dlqFzPgXu0q rbo9FSQqOsPpZLmSHGGoVoKmvZyZM27rIjjdlj+94Br+kAx5n5eMaWdaa2xkGk5wHG5c 2T2TjN9K/2nFxwUGHyMogqg1U06niE/wSTMIotPNt5tksvJsvma2FBCBWLXGNJEMTBjc bgKA== ARC-Authentication-Results: i=1; mx.google.com; dkim=neutral (body hash did not verify) header.i=@gmail.com header.s=20161025 header.b=Dx+mYOLQ; 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 j193-v6si14910967pge.617.2018.09.09.22.07.01; Sun, 09 Sep 2018 22:07:02 -0700 (PDT) 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=Dx+mYOLQ; 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 layers.openembedded.org (localhost [127.0.0.1]) by mail.openembedded.org (Postfix) with ESMTP id 33F997969B; Mon, 10 Sep 2018 05:06:56 +0000 (UTC) X-Original-To: openembedded-devel@lists.openembedded.org Delivered-To: openembedded-devel@lists.openembedded.org Received: from mail-pl1-f176.google.com (mail-pl1-f176.google.com [209.85.214.176]) by mail.openembedded.org (Postfix) with ESMTP id B5F4C744DB for ; Mon, 10 Sep 2018 05:06:38 +0000 (UTC) Received: by mail-pl1-f176.google.com with SMTP id j8-v6so9147803pll.12 for ; Sun, 09 Sep 2018 22:06:40 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:date:message-id; bh=VSdFrNy7TLBc5OYVvHFPrskF1FGNWezOzqlkS5w5dnk=; b=Dx+mYOLQmRFPFWPE0O+ThtsJf1Tws66Gt/J72yZJYMOJmlOQLNEsTu3hE9cq5YgAVy 4NVilw42OTySEDyBbSp40orRIsy0s9ii32qtiFKGjy+pLGUtykTELFD7gzfNKxm15Qai Q1fhBwTn+yq+PKuhIKeX6M0bgkJPvTXIxF+s4PGyz6d+R/iGduGBnAXBBqk0/wfZfVLC 4MZ1MgbBRHdcVkCMge5TXvoP0/XrgeogdU9oTg13AKve+oPvX46rHxqY/UGep1IrEXKC anO0xcK8ruxpfLkly7/96sV9myVf5U32kZuoIYqaNsKhcSk8zHx7CgNXWBlATcu87Tou 47Lg== 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; bh=VSdFrNy7TLBc5OYVvHFPrskF1FGNWezOzqlkS5w5dnk=; b=DgfQvxXGVRmNXu9HbvHgj01nmK8xEWTlqpoqDdgcTnFhNz5iFta79iJFJIVepmALwj jDJxN76quRFySw3F3mfAeXjAbLTScmXqJXHWWZRpl3IqOxZCUGGc2DzWKouZg/k6rEo9 ouWPfJfFqRJKIEMLnyVAKFU7AsUFwwm80/N1Y8JDWu5iXR0cWQ5Ua0e3hzRFfW7HqCrG Pe+AJGPU5eHa/1ftFaC9TW3FuO86o5d0rSm3MMZlg8FEzMCV+f8Ct/oq+wdU87xk3Jzr /YSH5qIazsyFgwlcu20Lfbngs9bgKASPLiT2vQXS8oNjpyQm9j5ABZxL792SOhSGQNX2 at7g== X-Gm-Message-State: APzg51AWa/8uznokwINOVsLP6ZU8oxbB793W61VhUCtPJRfz1yj2h7mz D7f/38iMhIHJOU8f/uYTX+UZCELY X-Received: by 2002:a17:902:8506:: with SMTP id bj6-v6mr19563558plb.210.1536555999022; Sun, 09 Sep 2018 22:06:39 -0700 (PDT) Received: from localhost.localdomain ([2601:646:877f:9499::2887]) by smtp.gmail.com with ESMTPSA id x24-v6sm18819188pfh.67.2018.09.09.22.06.38 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Sun, 09 Sep 2018 22:06:38 -0700 (PDT) From: Khem Raj To: openembedded-devel@lists.openembedded.org Date: Sun, 9 Sep 2018 22:06:20 -0700 Message-Id: <20180910050629.16170-1-raj.khem@gmail.com> X-Mailer: git-send-email 2.18.0 Subject: [oe] [meta-xfce][PATCH 01/10] xfce4-vala: Build for vala 0.42 to match oe-core 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: , MIME-Version: 1.0 Sender: openembedded-devel-bounces@lists.openembedded.org Errors-To: openembedded-devel-bounces@lists.openembedded.org Signed-off-by: Khem Raj --- meta-xfce/recipes-bindings/vala/xfce4-vala_4.10.3.bb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) -- 2.18.0 -- _______________________________________________ Openembedded-devel mailing list Openembedded-devel@lists.openembedded.org http://lists.openembedded.org/mailman/listinfo/openembedded-devel diff --git a/meta-xfce/recipes-bindings/vala/xfce4-vala_4.10.3.bb b/meta-xfce/recipes-bindings/vala/xfce4-vala_4.10.3.bb index 388659f20b..97007bec4c 100644 --- a/meta-xfce/recipes-bindings/vala/xfce4-vala_4.10.3.bb +++ b/meta-xfce/recipes-bindings/vala/xfce4-vala_4.10.3.bb @@ -11,7 +11,7 @@ SRC_URI = "http://archive.xfce.org/src/bindings/${BPN}/${@xfce_verdir("${PV}")}/ SRC_URI[md5sum] = "0bbb1d6e473e0fe9b335b7b1b49d8a71" SRC_URI[sha256sum] = "07a8f2b7c09fcdd3d86e0c52adea3c58ca011d0142a93997a01b4af77260ae7b" -EXTRA_OECONF = "-with-vala-api=0.40" +EXTRA_OECONF = "-with-vala-api=0.42" FILES_${PN} += "${datadir}/vala-*/vapi" From patchwork Mon Sep 10 05:06:21 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Khem Raj X-Patchwork-Id: 146270 Delivered-To: patch@linaro.org Received: by 2002:a2e:1648:0:0:0:0:0 with SMTP id 8-v6csp2078338ljw; Sun, 9 Sep 2018 22:07:34 -0700 (PDT) X-Google-Smtp-Source: ANB0VdYl678oYhg0LgLict4g/Hge8HlW9vF2QJe1xywrOFFSDiQqEFRC1g/zRwowmvXO33yUKIvz X-Received: by 2002:a63:115f:: with SMTP id 31-v6mr20555328pgr.53.1536556054363; Sun, 09 Sep 2018 22:07:34 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1536556054; cv=none; d=google.com; s=arc-20160816; b=RQNobiD4YY8SGDOUdZ8v+PEZ9ttwHw+k9ktIApaYn57MPaONpdEaeF3KMZhrGVuKQT 9RuI0WC3KD73utzfAQeNBtQQ1bh5glVFOc5GnMG5QQ0hDeh2+C/aLfMr+app04yFn+yQ 33/21dGOJAshYJRUcT00cT+fF/t2p3oatsST2/8Sxh0psU3etGRhaHPR22WDPulO55u3 2KwT5TXWwcZadVvpCm48p1/IeUjxtwjcY+jyXE9J+QxpaI/uaNAkzMoso+9gJE/8zEF/ EpcutmlLZM2vD8KoiFXwI9lTPjEq2KrmrlMeF9JM1lTCEGg8aRnaWgPOK2k+QRmq2YMt Q5/g== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=errors-to:sender:content-transfer-encoding:mime-version :list-subscribe:list-help:list-post:list-archive:list-unsubscribe :list-id:precedence:subject:references:in-reply-to:message-id:date :to:from:dkim-signature:delivered-to; bh=KSLZ3Vwc4UEj4YUaj8hE8+LWqPmzwUW7K5E7u/PqqRg=; b=NNDRAlsAvicb6gBjZJ/QBSol3L3gi6fKs+yuc+V0hK7OHYILIJkujmFGdE1fmJT2v1 FjUItYsK5Japj0f+kgp14My7atojHvReYeIPpiH4CbCRdaL7Rf/JV+6Q/WmvkGfr3u03 xDzeCYezEesM72jm6verZYzeM0+LH6dJLbbIwz1vntMmuy16uP4Kxc5oLLf7Pp5/zWOf jPQ4etnI5zpILx0FY3R0oCXGJdLRKCjt9umfBJt5somx0QyJ4sNFgKm/792QSNlxYqbV A8haH+PwOa6HdFR+m1MRPvRCz+2ENdPo47lqzWO+KX6ZIdscaeqbYwZ0HngDs0SfNCKN mkHA== ARC-Authentication-Results: i=1; mx.google.com; dkim=neutral (body hash did not verify) header.i=@gmail.com header.s=20161025 header.b=sKOW3FWY; 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 t18-v6si14804220plo.191.2018.09.09.22.07.34; Sun, 09 Sep 2018 22:07:34 -0700 (PDT) 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=sKOW3FWY; 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 layers.openembedded.org (localhost [127.0.0.1]) by mail.openembedded.org (Postfix) with ESMTP id 3B204796F3; Mon, 10 Sep 2018 05:07:31 +0000 (UTC) X-Original-To: openembedded-devel@lists.openembedded.org Delivered-To: openembedded-devel@lists.openembedded.org Received: from mail-pl1-f181.google.com (mail-pl1-f181.google.com [209.85.214.181]) by mail.openembedded.org (Postfix) with ESMTP id 43324753D4 for ; Mon, 10 Sep 2018 05:06:39 +0000 (UTC) Received: by mail-pl1-f181.google.com with SMTP id ba4-v6so9149954plb.11 for ; Sun, 09 Sep 2018 22:06:40 -0700 (PDT) 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; bh=Ghepz7qLAKgkzzV46OFOK/q1OgkhYSDmRd+4Gunuhog=; b=sKOW3FWY4d/NHitzHYUl39WjTnpNCwIrHTUkQBbv2bse/TI30h3rXTF4JIXVx9CGdN UCSYBKSi7jmJ7Of/D/rpjOmmTKgNonleuHjt25/m+hZ/XZmIkNHqOverWhNcld3P7Uvn gKrR2DcAcL7DckKLtDyAdl18h7Y8FJR0Gnud3seFkVnw35gM76uDgWS+U2TkczcsV/q1 kZJ0LtUtFMhAzz4nf7QZ2bqWTawZ6aGMNHKu1FWUqKeWAdgwgxcwdk0d0EErHwBwnl0a oqlsCBYJt10vDh/Hug+Sf0MaOye2mHc5LE/0pGQ1wg5pXOnCPYm2IRmtNEtdCw6gyzdQ STDw== 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=Ghepz7qLAKgkzzV46OFOK/q1OgkhYSDmRd+4Gunuhog=; b=dmNIusdc8XDWD/vRH0Rj9Z89VGlmOQKZDxZN/7c+pBGo/nVfEGEZ1CXQcHaMxGra4f vWHXzE7y+s02y43YMbloo2ubDcYQ3RbeoESMmSNJ8WVdthPpBkvtzG7b6RjpsYiomO5O 7qMTzYdJ296O/qV+RGFJvrXbTxc2AC/39xkCkaCdwGaMSqGMHdI4KMhC8BNjTIkAb7UQ NHMmxSY7TaXL0QaDovKU8MIyZAi7FXgWwRSK0chR0jKud1FpTepU3QkHkAUSP7iIH2f9 FvbDU4YCcBZZf/4ncrhqY94Yt89ndjdN3Xzij48UpJFyYTX5W7HBBd21ieYIRQNcZe2z 1n6Q== X-Gm-Message-State: APzg51Bm26alRU+ArlrKvEG3gYcus9o+KCorttcaCAHu4cqbro8/b788 ct/uaylG2zpJhhfzJbE/aJo+6+GA X-Received: by 2002:a17:902:d917:: with SMTP id c23-v6mr19962394plz.65.1536555999849; Sun, 09 Sep 2018 22:06:39 -0700 (PDT) Received: from localhost.localdomain ([2601:646:877f:9499::2887]) by smtp.gmail.com with ESMTPSA id x24-v6sm18819188pfh.67.2018.09.09.22.06.39 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Sun, 09 Sep 2018 22:06:39 -0700 (PDT) From: Khem Raj To: openembedded-devel@lists.openembedded.org Date: Sun, 9 Sep 2018 22:06:21 -0700 Message-Id: <20180910050629.16170-2-raj.khem@gmail.com> X-Mailer: git-send-email 2.18.0 In-Reply-To: <20180910050629.16170-1-raj.khem@gmail.com> References: <20180910050629.16170-1-raj.khem@gmail.com> Subject: [oe] [meta-oe][PATCH V2 02/10] uftrace: Upgrade to 0.8.3 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: , MIME-Version: 1.0 Sender: openembedded-devel-bounces@lists.openembedded.org Errors-To: openembedded-devel-bounces@lists.openembedded.org * Deliberately provide a non existing path to with_elfutils so it does not copy libelf.so into its staged install and become a provider for that library while elfutils should be the legit provider and this package should just list it in its rdeps * Fix build with musl Signed-off-by: Khem Raj --- V2: Fix build with musl ...001-include-dlfcn.h-for-RTLD_DEFAULT.patch | 39 +++++++++++++++++++ .../{uftrace_0.8.bb => uftrace_0.8.3.bb} | 12 ++++-- 2 files changed, 47 insertions(+), 4 deletions(-) create mode 100644 meta-oe/recipes-devtools/uftrace/uftrace/0001-include-dlfcn.h-for-RTLD_DEFAULT.patch rename meta-oe/recipes-devtools/uftrace/{uftrace_0.8.bb => uftrace_0.8.3.bb} (65%) -- 2.18.0 -- _______________________________________________ Openembedded-devel mailing list Openembedded-devel@lists.openembedded.org http://lists.openembedded.org/mailman/listinfo/openembedded-devel diff --git a/meta-oe/recipes-devtools/uftrace/uftrace/0001-include-dlfcn.h-for-RTLD_DEFAULT.patch b/meta-oe/recipes-devtools/uftrace/uftrace/0001-include-dlfcn.h-for-RTLD_DEFAULT.patch new file mode 100644 index 0000000000..fe7aac9318 --- /dev/null +++ b/meta-oe/recipes-devtools/uftrace/uftrace/0001-include-dlfcn.h-for-RTLD_DEFAULT.patch @@ -0,0 +1,39 @@ +From cdf7f2e394fcfb93a61f509ae3388f29540a6b35 Mon Sep 17 00:00:00 2001 +From: Khem Raj +Date: Sat, 8 Sep 2018 11:56:13 -0700 +Subject: [PATCH] include dlfcn.h for RTLD_DEFAULT + +Fixes +plthook.c:128:41: error: use of undeclared identifier 'RTLD_DEFAULT' + +Upstream-Status: Submitted [https://github.com/namhyung/uftrace/pull/487] +Signed-off-by: Khem Raj +--- + libmcount/plthook.c | 1 + + utils/debug.c | 1 + + 2 files changed, 2 insertions(+) + +diff --git a/libmcount/plthook.c b/libmcount/plthook.c +index d9d84f0..d54f5e8 100644 +--- a/libmcount/plthook.c ++++ b/libmcount/plthook.c +@@ -6,6 +6,7 @@ + #include + #include + #include ++#include + + /* This should be defined before #include "utils.h" */ + #define PR_FMT "mcount" +diff --git a/utils/debug.c b/utils/debug.c +index 2134b09..5460def 100644 +--- a/utils/debug.c ++++ b/utils/debug.c +@@ -13,6 +13,7 @@ + #include + #include + #include ++#include + + #include "utils/utils.h" + diff --git a/meta-oe/recipes-devtools/uftrace/uftrace_0.8.bb b/meta-oe/recipes-devtools/uftrace/uftrace_0.8.3.bb similarity index 65% rename from meta-oe/recipes-devtools/uftrace/uftrace_0.8.bb rename to meta-oe/recipes-devtools/uftrace/uftrace_0.8.3.bb index 82b179521c..e377a5c9d5 100644 --- a/meta-oe/recipes-devtools/uftrace/uftrace_0.8.bb +++ b/meta-oe/recipes-devtools/uftrace/uftrace_0.8.3.bb @@ -10,15 +10,19 @@ DEPENDS_append_libc-musl = " argp-standalone" inherit autotools -SRCREV = "5af9ff9fa89c340617e52c8ed05798b352a7145c" -SRC_URI = "git://github.com/namhyung/${BPN}" +# v0.8.3 +SRCREV = "8b723a6fae2ef30495cd6279774fba9c95cd9c88" +SRC_URI = "git://github.com/namhyung/${BPN} \ + file://0001-include-dlfcn.h-for-RTLD_DEFAULT.patch \ + " S = "${WORKDIR}/git" LDFLAGS_append_libc-musl = " -largp" -EXTRA_OECONF = "ARCH=${TARGET_ARCH}" +EXTRA_UFTRACE_OECONF = "ARCH=${TARGET_ARCH} \ + with_elfutils=/use/libelf/from/sysroot" do_configure() { - ${S}/configure ${EXTRA_OECONF} + ${S}/configure ${EXTRA_UFTRACE_OECONF} } FILES_SOLIBSDEV = "" From patchwork Mon Sep 10 05:06:22 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Khem Raj X-Patchwork-Id: 146271 Delivered-To: patch@linaro.org Received: by 2002:a2e:1648:0:0:0:0:0 with SMTP id 8-v6csp2078427ljw; Sun, 9 Sep 2018 22:07:42 -0700 (PDT) X-Google-Smtp-Source: ANB0VdZJMTm73SKt/TX4CPmnU6N6aSfNZoV+Rt+9pifQ90o7AAnQ3gnCIy+0IZvYAnxLo9Sopirz X-Received: by 2002:a62:6eca:: with SMTP id j193-v6mr21736153pfc.256.1536556062789; Sun, 09 Sep 2018 22:07:42 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1536556062; cv=none; d=google.com; s=arc-20160816; b=qifzpjEGTjLpamSzwkNGC7JCKBHFJMRHcJvq1JA3VSvHI5jYKxPyk0VyTiHrJYBxVI L8yTUwQ8N7+573Z3qEhliLv7lJW/NDioLPtbm2wF0WbdQzifhAOJO0hWROzAMSYG0NmR d047bNiFoYvw7t9yiUriIIkbjcNpz6KkR3NnTV4RxShu9L5/2IkgV6c8OlD2VcIOVfcz k90f+glTUg4/FuBdRbyFWQuh+TNtkc+4NMQEhmd1jjD9omXxbS2GcTWDIvh5oiwl1ySs N4x6qtcSzNG2mV5nio5KywOMYfOcNVs9ruVEiE3HWoyKn0gI4tKdzYM4Zv6c6003LO9W mS8g== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=errors-to:sender:content-transfer-encoding:mime-version :list-subscribe:list-help:list-post:list-archive:list-unsubscribe :list-id:precedence:subject:references:in-reply-to:message-id:date :to:from:dkim-signature:delivered-to; bh=Fql+R/MOImCcJSoUehIbOnc91L8zvm1rLLZZFxkhiCA=; b=pJKlmE7Q5JUN7Jnzv7cUg/+jucckxSXtOo5VRUevlsgf80N0yHqvb8OoMxzWJjvIxo ydgKa/IQIbe/21NN6sScn61yEsW9c1fnD+xLn2TeonPicaRzeVx6XOWUJc2/1kgStrj9 dBzhFoQHs0nZmNs7D6+v9f4KGY2Ompt5stkSj8itfAaLoh3BWg/yZXQElgXgYnWubO4w gUZCAsG7XGnD593XCEJ4hUujKtu9MJDp0BVXVoFxUtEMbgPb3dlg1FIlqRjEQqnqwEkK SrNXO9DQGdD2hP9tat+U2oAwAmsLy4jIoIlxneIA9NXodUyu422ylcWB8Ff6b5f8ATYd 2fMg== ARC-Authentication-Results: i=1; mx.google.com; dkim=neutral (body hash did not verify) header.i=@gmail.com header.s=20161025 header.b=dnTZZj1E; 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 t67-v6si16005741pfd.364.2018.09.09.22.07.42; Sun, 09 Sep 2018 22:07:42 -0700 (PDT) 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=dnTZZj1E; 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 layers.openembedded.org (localhost [127.0.0.1]) by mail.openembedded.org (Postfix) with ESMTP id B2B2E79705; Mon, 10 Sep 2018 05:07:40 +0000 (UTC) X-Original-To: openembedded-devel@lists.openembedded.org Delivered-To: openembedded-devel@lists.openembedded.org Received: from mail-pg1-f196.google.com (mail-pg1-f196.google.com [209.85.215.196]) by mail.openembedded.org (Postfix) with ESMTP id D041874621 for ; Mon, 10 Sep 2018 05:06:39 +0000 (UTC) Received: by mail-pg1-f196.google.com with SMTP id v66-v6so9800575pgb.10 for ; Sun, 09 Sep 2018 22:06:41 -0700 (PDT) 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; bh=Zt2g/PFZptwtqB17r9h7IfUQMLxNHITp7mSkAqlxzo0=; b=dnTZZj1Ek0N6mgIVnFCFObVnvBGXX5QzuUfU6RVr/qrvoiUo9A0M8pThSox5tAAIER cO32LllLT/GAZ50X5ZUWXdDKCqvU90sqVkjzSoCm6dnq2Pns9chm5f5IFUHtKvTIdN7G Yh5c2C5NeqD8j5k3PHcFInYaGEFKIRzurXFMDB30AFDN7/HGcDB56KJrfYSEp+M2DNQz 0OowlbN/xPij1YEezVVMmczqBTe3rRhy97k5IlLPEPU++OKTvK+4Q79w5bYL2TzX5rCw mOtQIzoVVOHJBi3i+zpmBqzzf2n5IbbB2yf8MndhhGhsBTWP4zCQvOXMjq+TGGA/i37+ QYEg== 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=Zt2g/PFZptwtqB17r9h7IfUQMLxNHITp7mSkAqlxzo0=; b=knp05CSg4MC1m3iwAavz6RpObF9FVeoXVDjrV/e8q6yQO4+svUAHMhtnODK2Klicok fQ8bZ2wTeFjSRi0nh6jm0MWTVOgvvvEqoyD4ABFw+r84bR4/a4lzzoeBz2kxlGjcWaip vM96qp/V5Y2wC/uh6rfcWHCsCcLPOucbqSMbZul0OYT9qIve4beEic7mKL/222sJgbQO QyWyAyE0hZshexejOcBvVVba3BN0u4H9Vehfm6AgdQD0VkUVZMLXbUAjZyotZTmpoxK1 9M0o9Ohjslgm9igfoC2PBAb8ULYRtD13C9m4bDiUdL+eU3XBren7HxggqH5EjtT3bz/j GyEw== X-Gm-Message-State: APzg51CcIJvj9fMH3r4c7Kcy2/kM07gX+vZwupIpB1J4nyvYDUuo0Iii t/LUcXit539V5A5YXlk1ZGMo7HjA X-Received: by 2002:a62:5a01:: with SMTP id o1-v6mr21925126pfb.0.1536556000611; Sun, 09 Sep 2018 22:06:40 -0700 (PDT) Received: from localhost.localdomain ([2601:646:877f:9499::2887]) by smtp.gmail.com with ESMTPSA id x24-v6sm18819188pfh.67.2018.09.09.22.06.39 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Sun, 09 Sep 2018 22:06:40 -0700 (PDT) From: Khem Raj To: openembedded-devel@lists.openembedded.org Date: Sun, 9 Sep 2018 22:06:22 -0700 Message-Id: <20180910050629.16170-3-raj.khem@gmail.com> X-Mailer: git-send-email 2.18.0 In-Reply-To: <20180910050629.16170-1-raj.khem@gmail.com> References: <20180910050629.16170-1-raj.khem@gmail.com> Subject: [oe] [meta-oe][PATCH 03/10] libqmi: Upgrade to 1.20.2 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: , MIME-Version: 1.0 Sender: openembedded-devel-bounces@lists.openembedded.org Errors-To: openembedded-devel-bounces@lists.openembedded.org Signed-off-by: Khem Raj --- .../libqmi/{libqmi_1.20.0.bb => libqmi_1.20.2.bb} | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) rename meta-oe/recipes-connectivity/libqmi/{libqmi_1.20.0.bb => libqmi_1.20.2.bb} (82%) -- 2.18.0 -- _______________________________________________ Openembedded-devel mailing list Openembedded-devel@lists.openembedded.org http://lists.openembedded.org/mailman/listinfo/openembedded-devel diff --git a/meta-oe/recipes-connectivity/libqmi/libqmi_1.20.0.bb b/meta-oe/recipes-connectivity/libqmi/libqmi_1.20.2.bb similarity index 82% rename from meta-oe/recipes-connectivity/libqmi/libqmi_1.20.0.bb rename to meta-oe/recipes-connectivity/libqmi/libqmi_1.20.2.bb index 9301cbd5ee..3e08c4f9e6 100644 --- a/meta-oe/recipes-connectivity/libqmi/libqmi_1.20.0.bb +++ b/meta-oe/recipes-connectivity/libqmi/libqmi_1.20.2.bb @@ -14,5 +14,5 @@ inherit autotools pkgconfig bash-completion SRC_URI = "http://www.freedesktop.org/software/${BPN}/${BPN}-${PV}.tar.xz \ file://0001-Detect-clang.patch \ " -SRC_URI[md5sum] = "797e365521df76b77b067e6317618b41" -SRC_URI[sha256sum] = "21428cd3749c56246565123f707fee51238651a22c60bdc85ebce97388626eb4" +SRC_URI[md5sum] = "584214476ab75c394160cb85fbccaa1d" +SRC_URI[sha256sum] = "c73459ca8bfe1213f8047858d4946fc1f58e164d4f488a7a6904edee25e2ca44" From patchwork Mon Sep 10 05:06:23 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Khem Raj X-Patchwork-Id: 146272 Delivered-To: patch@linaro.org Received: by 2002:a2e:1648:0:0:0:0:0 with SMTP id 8-v6csp2078500ljw; Sun, 9 Sep 2018 22:07:49 -0700 (PDT) X-Google-Smtp-Source: ANB0VdYtt/+Og7SbOd+wjg70+hEbv/6WtjFbKzA14OYaryf50Z57iXfXt1J6WwlyTYf3GDFbibi+ X-Received: by 2002:a63:f902:: with SMTP id h2-v6mr20731653pgi.154.1536556069530; Sun, 09 Sep 2018 22:07:49 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1536556069; cv=none; d=google.com; s=arc-20160816; b=mKB9J6A17pzZU5c7if5bndHC99poMbGYxRSDocp9UNNGZ81QRMLTQcmhZ5wlojlNql jnrWVgu1FCBaDYAS/gT1mNBsIgzNvMLA9RohhSbpDBMKnAmp6W7LonnxsRyaK+E3zfvH Jik84Edz27oqjc1UeUa/C8QjImZbnERN9Ed1SnTfAkqPA26LoWNurmwunkLequNqWjrb 9ckdzKslk2EcxVfjgLgXTgJ4L17YAhR8XCxQMJr8AoYkFl1ysPihBj3cToStP7gtkhZX D9wJFb4QkdoZ9VEMbB+uCwAd3RXVe65I3e+XHcVleX61OWoLFZF+qD8XyaaeeTMZ8oHI MSuw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=errors-to:sender:content-transfer-encoding:mime-version :list-subscribe:list-help:list-post:list-archive:list-unsubscribe :list-id:precedence:subject:references:in-reply-to:message-id:date :to:from:dkim-signature:delivered-to; bh=b5pwEXNHs3wSQ7bZzXpBiTRCS0rV9bPhA6wlxxexXew=; b=QcOwfSXYlbwSZNQSEOZvk95L6TgdnrcrVrRsyK/Q+0pT6DmnlURD+yQEwfDSv9dTR/ utkSVgsdg33oo+aPHLkmsP7NphKFo7JSEMiaR8CIeUftN83z0u54FspKqHvEffL7tuOd Mbep3guZPyV5+d+Y+PrDe+gZ0+5E/pKKIGOBvlMDrtlhX2Bkp6hrEQLwCVL9qnN3m64f Z5uYDi9nMvSafNhY9S5ywx7nsoq4OzMvUka4G0o3j+rf8JDhtGLkT2/9VEPGFmnzgrE9 Qc0ot4gBeZIfePAhJyV/p7oSuDLRWtXq0bQ2VMg+QEm/k5oMqdCMEmzBiPmZ55X+yeOq q4iA== ARC-Authentication-Results: i=1; mx.google.com; dkim=neutral (body hash did not verify) header.i=@gmail.com header.s=20161025 header.b=TER2WNcY; 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 o16-v6si14604666pgv.402.2018.09.09.22.07.49; Sun, 09 Sep 2018 22:07:49 -0700 (PDT) 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=TER2WNcY; 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 layers.openembedded.org (localhost [127.0.0.1]) by mail.openembedded.org (Postfix) with ESMTP id D1AC079722; Mon, 10 Sep 2018 05:07:41 +0000 (UTC) X-Original-To: openembedded-devel@lists.openembedded.org Delivered-To: openembedded-devel@lists.openembedded.org Received: from mail-pl1-f196.google.com (mail-pl1-f196.google.com [209.85.214.196]) by mail.openembedded.org (Postfix) with ESMTP id 0CD5C796BE for ; Mon, 10 Sep 2018 05:06:40 +0000 (UTC) Received: by mail-pl1-f196.google.com with SMTP id s17-v6so9145394plp.7 for ; Sun, 09 Sep 2018 22:06:42 -0700 (PDT) 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; bh=nbysY9w8qk3Aa7CcCJQe7owpmdAnzeOtWaGRB6eTLko=; b=TER2WNcYmxarHpt62LPhoV1ZqMVTcXeQEgY04UgRsznwfURAkTDcuCVnP1wFZZI6HV 0113Qaqousvapy1/2EPgvGa/L23hAImJqp/KKL8ujLmBbdNuLMMdprIc81zdJdNyEzpS cWBcE5QJ0Or/tHFlyPtOKDFh8E8g5kzDopP2xLtVUMkj86eY7+GJQ7mQXurzvNvoTTbW REihd6xVZkp0cddnzs+2HohExc03mU1//yLvwhemupObe4mHrSD4ybncnRcHHf2TGGcu HUf+HrqJbRYs3sd55TDTZ+avU9sSqkRUDAWnGSdyHpihOkyB/otn6DDhsZJlyWmKCSYR ZxEw== 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=nbysY9w8qk3Aa7CcCJQe7owpmdAnzeOtWaGRB6eTLko=; b=t7kO9apcxI/poFnlQh3kjrOodBxmVELzQBAsjXGk/+7h8D03ampyDXF/+ZnB/Wd35n r8TkWAJg9MtwYoMCpXiYsv+HDo4Y6yFV7952h/h10i4EARCFDRziZopCs2/vKBdyUgc3 QoECEDkOeOQgnM2P7dvHjzeRnybqV/rqyMmexja373Bah9wqoW4iAv7p1NlaoA8ogBqd 6PZIQfNJAq79glo+fktIUoAwDuWt0GxYpLQtQ8LNqOjvrfsCiGIZiIW1v/ndjtHlzFJu iLbEKypKRHpNzjDlXVKYSRb2f2pcjqy1yXHlDTfAEUtBOGmZ0mwsfVWE10Llzl0XC3mX D5Eg== X-Gm-Message-State: APzg51CWC02GM6IrjeOY8WOGvcchkoN59OrhST8DSwDBMMEG1qK1S6WB qf02x4A7G65J7E5rkoYWAEFl6AOY X-Received: by 2002:a17:902:9a48:: with SMTP id x8-v6mr19869023plv.72.1536556001560; Sun, 09 Sep 2018 22:06:41 -0700 (PDT) Received: from localhost.localdomain ([2601:646:877f:9499::2887]) by smtp.gmail.com with ESMTPSA id x24-v6sm18819188pfh.67.2018.09.09.22.06.40 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Sun, 09 Sep 2018 22:06:40 -0700 (PDT) From: Khem Raj To: openembedded-devel@lists.openembedded.org Date: Sun, 9 Sep 2018 22:06:23 -0700 Message-Id: <20180910050629.16170-4-raj.khem@gmail.com> X-Mailer: git-send-email 2.18.0 In-Reply-To: <20180910050629.16170-1-raj.khem@gmail.com> References: <20180910050629.16170-1-raj.khem@gmail.com> Subject: [oe] [meta-networking][PATCH V2 04/10] openhpi: Upgrade to 3.8.0 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: , MIME-Version: 1.0 Sender: openembedded-devel-bounces@lists.openembedded.org Errors-To: openembedded-devel-bounces@lists.openembedded.org * Add patches to fix build with OpenSSL 1.1.x * Forward patches and drop ones not needed anymore * openhpi: Fix build with musl Signed-off-by: Khem Raj --- V2: Fix build with musl ...-poke-at-build-host-s-etc-os-release.patch | 27 +++++ .../0001-Fix-build-failures-with-gcc7.patch | 49 ---------- .../0001-include-iostream-for-cout.patch | 41 ++++++++ .../0001-ipmidirect-Replace-__STRING.patch | 31 ------ ...r-PTHREAD_RECURSIVE_MUTEX_INITIALIZE.patch | 47 --------- .../recipes-daemons/openhpi/files/c++11.patch | 24 +++-- .../openhpi/files/clang-c++11.patch | 17 +--- .../openhpi/files/cross_899198.patch | 98 +++++++++++++++++++ .../openhpi/files/no-md2.patch | 37 +++++++ .../openhpi/files/openhpi-3.6.1-ssl.patch | 20 ++++ .../files/openhpi-hpi-shell-thread-fix.patch | 29 ------ .../files/openhpi-libxml2-cross-compile.patch | 23 +++-- .../files/openhpi-netsnmp-cross-compile.patch | 25 +++-- ...-serial-tests-config-needed-by-ptest.patch | 19 ++-- .../{openhpi_3.6.1.bb => openhpi_3.8.0.bb} | 19 ++-- 15 files changed, 291 insertions(+), 215 deletions(-) create mode 100644 meta-networking/recipes-daemons/openhpi/files/0001-Do-not-poke-at-build-host-s-etc-os-release.patch delete mode 100644 meta-networking/recipes-daemons/openhpi/files/0001-Fix-build-failures-with-gcc7.patch create mode 100644 meta-networking/recipes-daemons/openhpi/files/0001-include-iostream-for-cout.patch delete mode 100644 meta-networking/recipes-daemons/openhpi/files/0001-ipmidirect-Replace-__STRING.patch delete mode 100644 meta-networking/recipes-daemons/openhpi/files/0001-plugins-Check-for-PTHREAD_RECURSIVE_MUTEX_INITIALIZE.patch create mode 100644 meta-networking/recipes-daemons/openhpi/files/cross_899198.patch create mode 100644 meta-networking/recipes-daemons/openhpi/files/no-md2.patch create mode 100644 meta-networking/recipes-daemons/openhpi/files/openhpi-3.6.1-ssl.patch delete mode 100644 meta-networking/recipes-daemons/openhpi/files/openhpi-hpi-shell-thread-fix.patch rename meta-networking/recipes-daemons/openhpi/{openhpi_3.6.1.bb => openhpi_3.8.0.bb} (90%) -- 2.18.0 -- _______________________________________________ Openembedded-devel mailing list Openembedded-devel@lists.openembedded.org http://lists.openembedded.org/mailman/listinfo/openembedded-devel diff --git a/meta-networking/recipes-daemons/openhpi/files/0001-Do-not-poke-at-build-host-s-etc-os-release.patch b/meta-networking/recipes-daemons/openhpi/files/0001-Do-not-poke-at-build-host-s-etc-os-release.patch new file mode 100644 index 0000000000..ab9b25fed0 --- /dev/null +++ b/meta-networking/recipes-daemons/openhpi/files/0001-Do-not-poke-at-build-host-s-etc-os-release.patch @@ -0,0 +1,27 @@ +From 2bc5c6367a7f70ca5bff177ec95bcad3b1c2b66b Mon Sep 17 00:00:00 2001 +From: Khem Raj +Date: Thu, 6 Sep 2018 18:15:10 -0700 +Subject: [PATCH] Do not poke at build host's /etc/os-release + +During cross compile we are interested in target distro and not host +distro therefore do not check for it. + +Upstream-Status: Inappropriate [Cross compile specific] + +Signed-off-by: Khem Raj +--- + configure.ac | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +Index: openhpi-3.8.0/configure.ac +=================================================================== +--- openhpi-3.8.0.orig/configure.ac ++++ openhpi-3.8.0/configure.ac +@@ -194,7 +194,6 @@ AC_SUBST(JSON_C_LIB) + AC_SUBST(JSON_C_INCLUDE) + AC_CHECK_LIB([rabbitmq],[amqp_new_connection],[RABBITMQ_LIB=-lrabbitmq],[RABBITMQ_LIB=]) + AC_SUBST(RABBITMQ_LIB) +-AC_CHECK_FILE([/etc/os-release],[DISTRO=`grep "^ID=" /etc/os-release | awk -F"\"" '{ print $2 }'`]) + + AC_CHECK_HEADERS([amqp.h],[have_rabbitmq=yes],[have_rabbitmq=no]) + diff --git a/meta-networking/recipes-daemons/openhpi/files/0001-Fix-build-failures-with-gcc7.patch b/meta-networking/recipes-daemons/openhpi/files/0001-Fix-build-failures-with-gcc7.patch deleted file mode 100644 index 4f493f7b8f..0000000000 --- a/meta-networking/recipes-daemons/openhpi/files/0001-Fix-build-failures-with-gcc7.patch +++ /dev/null @@ -1,49 +0,0 @@ -From 398c6db66c643ed6133cc2b028ab1e27a17c5295 Mon Sep 17 00:00:00 2001 -From: Khem Raj -Date: Mon, 1 May 2017 19:10:09 +0000 -Subject: [PATCH] Fix build failures with gcc7 - -Signed-off-by: Khem Raj ---- - plugins/ipmidirect/ipmi_mc_vendor.cpp | 2 +- - plugins/ipmidirect/ipmi_resource.cpp | 4 ++-- - 2 files changed, 3 insertions(+), 3 deletions(-) - -diff --git a/plugins/ipmidirect/ipmi_mc_vendor.cpp b/plugins/ipmidirect/ipmi_mc_vendor.cpp -index 2c6c090..557771c 100644 ---- a/plugins/ipmidirect/ipmi_mc_vendor.cpp -+++ b/plugins/ipmidirect/ipmi_mc_vendor.cpp -@@ -322,7 +322,7 @@ cIpmiMcVendor::CreateResources( cIpmiDomain *domain, cIpmiMc *source_mc, cIpmiSd - if ( addr.m_channel != source_mc->GetChannel() ) - stdlog << "WARNING : SDR channel " << addr.m_channel << " NOT equal to MC channel " << source_mc->GetChannel() << "\n"; - -- if ( FindOrCreateResource( domain, source_mc, fru_id, sdr, sdrs ) == false ) { -+ if ( !FindOrCreateResource( domain, source_mc, fru_id, sdr, sdrs ) ) { - return false; - } - } -diff --git a/plugins/ipmidirect/ipmi_resource.cpp b/plugins/ipmidirect/ipmi_resource.cpp -index c438e74..2552673 100644 ---- a/plugins/ipmidirect/ipmi_resource.cpp -+++ b/plugins/ipmidirect/ipmi_resource.cpp -@@ -73,7 +73,7 @@ cIpmiResource::SendCommandReadLock( const cIpmiMsg &msg, cIpmiMsg &rsp, - - domain->ReadLock(); - -- if ( domain->VerifyResource( resource ) == false ) -+ if ( !domain->VerifyResource( resource ) ) - return SA_ERR_HPI_NOT_PRESENT; - - return rv; -@@ -91,7 +91,7 @@ cIpmiResource::SendCommandReadLock( cIpmiRdr *rdr, const cIpmiMsg &msg, cIpmiMsg - - domain->ReadLock(); - -- if ( domain->VerifyRdr( rdr ) == false ) -+ if ( !domain->VerifyRdr( rdr ) ) - return SA_ERR_HPI_NOT_PRESENT; - - return rv; --- -1.9.1 - diff --git a/meta-networking/recipes-daemons/openhpi/files/0001-include-iostream-for-cout.patch b/meta-networking/recipes-daemons/openhpi/files/0001-include-iostream-for-cout.patch new file mode 100644 index 0000000000..c78ec28de7 --- /dev/null +++ b/meta-networking/recipes-daemons/openhpi/files/0001-include-iostream-for-cout.patch @@ -0,0 +1,41 @@ +From 8f47adc3b9085d589e62cb5eb560dd23a703036a Mon Sep 17 00:00:00 2001 +From: Khem Raj +Date: Sat, 8 Sep 2018 12:47:49 -0700 +Subject: [PATCH] include iostream for cout + +End cout with endl + +Fixes +plugins/dynamic_simulator/thread.cpp:241:3: error: 'cout' was not declared in this scope + cout<<"PTHREAD_RECURSIVE_MUTEX_INITIALIZER_NP is Defined" + ^~~~ + +Upstream-Status: Pending + +Signed-off-by: Khem Raj +--- + plugins/dynamic_simulator/thread.cpp | 4 ++-- + 1 file changed, 2 insertions(+), 2 deletions(-) + +diff --git a/plugins/dynamic_simulator/thread.cpp b/plugins/dynamic_simulator/thread.cpp +index b971502..61eaf42 100644 +--- a/plugins/dynamic_simulator/thread.cpp ++++ b/plugins/dynamic_simulator/thread.cpp +@@ -26,7 +26,7 @@ + */ + + #include "thread.h" +-#include ++#include + #include + #include + +@@ -238,7 +238,7 @@ cThreadLock::cThreadLock() + pthread_mutexattr_settype( &attr, PTHREAD_MUTEX_RECURSIVE ); + pthread_mutex_init( &m_lock, &attr ); + pthread_mutexattr_destroy( &attr ); +- cout<<"PTHREAD_RECURSIVE_MUTEX_INITIALIZER_NP is Defined" ++ std::cout<<"PTHREAD_RECURSIVE_MUTEX_INITIALIZER_NP is Defined"< -Date: Thu, 14 Sep 2017 17:56:31 -0700 -Subject: [PATCH] ipmidirect: Replace __STRING - -__STRING is not universally available e.g. -musl does not define it - -Signed-off-by: Khem Raj ---- -Upstream-Status: Pending - - plugins/ipmidirect/t/test.h | 2 +- - 1 file changed, 1 insertion(+), 1 deletion(-) - -diff --git a/plugins/ipmidirect/t/test.h b/plugins/ipmidirect/t/test.h -index 8d71381..978d5ff 100644 ---- a/plugins/ipmidirect/t/test.h -+++ b/plugins/ipmidirect/t/test.h -@@ -22,7 +22,7 @@ TestFunction( const char *str, const char *file, int line, bool expr ) - } - - --#define Test(expr) TestFunction( __STRING(expr), __FILE__, __LINE__, expr ) -+#define Test(expr) TestFunction( #expr, __FILE__, __LINE__, expr ) - - - static int --- -2.14.1 - diff --git a/meta-networking/recipes-daemons/openhpi/files/0001-plugins-Check-for-PTHREAD_RECURSIVE_MUTEX_INITIALIZE.patch b/meta-networking/recipes-daemons/openhpi/files/0001-plugins-Check-for-PTHREAD_RECURSIVE_MUTEX_INITIALIZE.patch deleted file mode 100644 index 0f033ac855..0000000000 --- a/meta-networking/recipes-daemons/openhpi/files/0001-plugins-Check-for-PTHREAD_RECURSIVE_MUTEX_INITIALIZE.patch +++ /dev/null @@ -1,47 +0,0 @@ -From be665d9513cca7e8b64c79ae424cf44ac166b052 Mon Sep 17 00:00:00 2001 -From: Khem Raj -Date: Thu, 14 Sep 2017 17:07:58 -0700 -Subject: [PATCH] plugins: Check for PTHREAD_RECURSIVE_MUTEX_INITIALIZER_NP - before use - -musl does not define PTHREAD_RECURSIVE_MUTEX_INITIALIZER_NP -so we can not assume that all Linux systems support PTHREAD_RECURSIVE_MUTEX_INITIALIZER_NP -its a glibc specific define so check for it being defined before using it - -Signed-off-by: Khem Raj ---- -Upstream-Status: Pending - - plugins/dynamic_simulator/thread.cpp | 2 +- - plugins/ipmidirect/thread.cpp | 2 +- - 2 files changed, 2 insertions(+), 2 deletions(-) - -diff --git a/plugins/dynamic_simulator/thread.cpp b/plugins/dynamic_simulator/thread.cpp -index d663be0..9210fd7 100644 ---- a/plugins/dynamic_simulator/thread.cpp -+++ b/plugins/dynamic_simulator/thread.cpp -@@ -229,7 +229,7 @@ cThread::Exit( void *rv ) - /** - * Constructor - **/ --#if ( defined(__sun) && defined(__SVR4) ) || defined(__FreeBSD__) -+#ifndef PTHREAD_RECURSIVE_MUTEX_INITIALIZER_NP - cThreadLock::cThreadLock() - { - pthread_mutexattr_t attr; -diff --git a/plugins/ipmidirect/thread.cpp b/plugins/ipmidirect/thread.cpp -index 5c52557..48e83fa 100644 ---- a/plugins/ipmidirect/thread.cpp -+++ b/plugins/ipmidirect/thread.cpp -@@ -167,7 +167,7 @@ cThread::Exit( void *rv ) - // cThreadLock - ////////////////////////////////////////////////// - --#if ( defined(__sun) && defined(__SVR4) ) || defined(__FreeBSD__) -+#ifndef PTHREAD_RECURSIVE_MUTEX_INITIALIZER_NP - cThreadLock::cThreadLock() - { - pthread_mutexattr_t attr; --- -2.14.1 - diff --git a/meta-networking/recipes-daemons/openhpi/files/c++11.patch b/meta-networking/recipes-daemons/openhpi/files/c++11.patch index 0549d59777..5eff86b4d5 100644 --- a/meta-networking/recipes-daemons/openhpi/files/c++11.patch +++ b/meta-networking/recipes-daemons/openhpi/files/c++11.patch @@ -1,11 +1,21 @@ -Index: openhpi-3.6.1/configure.ac -=================================================================== ---- openhpi-3.6.1.orig/configure.ac -+++ openhpi-3.6.1/configure.ac -@@ -44,6 +44,7 @@ AC_PROG_CPP - AC_PROG_INSTALL - AC_PROG_LN_S +From ed51168dfd6844deeaebf7d5f6c65898aafb6299 Mon Sep 17 00:00:00 2001 +From: Khem Raj +Date: Sun, 27 Aug 2017 12:12:04 -0700 + +Upstream-Status: Pending +Signed-off-by: Khem Raj +--- + configure.ac | 1 + + 1 file changed, 1 insertion(+) + +diff --git a/configure.ac b/configure.ac +index c29a31f..f7fe0f7 100644 +--- a/configure.ac ++++ b/configure.ac +@@ -46,6 +46,7 @@ AC_PROG_LN_S AC_PROG_MAKE_SET + AC_PROG_AWK + AC_PROG_GREP +AX_CXX_COMPILE_STDCXX_11([noext],[mandatory]) enabled_non32bit="no" diff --git a/meta-networking/recipes-daemons/openhpi/files/clang-c++11.patch b/meta-networking/recipes-daemons/openhpi/files/clang-c++11.patch index 9b35a0cced..7958a07c67 100644 --- a/meta-networking/recipes-daemons/openhpi/files/clang-c++11.patch +++ b/meta-networking/recipes-daemons/openhpi/files/clang-c++11.patch @@ -1,3 +1,7 @@ +Support build with Clang + +Upstream-Status: Pending +Signed-off-by: Khem Raj Index: openhpi-3.6.1/plugins/dynamic_simulator/new_sim.cpp =================================================================== --- openhpi-3.6.1.orig/plugins/dynamic_simulator/new_sim.cpp @@ -1273,16 +1277,3 @@ Index: openhpi-3.6.1/plugins/ipmidirect/ipmi.cpp static SaErrorT IpmiResetWatchdog(void *hnd, -Index: openhpi-3.6.1/plugins/ipmidirect/ipmi_auth.h -=================================================================== ---- openhpi-3.6.1.orig/plugins/ipmidirect/ipmi_auth.h -+++ openhpi-3.6.1/plugins/ipmidirect/ipmi_auth.h -@@ -32,7 +32,7 @@ class cIpmiAuthSg - { - public: - void *data; /* NULL to terminate. */ -- int len; -+ unsigned int len; - }; - - diff --git a/meta-networking/recipes-daemons/openhpi/files/cross_899198.patch b/meta-networking/recipes-daemons/openhpi/files/cross_899198.patch new file mode 100644 index 0000000000..3161140df9 --- /dev/null +++ b/meta-networking/recipes-daemons/openhpi/files/cross_899198.patch @@ -0,0 +1,98 @@ +From: Helmut Grohne +Subject: fix cross compilation + +The OH_SET_SIZES macro relies on the usual autoconf sizeof cache variables +during cross compilation, but it never ensure that they are initialized. + +pkg-config must be called with $ac_tool_prefix and PKG_PROG_PKG_CONFIG takes +care of that. Setting PKG_CONFIG_PATH breaks the pkg-config-cross-wrapper. +Don't do that. + +Upstream-Status: Pending +Signed-off-by: Khem Raj + +Index: openhpi-3.8.0/acinclude.m4 +=================================================================== +--- openhpi-3.8.0.orig/acinclude.m4 ++++ openhpi-3.8.0/acinclude.m4 +@@ -22,30 +22,39 @@ AC_DEFUN([OH_SET_SIZES], + + if test "x$cross_compiling" != "xno"; then + if test "x$OH_SIZEOF_UCHAR" = x; then ++ AC_CHECK_SIZEOF([unsigned char]) + OH_SIZEOF_UCHAR=$ac_cv_sizeof_uchar + fi + if test "x$OH_SIZEOF_USHORT" = x; then ++ AC_CHECK_SIZEOF([unsigned short]) + OH_SIZEOF_USHORT=$ac_cv_sizeof_ushort + fi + if test "x$OH_SIZEOF_UINT" = x; then ++ AC_CHECK_SIZEOF([unsigned int]) + OH_SIZEOF_UINT=$ac_cv_sizeof_uint + fi + if test "x$OH_SIZEOF_CHAR" = x; then ++ AC_CHECK_SIZEOF([char]) + OH_SIZEOF_CHAR=$ac_cv_sizeof_char + fi + if test "x$OH_SIZEOF_SHORT" = x; then ++ AC_CHECK_SIZEOF([short]) + OH_SIZEOF_SHORT=$ac_cv_sizeof_short + fi + if test "x$OH_SIZEOF_INT" = x; then ++ AC_CHECK_SIZEOF([int]) + OH_SIZEOF_INT=$ac_cv_sizeof_int + fi + if test "x$OH_SIZEOF_LLONG" = x; then ++ AC_CHECK_SIZEOF([long long]) + OH_SIZEOF_LLONG=$ac_cv_sizeof_longlong + fi + if test "x$OH_SIZEOF_FLOAT" = x; then ++ AC_CHECK_SIZEOF([float]) + OH_SIZEOF_FLOAT=$ac_cv_sizeof_float + fi + if test "x$OH_SIZEOF_DOUBLE" = x; then ++ AC_CHECK_SIZEOF([double]) + OH_SIZEOF_DOUBLE=$ac_cv_sizeof_double + fi + else +Index: openhpi-3.8.0/configure.ac +=================================================================== +--- openhpi-3.8.0.orig/configure.ac ++++ openhpi-3.8.0/configure.ac +@@ -87,9 +87,9 @@ have_rtas_lib=no + + dnl Check for GLIB + +-AC_CHECK_PROG([found_pkg_config],[pkg-config],[yes]) ++PKG_PROG_PKG_CONFIG + +-if test "x$found_pkg_config" != "xyes"; then ++if test "x$PKG_CONFIG" = "x"; then + OH_CHECK_FAIL(pkg-config,pkg-config) + fi + PKG_CFG_SETPATH +@@ -105,7 +105,7 @@ GLIB=glib-2.0 + GTHREAD=gthread-2.0 + GMODULE=gmodule-2.0 + +-if pkg-config --atleast-version $GLIB_REQUIRED_VERSION $GLIB; then ++if $PKG_CONFIG --atleast-version $GLIB_REQUIRED_VERSION $GLIB; then + : + else + AC_MSG_ERROR([ +@@ -268,12 +268,12 @@ dnl + dnl We really need to make ipmi enablement be contigent on OpenIPMI + dnl + +-if PKG_CONFIG_PATH=$PKG_CONFIG_PATH:/usr/local/lib/pkgconfig pkg-config --atleast-version 1.4.20 OpenIPMI; then ++if $PKG_CONFIG --atleast-version 1.4.20 OpenIPMI; then + have_openipmi=yes + AC_CHECK_LIB([OpenIPMI], [ipmi_smi_setup_con], [have_openipmi=yes]) +- OPENIPMI_CFLAGS=`PKG_CONFIG_PATH=$PKG_CONFIG_PATH:/usr/local/lib/pkgconfig pkg-config --cflags OpenIPMI` ++ OPENIPMI_CFLAGS=`$PKG_CONFIG --cflags OpenIPMI` + AC_SUBST(OPENIPMI_CFLAGS) +- OPENIPMI_LIBS=`PKG_CONFIG_PATH=$PKG_CONFIG_PATH:/usr/local/lib/pkgconfig pkg-config --libs OpenIPMI` ++ OPENIPMI_LIBS=`$PKG_CONFIG --libs OpenIPMI` + AC_SUBST(OPENIPMI_LIBS) + fi + diff --git a/meta-networking/recipes-daemons/openhpi/files/no-md2.patch b/meta-networking/recipes-daemons/openhpi/files/no-md2.patch new file mode 100644 index 0000000000..c4dd23e790 --- /dev/null +++ b/meta-networking/recipes-daemons/openhpi/files/no-md2.patch @@ -0,0 +1,37 @@ +Description: Fix FTBFS with OpenSSL 1.1 by honouring OPENSSL_NO_MD2 +Author: Adrian Bunk +Bug-Debian: https://bugs.debian.org/859543 + +Upstream-Status: Pending +Signed-off-by: Khem Raj + +Index: openhpi-3.8.0/plugins/ipmidirect/ipmi_auth.cpp +=================================================================== +--- openhpi-3.8.0.orig/plugins/ipmidirect/ipmi_auth.cpp ++++ openhpi-3.8.0/plugins/ipmidirect/ipmi_auth.cpp +@@ -21,6 +21,7 @@ + #include "ipmi_auth.h" + #include + #include ++#include + + + cIpmiAuth * +@@ -32,7 +33,7 @@ IpmiAuthFactory( tIpmiAuthType type ) + return new cIpmiAuthNone; + + case eIpmiAuthTypeMd2: +-#ifdef HAVE_OPENSSL_MD2_H ++#if defined(HAVE_OPENSSL_MD2_H) && !defined(OPENSSL_NO_MD2) + return new cIpmiAuthMd2; + #else + break; +@@ -78,7 +79,7 @@ cIpmiAuthNone::Check( cIpmiAuthSg /*d*/[ + } + + +-#ifdef HAVE_OPENSSL_MD2_H ++#if defined(HAVE_OPENSSL_MD2_H) && !defined(OPENSSL_NO_MD2) + #include + + diff --git a/meta-networking/recipes-daemons/openhpi/files/openhpi-3.6.1-ssl.patch b/meta-networking/recipes-daemons/openhpi/files/openhpi-3.6.1-ssl.patch new file mode 100644 index 0000000000..ca522bcc67 --- /dev/null +++ b/meta-networking/recipes-daemons/openhpi/files/openhpi-3.6.1-ssl.patch @@ -0,0 +1,20 @@ +Link with libssl + +fixed build with openssl-1.1.x + +Taken from Fedora +https://src.fedoraproject.org/rpms/openhpi/c/be77f5484b0206f8946a85b29424ea10bf863063 + +Signed-off-by: Khem Raj +Upstream-Status: Unknown + +diff -up openhpi-3.6.1/ssl/Makefile.am.than openhpi-3.6.1/ssl/Makefile.am +--- openhpi-3.6.1/ssl/Makefile.am.than 2017-02-21 12:21:12.114814698 -0500 ++++ openhpi-3.6.1/ssl/Makefile.am 2017-02-21 12:22:44.576454262 -0500 +@@ -19,5 +19,5 @@ lib_LTLIBRARIES = libopenhpi_ssl.la + libopenhpi_ssl_la_SOURCES = oh_ssl.c oh_ssl.h + + libopenhpi_ssl_la_LDFLAGS = -version-info @HPI_LIB_VERSION@ +-libopenhpi_ssl_la_LIBADD = @CRYPTO_LIB@ ++libopenhpi_ssl_la_LIBADD = -lssl @CRYPTO_LIB@ + diff --git a/meta-networking/recipes-daemons/openhpi/files/openhpi-hpi-shell-thread-fix.patch b/meta-networking/recipes-daemons/openhpi/files/openhpi-hpi-shell-thread-fix.patch deleted file mode 100644 index cc21ff8c79..0000000000 --- a/meta-networking/recipes-daemons/openhpi/files/openhpi-hpi-shell-thread-fix.patch +++ /dev/null @@ -1,29 +0,0 @@ -commit e9f9a73c9dba8dd59f3d6c3acd9988ec8361d55a -Author: Aws Ismail -Date: Mon Dec 17 16:23:45 2012 -0500 - - Correct dangling g_thread_exit in session.c - - hpi_shell's session.c has its progress_bar - thread created using pthread_create but - exited using g_thread_exit. Use pthread_exit - instead to avoid unpredictable GLIB thread - errors. - - Upstream-Status: Pending - - Signed-off-by: Aws Ismail - -Index: openhpi-3.6.1/hpi_shell/session.c -=================================================================== ---- openhpi-3.6.1.orig/hpi_shell/session.c -+++ openhpi-3.6.1/hpi_shell/session.c -@@ -73,7 +73,7 @@ static void* progress_bar(void *unused) - if (i < (PROGRESS_BUF_SIZE - mes_len - 1)) i++; - t++; - }; -- g_thread_exit(0); -+ pthread_exit(0); - return (void *)1; - } - diff --git a/meta-networking/recipes-daemons/openhpi/files/openhpi-libxml2-cross-compile.patch b/meta-networking/recipes-daemons/openhpi/files/openhpi-libxml2-cross-compile.patch index c848b35027..160eeede69 100644 --- a/meta-networking/recipes-daemons/openhpi/files/openhpi-libxml2-cross-compile.patch +++ b/meta-networking/recipes-daemons/openhpi/files/openhpi-libxml2-cross-compile.patch @@ -1,4 +1,7 @@ -Fix libxml2 for cross-compiling +From afe545e77f9d841b7777d859e7e8108492fece96 Mon Sep 17 00:00:00 2001 +From: Jackie Huang +Date: Wed, 26 Apr 2017 16:22:00 +0800 +Subject: [PATCH] Fix libxml2 for cross-compiling Use proper XML2_INCLUDE path when cross-compiling @@ -6,16 +9,20 @@ Upstream-Status: Pending Signed-of-by: Aws Ismail -Index: openhpi-3.6.1/configure.ac -=================================================================== ---- openhpi-3.6.1.orig/configure.ac -+++ openhpi-3.6.1/configure.ac -@@ -177,7 +177,7 @@ AC_CHECK_HEADERS([openssl/md2.h openssl/ +--- + configure.ac | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/configure.ac b/configure.ac +index 6242cbf..4fb6b69 100644 +--- a/configure.ac ++++ b/configure.ac +@@ -179,7 +179,7 @@ AC_CHECK_HEADERS([openssl/md2.h openssl/md5.h openssl/bio.h openssl/ssl.h openss dnl xml is used for XML-based communication in ilo2_ribcl and oa_soap AC_CHECK_LIB([xml2],[xmlParseMemory],[XML2_LIB=-lxml2],[XML2_LIB=]) --AC_CHECK_HEADERS([libxml2/libxml/xmlexports.h],[XML2_INCLUDE="-I/usr/include/libxml2"],[XML2_INCLUDE]) -+AC_CHECK_HEADERS([libxml2/libxml/xmlexports.h],[XML2_INCLUDE="$XML2_INCLUDE"],[XML2_INCLUDE]) +-AC_CHECK_HEADERS([libxml2/libxml/xmlexports.h],[XML2_INCLUDE="-I/usr/include/libxml2"],[XML2_INCLUDE=]) ++AC_CHECK_HEADERS([libxml2/libxml/xmlexports.h],[XML2_INCLUDE="$XML2_INCLUDE"],[XML2_INCLUDE=]) AC_SUBST(XML2_LIB) AC_SUBST(XML2_INCLUDE) diff --git a/meta-networking/recipes-daemons/openhpi/files/openhpi-netsnmp-cross-compile.patch b/meta-networking/recipes-daemons/openhpi/files/openhpi-netsnmp-cross-compile.patch index 95b0abc913..293c8d91f5 100644 --- a/meta-networking/recipes-daemons/openhpi/files/openhpi-netsnmp-cross-compile.patch +++ b/meta-networking/recipes-daemons/openhpi/files/openhpi-netsnmp-cross-compile.patch @@ -13,36 +13,33 @@ Signed-off-by: Wenzong Fan configure | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) -diff --git a/acinclude.m4 b/acinclude.m4 -index 82c33f6..727e461 100644 ---- a/acinclude.m4 -+++ b/acinclude.m4 +Index: openhpi-3.8.0/acinclude.m4 +=================================================================== +--- openhpi-3.8.0.orig/acinclude.m4 ++++ openhpi-3.8.0/acinclude.m4 @@ -160,8 +160,8 @@ AC_DEFUN([OH_CHECK_NETSNMP], ], [ have_netsnmp=yes -- SNMPFLAGS=`${net_snmp_config:-net-snmp-config} --cflags | perl -p -e 's/-O\S*//g'` +- SNMPFLAGS=`${net_snmp_config:-net-snmp-config} --cflags | perl -p -e 's/ -O\S*//g'` - SNMPLIBS=`${net_snmp_config:-net-snmp-config} --libs` + SNMPFLAGS="" + SNMPLIBS="" AC_MSG_RESULT(yes) ], [AC_MSG_RESULT(no. No SNMP based plugins can be built!)]) -diff --git a/configure b/configure -index 00067bc..36b913c 100755 ---- a/configure -+++ b/configure -@@ -15949,8 +15949,8 @@ _ACEOF +Index: openhpi-3.8.0/configure +=================================================================== +--- openhpi-3.8.0.orig/configure ++++ openhpi-3.8.0/configure +@@ -16062,8 +16062,8 @@ _ACEOF if ac_fn_c_try_link "$LINENO"; then : have_netsnmp=yes -- SNMPFLAGS=`${net_snmp_config:-net-snmp-config} --cflags | perl -p -e 's/-O\S*//g'` +- SNMPFLAGS=`${net_snmp_config:-net-snmp-config} --cflags | perl -p -e 's/ -O\S*//g'` - SNMPLIBS=`${net_snmp_config:-net-snmp-config} --libs` + SNMPFLAGS="" + SNMPLIBS="" { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 $as_echo "yes" >&6; } --- -1.9.1 - diff --git a/meta-networking/recipes-daemons/openhpi/files/openhpi-use-serial-tests-config-needed-by-ptest.patch b/meta-networking/recipes-daemons/openhpi/files/openhpi-use-serial-tests-config-needed-by-ptest.patch index 3e09180d4d..472318b808 100644 --- a/meta-networking/recipes-daemons/openhpi/files/openhpi-use-serial-tests-config-needed-by-ptest.patch +++ b/meta-networking/recipes-daemons/openhpi/files/openhpi-use-serial-tests-config-needed-by-ptest.patch @@ -1,4 +1,4 @@ -From 36fbaa27e7299f63c1324b0ad22b970e9365d6a7 Mon Sep 17 00:00:00 2001 +From 5e0ae172586f5aeb270a8f9b012dd3e36536a2a9 Mon Sep 17 00:00:00 2001 From: Jackie Huang Date: Wed, 24 Dec 2014 10:54:59 +0800 Subject: [PATCH] openhpi: use serial-tests config needed by ptest @@ -9,17 +9,18 @@ serial-tests is required to generate those targets. Upstream-Status: Inappropriate [default automake behavior incompatible with ptest] Signed-off-by: Jackie Huang + --- - configure.ac | 2 +- - 1 files changed, 1 insertions(+), 1 deletions(-) + configure.ac | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) -Index: openhpi-3.6.1/configure.ac -=================================================================== ---- openhpi-3.6.1.orig/configure.ac -+++ openhpi-3.6.1/configure.ac -@@ -7,7 +7,7 @@ dnl various hacks by Sean Dague 4/23/03 AC_PREREQ(2.57) - AC_INIT(openhpi, 3.6.1) + AC_INIT(openhpi, 3.8.0) AC_CONFIG_SRCDIR(openhpi.spec.in) -AM_INIT_AUTOMAKE([1.8]) +AM_INIT_AUTOMAKE([1.8 serial-tests]) diff --git a/meta-networking/recipes-daemons/openhpi/openhpi_3.6.1.bb b/meta-networking/recipes-daemons/openhpi/openhpi_3.8.0.bb similarity index 90% rename from meta-networking/recipes-daemons/openhpi/openhpi_3.6.1.bb rename to meta-networking/recipes-daemons/openhpi/openhpi_3.8.0.bb index 596578e118..c4b3309f7c 100644 --- a/meta-networking/recipes-daemons/openhpi/openhpi_3.6.1.bb +++ b/meta-networking/recipes-daemons/openhpi/openhpi_3.8.0.bb @@ -20,7 +20,8 @@ SECTION = "net" LICENSE = "BSD" LIC_FILES_CHKSUM = "file://COPYING;md5=e3c772a32386888ccb5ae1c0ba95f1a4" -DEPENDS = "net-snmp libxml2 ncurses openssl glib-2.0 popt e2fsprogs autoconf-archive-native" +DEPENDS = "net-snmp libxml2 ncurses openssl glib-2.0 popt e2fsprogs \ + autoconf-archive-native os-release" SRC_URI = "${SOURCEFORGE_MIRROR}/${BPN}/${BP}.tar.gz \ file://openhpi.init \ @@ -32,23 +33,23 @@ SRC_URI = "${SOURCEFORGE_MIRROR}/${BPN}/${BP}.tar.gz \ file://openhpi-glib-cross-compile.patch \ file://openhpi-linkfix.patch \ file://openhpi-fix-host-gcc.patch \ - file://openhpi-hpi-shell-thread-fix.patch \ file://openhpi-fix-testfail-errors.patch \ file://openhpi-add-libnetsnmp-when-link.patch \ file://openhpi-invalide-session.patch \ file://openhpi-use-serial-tests-config-needed-by-ptest.patch \ file://openhpi-fix-alignment-issue.patch \ - file://0001-Fix-build-failures-with-gcc7.patch \ file://c++11.patch \ file://clang-c++11.patch \ file://fix-narrowing-warning.patch \ - file://0001-plugins-Check-for-PTHREAD_RECURSIVE_MUTEX_INITIALIZE.patch \ - file://0001-ipmidirect-Replace-__STRING.patch \ file://0001-session-close-socket.patch \ + file://openhpi-3.6.1-ssl.patch \ + file://0001-Do-not-poke-at-build-host-s-etc-os-release.patch \ + file://cross_899198.patch \ + file://no-md2.patch \ + file://0001-include-iostream-for-cout.patch \ " - -SRC_URI[md5sum] = "4718b16e0f749b5ad214a9b04f45dd23" -SRC_URI[sha256sum] = "e0a810cb401c4bdcfc9551f2e6afd5a8ca4b411f5ee3bc60c19f82fd6e84a3dc" +SRC_URI[md5sum] = "fffda3deea8a0d3671a72eea9d13a4df" +SRC_URI[sha256sum] = "c94332a29160dd75cb799c027e614690c00263b0fabed87417707bec04c38723" inherit autotools pkgconfig ptest update-rc.d systemd @@ -64,6 +65,8 @@ PACKAGECONFIG[sysfs] = "--enable-sysfs,--disable-sysfs,sysfsutils," PACKAGECONFIG[libgcrypt] = "--enable-encryption,--disable-encryption,libgcrypt," PACKAGECONFIG[non32bit] = "--enable-non32bit-int,--disable-non32bit-int,," +export DISTRO + do_install_append () { install -m 0755 -d ${D}${sysconfdir}/${BPN} install -m 0755 ${S}/openhpiclient.conf.example ${D}${sysconfdir}/${BPN}/openhpiclient.conf From patchwork Mon Sep 10 05:06:24 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Khem Raj X-Patchwork-Id: 146273 Delivered-To: patch@linaro.org Received: by 2002:a2e:1648:0:0:0:0:0 with SMTP id 8-v6csp2078592ljw; Sun, 9 Sep 2018 22:07:58 -0700 (PDT) X-Google-Smtp-Source: ANB0VdZQMvYhZFtxnSFPwG1bFc8zwdBROdsvwl/YylXOHhzczjbgRINfi/H+8h1vBpqH/jibBnJZ X-Received: by 2002:a65:448a:: with SMTP id l10-v6mr20907185pgq.382.1536556078355; Sun, 09 Sep 2018 22:07:58 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1536556078; cv=none; d=google.com; s=arc-20160816; b=VtkAH3byFXlIRc31FXBquyz6dAkjfcw7qFKvZfT3tjVjuL/Jy1d2aaEuxhUb4QN04q /RKxl+sRK7rGU6h17qS2al4ZeEFiMW+KJXOPOen/wyLtnImx7NHQWFH19K1S69knUMOw Dh7FkWvghbtVo769ktqYEb/NQWjeOchthhGI51Fw8VA2JUuCiDJ45rdDtU/La0WSyNqj MVDLYC98YJQNUsh+kcAJOgetdkDFNYaiZUvbc/L46bLdTRAdP9nBdk5NIuZXrdUqL5hd BDQpc2J6vGHvUCCqpFSv91EAeZKUNuAq/c72ERcycJfD/3izmHF9xlmmUx4UZelf4eip 7x7g== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=errors-to:sender:content-transfer-encoding:mime-version :list-subscribe:list-help:list-post:list-archive:list-unsubscribe :list-id:precedence:subject:references:in-reply-to:message-id:date :to:from:dkim-signature:delivered-to; bh=oqWC5UTpMeQ8EMtDBk8XbbscEfDvmwPzsm7VMlHyrv4=; b=WsfJXpfHP+nciHDYXHyCgCLSLPt9rIbQ1OUhSRzSx/wOXJ8lQh9cPYl7Md5rveYFQE 7auR0yIVLOWRkoshHtXDzyrz0iFFpwWNkh7iIUGsurh9jL2hO+t5hAtBUbP6eokQXi8e Q+sRMTHaFhtQu1yUztUdg3GSZmph2p26pAqDyrwpDowPrxDQEszmdILf3Sp2g8n8r1Ug z0UBcqX6Yubg2UBaJo1AUNwOFXakQfs8+IJK4rgtCKOfZhdrhjhxcUMR6Ab0f76fvR+K Eg0064INkKHG26DOsWlhqgiWbhX8uUb5m716SKHvB6wr3/QkGpEuBSUqpES5u8QYLfom OzYw== ARC-Authentication-Results: i=1; mx.google.com; dkim=neutral (body hash did not verify) header.i=@gmail.com header.s=20161025 header.b=TmW39JSE; 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 s12-v6si17178769pgi.514.2018.09.09.22.07.58; Sun, 09 Sep 2018 22:07:58 -0700 (PDT) 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=TmW39JSE; 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 layers.openembedded.org (localhost [127.0.0.1]) by mail.openembedded.org (Postfix) with ESMTP id F1C6A79726; Mon, 10 Sep 2018 05:07:42 +0000 (UTC) X-Original-To: openembedded-devel@lists.openembedded.org Delivered-To: openembedded-devel@lists.openembedded.org Received: from mail-pg1-f169.google.com (mail-pg1-f169.google.com [209.85.215.169]) by mail.openembedded.org (Postfix) with ESMTP id A49AB65D00 for ; Mon, 10 Sep 2018 05:06:41 +0000 (UTC) Received: by mail-pg1-f169.google.com with SMTP id t84-v6so7974791pgb.5 for ; Sun, 09 Sep 2018 22:06:43 -0700 (PDT) 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; bh=4yT7tDqHVlENlk3my+LpXGHTJnBVc3smPsg9VCu3Upk=; b=TmW39JSEP1aG8vYHzslIlTm5njtCwS2iGcCzQnWfcxZJ19Vyi6RXCRsCKQFFwioV+K DezZy6o7igEORVGGeugEe5YT8K/57VZFRNl9bPKpKuXBxTLzQJqoQEIcmP79RZT5BbkA GcUsOONdYDS6JwA3Z2iKHVtssneZ/XpsWdc5YSxPeqOdTzbG45ygUcXf1nvOb1RglGM9 pndLkAAgCBVJfCoxCdVQK9o4kOMaedQPviugDDwWXA1/f72jo6wnVxiOzyo1QePFz+Ch AJt7Ig45uWoCm/Vh+LrLVHF/faNaQaJ+AMEaq6g+lPmNg0+xeaakybtmMa66xQyhylNO kbxg== 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=4yT7tDqHVlENlk3my+LpXGHTJnBVc3smPsg9VCu3Upk=; b=BNmuG8kctHvUQeKPk8q/TYqov7w14ytG1eH9owXPFb9jw6HwtBrnYuysz/pJCp4U2q VZH56Z8ZawqRrR09EV0juGleHEYMMzgnaSRfznKLA8+VphsRm/HhH9Xjn1D0+uOSjwVN cT/rjLCwtFPmqHsS+XzMx1wFMY2fqJ95eefuRIhVKejAf971YJNo9sEfx/CH78ktdPlu 3i1DD6aa3Usf5qcvPpj7Glo9lmv8gL1XHMaxvYUetzjlceiOP9iwiQuR9jDrucBB6akT CmIBB67M8uVPzsZvRhgPLF5TN6hF2dKRx9WxW6WtNqkMe9jIEFk3ELlARPPE6ciMgjN+ 4P9g== X-Gm-Message-State: APzg51AvxHlGwgkArdL0mS/p5CAST19DpOnQg4azxQIpYCq+vD2ThQMk j55s2SS9HufSwyB2zwqHLtCei175 X-Received: by 2002:a62:6948:: with SMTP id e69-v6mr21570970pfc.166.1536556002390; Sun, 09 Sep 2018 22:06:42 -0700 (PDT) Received: from localhost.localdomain ([2601:646:877f:9499::2887]) by smtp.gmail.com with ESMTPSA id x24-v6sm18819188pfh.67.2018.09.09.22.06.41 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Sun, 09 Sep 2018 22:06:41 -0700 (PDT) From: Khem Raj To: openembedded-devel@lists.openembedded.org Date: Sun, 9 Sep 2018 22:06:24 -0700 Message-Id: <20180910050629.16170-5-raj.khem@gmail.com> X-Mailer: git-send-email 2.18.0 In-Reply-To: <20180910050629.16170-1-raj.khem@gmail.com> References: <20180910050629.16170-1-raj.khem@gmail.com> Subject: [oe] [meta-networking][PATCH 05/10] openflow: Fix build with openSSL 1.1.x 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: , MIME-Version: 1.0 Sender: openembedded-devel-bounces@lists.openembedded.org Errors-To: openembedded-devel-bounces@lists.openembedded.org Signed-off-by: Khem Raj --- ...generate-not-static-get_dh-functions.patch | 33 +++++++++++++++++++ .../openflow/openflow_git.bb | 1 + 2 files changed, 34 insertions(+) create mode 100644 meta-networking/recipes-protocols/openflow/openflow/0001-generate-not-static-get_dh-functions.patch -- 2.18.0 -- _______________________________________________ Openembedded-devel mailing list Openembedded-devel@lists.openembedded.org http://lists.openembedded.org/mailman/listinfo/openembedded-devel diff --git a/meta-networking/recipes-protocols/openflow/openflow/0001-generate-not-static-get_dh-functions.patch b/meta-networking/recipes-protocols/openflow/openflow/0001-generate-not-static-get_dh-functions.patch new file mode 100644 index 0000000000..4acae80fa7 --- /dev/null +++ b/meta-networking/recipes-protocols/openflow/openflow/0001-generate-not-static-get_dh-functions.patch @@ -0,0 +1,33 @@ +From 0fe6770b617af7e400abc6f8652c1417d4c3575e Mon Sep 17 00:00:00 2001 +From: Khem Raj +Date: Sat, 8 Sep 2018 22:49:15 -0700 +Subject: [PATCH] generate not static get_dh* functions + +Fixes build with OpenSSL 1.1.x + +Upstream-Status: Pending + +Signed-off-by: Khem Raj +--- + lib/automake.mk | 5 +++-- + 1 file changed, 3 insertions(+), 2 deletions(-) + +diff --git a/lib/automake.mk b/lib/automake.mk +index bfbeb94..b53909a 100644 +--- a/lib/automake.mk ++++ b/lib/automake.mk +@@ -113,8 +113,9 @@ lib/dhparams.c: lib/dh1024.pem lib/dh2048.pem lib/dh4096.pem + (echo '#include "lib/dhparams.h"' && \ + openssl dhparam -C -in $(srcdir)/lib/dh1024.pem -noout && \ + openssl dhparam -C -in $(srcdir)/lib/dh2048.pem -noout && \ +- openssl dhparam -C -in $(srcdir)/lib/dh4096.pem -noout) \ +- | sed 's/\(get_dh[0-9]*\)()/\1(void)/' > lib/dhparams.c.tmp ++ openssl dhparam -C -in $(srcdir)/lib/dh4096.pem -noout) | \ ++ sed -e 's/\(get_dh[0-9]*\)()/\1(void)/' \ ++ -e 's/static DH \*get_dh/DH \*get_dh/' > lib/dhparams.c.tmp + mv lib/dhparams.c.tmp lib/dhparams.c + endif + +-- +2.18.0 + diff --git a/meta-networking/recipes-protocols/openflow/openflow_git.bb b/meta-networking/recipes-protocols/openflow/openflow_git.bb index eceb45e94f..b6cef0730a 100644 --- a/meta-networking/recipes-protocols/openflow/openflow_git.bb +++ b/meta-networking/recipes-protocols/openflow/openflow_git.bb @@ -6,4 +6,5 @@ PV = "1.0+git${SRCPV}" SRC_URI += "\ file://0001-Check-and-use-strlcpy-from-libc-before-defining-own.patch \ file://0002-lib-netdev-Adjust-header-include-sequence.patch \ + file://0001-generate-not-static-get_dh-functions.patch \ " From patchwork Mon Sep 10 05:06:25 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Khem Raj X-Patchwork-Id: 146275 Delivered-To: patch@linaro.org Received: by 2002:a2e:1648:0:0:0:0:0 with SMTP id 8-v6csp2078805ljw; Sun, 9 Sep 2018 22:08:15 -0700 (PDT) X-Google-Smtp-Source: ANB0VdZ6SbAVTmss2b8fGAIXnTjminM1Ev0S1vuDeFJKNLg3uakP9Han1cquUN2EJdSgtSMEvjWA X-Received: by 2002:a65:4384:: with SMTP id m4-v6mr20536616pgp.265.1536556095039; Sun, 09 Sep 2018 22:08:15 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1536556095; cv=none; d=google.com; s=arc-20160816; b=mFpPZ6GwvCcrMUBaOnGrOcPmlVbSDo783EqS9mbkwPAj49bRfpClNWb6W/nAqAm65P vejwCY4wT3NaNPnwAn5tjRWJXZ0Wtj8d/hFXrP9rbE7KnZk6jSvRWfUfKOM7nQnx4IFr 7leSj0W7y/zQXKzIMBeWFR3ne361pvLfTg5UT6TFEmBrDQ8BerKs336aCHGXpIrflQ9a aYUqA3r8NNTpEYkUJTUobK9QEIgTY4/WzFZKGsNT8uaqwBVroarkVvRGhfQa1ZslcthV Ws9g281i3R5U5PhaBtjDyvygcK0NeiGpb4aPBsFl2P2V7aGqm1L6wAjr/YQtx5dQrSa4 SyDg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=errors-to:sender:content-transfer-encoding:mime-version :list-subscribe:list-help:list-post:list-archive:list-unsubscribe :list-id:precedence:subject:references:in-reply-to:message-id:date :to:from:dkim-signature:delivered-to; bh=eQQJwJYWusnCFEtNNwzXvYjMrHhcfFc66v1AkCcu1fc=; b=hjRaPRJq1LkfZ77Cl9Wwa60AhlN9zIFKv/moYTJtvQUTWhpAyKNfNvHZttKGaWFLiL llBip9Ax+T9yDj6rrmipo7OJNAbkAwPNNckfyRvZXt3atzRd/fqbHyOZNYIwg9Mj8KQM IGpLKndy0j5Y10SAPX/yY1MdbZlf7DyWivonX5tnQnaCiGszM3jwcedJh6RTeXZchm5G fgpXlaLPs8U1The/2PpIu1uTMxC54gct1eqO+FgAv6hahCWY6a2Db0zNTp5G9qp19QGa IgYqvg9oedzHEOUVDAjOYDj3tQK6ykBMi6X922/cH0JOu3kBt1DNb5ocWMys95t11Brk rWxw== ARC-Authentication-Results: i=1; mx.google.com; dkim=neutral (body hash did not verify) header.i=@gmail.com header.s=20161025 header.b=YTPja+MV; 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 l12-v6si15130061plt.440.2018.09.09.22.08.14; Sun, 09 Sep 2018 22:08:15 -0700 (PDT) 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=YTPja+MV; 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 layers.openembedded.org (localhost [127.0.0.1]) by mail.openembedded.org (Postfix) with ESMTP id 72E587973E; Mon, 10 Sep 2018 05:07:45 +0000 (UTC) X-Original-To: openembedded-devel@lists.openembedded.org Delivered-To: openembedded-devel@lists.openembedded.org Received: from mail-pf1-f170.google.com (mail-pf1-f170.google.com [209.85.210.170]) by mail.openembedded.org (Postfix) with ESMTP id 5DA1660190 for ; Mon, 10 Sep 2018 05:06:44 +0000 (UTC) Received: by mail-pf1-f170.google.com with SMTP id s13-v6so9828706pfi.7 for ; Sun, 09 Sep 2018 22:06:45 -0700 (PDT) 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; bh=gLWzsCCLRxubaKJ8Kzh6Lg3LxZoM8LN2q4GSI0lWwMI=; b=YTPja+MV1B/tQgPpCKx5zauypTJ7Obp+UwrgJXK3KOHhHVKMWiPg6SRitsqleLZ6AS HMZudbx91pX9/e3xgiJhclZ2LuR42bF8oQX1vd5TbryzgUEroUXJ7ITs6gFAf5F1ve5t REpukepTs4q2XqgkmBe3gqGuQaGnwXX3pO58OwUrtKZ2AsjYhoFOAa6fxpgnRaOu12Gy 3dzYDVXybu9sx86dNu6VSEJX/wa5Wg9Fk61TY2UM9oyKytvfehtJ3rMtA07fLbK7oTW8 LShBH2b0g2ZbZMFMEI2JLgo8w5dz+J7MnoVtyAF23fYY3O6sLEnwlG/5IB2Pl9UQFVXd smRw== 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=gLWzsCCLRxubaKJ8Kzh6Lg3LxZoM8LN2q4GSI0lWwMI=; b=a9DuXZy19eTnqhap1keb6f4QFY6Z1Ek93CQ4bFlq6pH89iwqzVbGstRAdrk5obJffK gYwfpKYm3vIozUUixDrrG5QKVKDPtv5fi9M/3yNVqWYLYL8I+hQs0bNjxHzBUgHbFiJ9 JA35pE4rvEOELCftRh7gVpKfUvMLo7E3O1FDcDc+qDVLat2Axpfkr8dtvqYDrV5AM2Ek 3I3dxLcJxRJ1mE9rKnmJmJOEmabOveiIVuUbSdasau3NKx9y8l5z37tcqt6CDlFNdPW4 3jjxcSCNff+DMICyIxAAhDVCyPfzUZI1MMizSBCSmE0vQk5JuU33ZcQVZhPHtVdq20l6 26qQ== X-Gm-Message-State: APzg51DvMMx0jPAm23MTctHBn/6Do323iBpA7TjCId6x+3UXRqtpWNK4 GZiz7N/I2ZieiOS6djS2zM5bl//H X-Received: by 2002:a62:d1b:: with SMTP id v27-v6mr21088704pfi.87.1536556003505; Sun, 09 Sep 2018 22:06:43 -0700 (PDT) Received: from localhost.localdomain ([2601:646:877f:9499::2887]) by smtp.gmail.com with ESMTPSA id x24-v6sm18819188pfh.67.2018.09.09.22.06.42 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Sun, 09 Sep 2018 22:06:42 -0700 (PDT) From: Khem Raj To: openembedded-devel@lists.openembedded.org Date: Sun, 9 Sep 2018 22:06:25 -0700 Message-Id: <20180910050629.16170-6-raj.khem@gmail.com> X-Mailer: git-send-email 2.18.0 In-Reply-To: <20180910050629.16170-1-raj.khem@gmail.com> References: <20180910050629.16170-1-raj.khem@gmail.com> Subject: [oe] [meta-oe][PATCH 06/10] opencv: Update to 3.4.3 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: , MIME-Version: 1.0 Sender: openembedded-devel-bounces@lists.openembedded.org Errors-To: openembedded-devel-bounces@lists.openembedded.org * Drop backported patches * Update versions of external submodules Signed-off-by: Khem Raj --- .../opencv/opencv/0001-Dont-use-isystem.patch | 26 - ...-GCC-7.1.1-compilation-issue-with-sa.patch | 127 -- ...otene-don-t-use-__asm__-with-aarch64.patch | 1250 ----------------- .../0002-Do-not-enable-asm-with-clang.patch | 993 ------------- ...ecs-refactoring-improve-code-quality.patch | 656 --------- .../0003-To-fix-errors-as-following.patch | 49 +- ...proc-test-add-checks-for-remove-call.patch | 186 --- .../opencv/opencv/CVE-2017-14136.patch | 288 ---- .../opencv/opencv/already-exists.patch | 394 ------ .../opencv/opencv/fixpkgconfig.patch | 21 +- .../opencv/opencv/javagen.patch | 16 - .../opencv/opencv/protobuf.patch | 57 - .../opencv/opencv/tinydnn.patch | 34 - .../opencv/{opencv_3.3.bb => opencv_3.4.3.bb} | 39 +- 14 files changed, 42 insertions(+), 4094 deletions(-) delete mode 100644 meta-oe/recipes-support/opencv/opencv/0001-Dont-use-isystem.patch delete mode 100644 meta-oe/recipes-support/opencv/opencv/0001-build-workaround-GCC-7.1.1-compilation-issue-with-sa.patch delete mode 100644 meta-oe/recipes-support/opencv/opencv/0001-carotene-don-t-use-__asm__-with-aarch64.patch delete mode 100644 meta-oe/recipes-support/opencv/opencv/0002-Do-not-enable-asm-with-clang.patch delete mode 100644 meta-oe/recipes-support/opencv/opencv/0002-imgcodecs-refactoring-improve-code-quality.patch delete mode 100644 meta-oe/recipes-support/opencv/opencv/0003-imgproc-test-add-checks-for-remove-call.patch delete mode 100644 meta-oe/recipes-support/opencv/opencv/CVE-2017-14136.patch delete mode 100644 meta-oe/recipes-support/opencv/opencv/already-exists.patch delete mode 100644 meta-oe/recipes-support/opencv/opencv/javagen.patch delete mode 100644 meta-oe/recipes-support/opencv/opencv/protobuf.patch delete mode 100644 meta-oe/recipes-support/opencv/opencv/tinydnn.patch rename meta-oe/recipes-support/opencv/{opencv_3.3.bb => opencv_3.4.3.bb} (88%) -- 2.18.0 -- _______________________________________________ Openembedded-devel mailing list Openembedded-devel@lists.openembedded.org http://lists.openembedded.org/mailman/listinfo/openembedded-devel diff --git a/meta-oe/recipes-support/opencv/opencv/0001-Dont-use-isystem.patch b/meta-oe/recipes-support/opencv/opencv/0001-Dont-use-isystem.patch deleted file mode 100644 index 6dd48fcdc3..0000000000 --- a/meta-oe/recipes-support/opencv/opencv/0001-Dont-use-isystem.patch +++ /dev/null @@ -1,26 +0,0 @@ -From 2bc6bb9831d07f035fea74ea745cea43dd5f9ef9 Mon Sep 17 00:00:00 2001 -From: Khem Raj -Date: Sat, 9 Sep 2017 23:48:31 -0700 -Subject: [PATCH] Dont use isystem - -Signed-off-by: Khem Raj ---- -Upstream-Status: Pending - - cmake/OpenCVPCHSupport.cmake | 10 ++++------ - 1 file changed, 4 insertions(+), 6 deletions(-) - -Index: git/cmake/OpenCVPCHSupport.cmake -=================================================================== ---- git.orig/cmake/OpenCVPCHSupport.cmake -+++ git/cmake/OpenCVPCHSupport.cmake -@@ -17,7 +17,8 @@ IF(CMAKE_COMPILER_IS_GNUCXX) - IF(NOT CMAKE_CXX_COMPILER_VERSION VERSION_LESS "4.2.0") - SET(PCHSupport_FOUND TRUE) - ENDIF() -- -+ SET(CMAKE_INCLUDE_SYSTEM_FLAG_C "-I") -+ SET(CMAKE_INCLUDE_SYSTEM_FLAG_CXX "-I") - SET(_PCH_include_prefix "-I") - SET(_PCH_isystem_prefix "-isystem") - SET(_PCH_define_prefix "-D") diff --git a/meta-oe/recipes-support/opencv/opencv/0001-build-workaround-GCC-7.1.1-compilation-issue-with-sa.patch b/meta-oe/recipes-support/opencv/opencv/0001-build-workaround-GCC-7.1.1-compilation-issue-with-sa.patch deleted file mode 100644 index 0140633db3..0000000000 --- a/meta-oe/recipes-support/opencv/opencv/0001-build-workaround-GCC-7.1.1-compilation-issue-with-sa.patch +++ /dev/null @@ -1,127 +0,0 @@ -Upstream-Status: Backport [https://github.com/opencv/opencv/pull/9376/commits/0d854db361106dfcb055231fd0112c5b85ef2287] - -Fix CVEs for opencv 3.3. - -* CVE-2017-12597 -* CVE-2017-12598 -* CVE-2017-12599 -* CVE-2017-12600 -* CVE-2017-12601 -* CVE-2017-12602 -* CVE-2017-12603 -* CVE-2017-12604 -* CVE-2017-12605 -* CVE-2017-12606 -* CVE-2017-12862 -* CVE-2017-12863 -* CVE-2017-12864 - -Signed-off-by: Kai Kang ---- -From 0d854db361106dfcb055231fd0112c5b85ef2287 Mon Sep 17 00:00:00 2001 -From: Alexander Alekhin -Date: Tue, 15 Aug 2017 21:45:05 +0000 -Subject: [PATCH 1/3] build: workaround GCC 7.1.1 compilation issue with - sanitize flags - -Version: gcc (GCC) 7.1.1 20170622 (Red Hat 7.1.1-3) -Flags: -fsanitize=address,undefined ---- - modules/ts/src/cuda_test.cpp | 56 ++++++++++++++++++++++++++------------------ - 1 file changed, 33 insertions(+), 23 deletions(-) - -diff --git a/modules/ts/src/cuda_test.cpp b/modules/ts/src/cuda_test.cpp -index a48e0a087..eb4cee136 100644 ---- a/modules/ts/src/cuda_test.cpp -+++ b/modules/ts/src/cuda_test.cpp -@@ -322,16 +322,20 @@ namespace cvtest - - if (m1.size() != m2.size()) - { -- return AssertionFailure() << "Matrices \"" << expr1 << "\" and \"" << expr2 << "\" have different sizes : \"" -- << expr1 << "\" [" << PrintToString(m1.size()) << "] vs \"" -- << expr2 << "\" [" << PrintToString(m2.size()) << "]"; -+ std::stringstream msg; -+ msg << "Matrices \"" << expr1 << "\" and \"" << expr2 << "\" have different sizes : \"" -+ << expr1 << "\" [" << PrintToString(m1.size()) << "] vs \"" -+ << expr2 << "\" [" << PrintToString(m2.size()) << "]"; -+ return AssertionFailure() << msg.str(); - } - - if (m1.type() != m2.type()) - { -- return AssertionFailure() << "Matrices \"" << expr1 << "\" and \"" << expr2 << "\" have different types : \"" -- << expr1 << "\" [" << PrintToString(MatType(m1.type())) << "] vs \"" -- << expr2 << "\" [" << PrintToString(MatType(m2.type())) << "]"; -+ std::stringstream msg; -+ msg << "Matrices \"" << expr1 << "\" and \"" << expr2 << "\" have different types : \"" -+ << expr1 << "\" [" << PrintToString(MatType(m1.type())) << "] vs \"" -+ << expr2 << "\" [" << PrintToString(MatType(m2.type())) << "]"; -+ return AssertionFailure() << msg.str(); - } - - Mat diff; -@@ -343,12 +347,14 @@ namespace cvtest - - if (maxVal > eps) - { -- return AssertionFailure() << "The max difference between matrices \"" << expr1 << "\" and \"" << expr2 -- << "\" is " << maxVal << " at (" << maxLoc.y << ", " << maxLoc.x / m1.channels() << ")" -- << ", which exceeds \"" << eps_expr << "\", where \"" -- << expr1 << "\" at (" << maxLoc.y << ", " << maxLoc.x / m1.channels() << ") evaluates to " << printMatVal(m1, maxLoc) << ", \"" -- << expr2 << "\" at (" << maxLoc.y << ", " << maxLoc.x / m1.channels() << ") evaluates to " << printMatVal(m2, maxLoc) << ", \"" -- << eps_expr << "\" evaluates to " << eps; -+ std::stringstream msg; -+ msg << "The max difference between matrices \"" << expr1 << "\" and \"" << expr2 -+ << "\" is " << maxVal << " at (" << maxLoc.y << ", " << maxLoc.x / m1.channels() << ")" -+ << ", which exceeds \"" << eps_expr << "\", where \"" -+ << expr1 << "\" at (" << maxLoc.y << ", " << maxLoc.x / m1.channels() << ") evaluates to " << printMatVal(m1, maxLoc) << ", \"" -+ << expr2 << "\" at (" << maxLoc.y << ", " << maxLoc.x / m1.channels() << ") evaluates to " << printMatVal(m2, maxLoc) << ", \"" -+ << eps_expr << "\" evaluates to " << eps; -+ return AssertionFailure() << msg.str(); - } - - return AssertionSuccess(); -@@ -469,9 +475,11 @@ namespace cvtest - { - if (gold.size() != actual.size()) - { -- return testing::AssertionFailure() << "KeyPoints size mistmach\n" -- << "\"" << gold_expr << "\" : " << gold.size() << "\n" -- << "\"" << actual_expr << "\" : " << actual.size(); -+ std::stringstream msg; -+ msg << "KeyPoints size mistmach\n" -+ << "\"" << gold_expr << "\" : " << gold.size() << "\n" -+ << "\"" << actual_expr << "\" : " << actual.size(); -+ return AssertionFailure() << msg.str(); - } - - std::sort(actual.begin(), actual.end(), KeyPointLess()); -@@ -484,14 +492,16 @@ namespace cvtest - - if (!keyPointsEquals(p1, p2)) - { -- return testing::AssertionFailure() << "KeyPoints differ at " << i << "\n" -- << "\"" << gold_expr << "\" vs \"" << actual_expr << "\" : \n" -- << "pt : " << testing::PrintToString(p1.pt) << " vs " << testing::PrintToString(p2.pt) << "\n" -- << "size : " << p1.size << " vs " << p2.size << "\n" -- << "angle : " << p1.angle << " vs " << p2.angle << "\n" -- << "response : " << p1.response << " vs " << p2.response << "\n" -- << "octave : " << p1.octave << " vs " << p2.octave << "\n" -- << "class_id : " << p1.class_id << " vs " << p2.class_id; -+ std::stringstream msg; -+ msg << "KeyPoints differ at " << i << "\n" -+ << "\"" << gold_expr << "\" vs \"" << actual_expr << "\" : \n" -+ << "pt : " << testing::PrintToString(p1.pt) << " vs " << testing::PrintToString(p2.pt) << "\n" -+ << "size : " << p1.size << " vs " << p2.size << "\n" -+ << "angle : " << p1.angle << " vs " << p2.angle << "\n" -+ << "response : " << p1.response << " vs " << p2.response << "\n" -+ << "octave : " << p1.octave << " vs " << p2.octave << "\n" -+ << "class_id : " << p1.class_id << " vs " << p2.class_id; -+ return AssertionFailure() << msg.str(); - } - } - --- -2.14.1 - diff --git a/meta-oe/recipes-support/opencv/opencv/0001-carotene-don-t-use-__asm__-with-aarch64.patch b/meta-oe/recipes-support/opencv/opencv/0001-carotene-don-t-use-__asm__-with-aarch64.patch deleted file mode 100644 index a1a56e0e4d..0000000000 --- a/meta-oe/recipes-support/opencv/opencv/0001-carotene-don-t-use-__asm__-with-aarch64.patch +++ /dev/null @@ -1,1250 +0,0 @@ -From 353fc92618ce0dc6bab4a3e8bff1c13c3b613110 Mon Sep 17 00:00:00 2001 -From: Alexander Alekhin -Date: Wed, 23 Aug 2017 17:41:23 +0300 -Subject: [PATCH 1/2] carotene: don't use __asm__ with aarch64 - ---- -Upstream-Status: Backport - - 3rdparty/carotene/src/channel_extract.cpp | 4 +- - 3rdparty/carotene/src/channels_combine.cpp | 2 +- - 3rdparty/carotene/src/colorconvert.cpp | 104 ++++++++++++++--------------- - 3rdparty/carotene/src/convert.cpp | 54 +++++++-------- - 3rdparty/carotene/src/convert_scale.cpp | 72 ++++++++++---------- - 3rdparty/carotene/src/gaussian_blur.cpp | 6 +- - 3rdparty/carotene/src/pyramid.cpp | 20 +++--- - 3rdparty/carotene/src/scharr.cpp | 4 +- - 8 files changed, 133 insertions(+), 133 deletions(-) - -diff --git a/3rdparty/carotene/src/channel_extract.cpp b/3rdparty/carotene/src/channel_extract.cpp -index f663bc6005..8238a3ece8 100644 ---- a/3rdparty/carotene/src/channel_extract.cpp -+++ b/3rdparty/carotene/src/channel_extract.cpp -@@ -231,7 +231,7 @@ void extract4(const Size2D &size, - srcStride == dst2Stride && \ - srcStride == dst3Stride && - --#if defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 -+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 - - #define SPLIT_ASM2(sgn, bits) __asm__ ( \ - "vld2." #bits " {d0, d2}, [%[in0]] \n\t" \ -@@ -351,7 +351,7 @@ void extract4(const Size2D &size, - } \ - } - --#if defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 -+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 - - #define ALPHA_QUAD(sgn, bits) { \ - internal::prefetch(src + sj); \ -diff --git a/3rdparty/carotene/src/channels_combine.cpp b/3rdparty/carotene/src/channels_combine.cpp -index 157c8b8121..fc98fb9181 100644 ---- a/3rdparty/carotene/src/channels_combine.cpp -+++ b/3rdparty/carotene/src/channels_combine.cpp -@@ -77,7 +77,7 @@ namespace CAROTENE_NS { - dstStride == src2Stride && \ - dstStride == src3Stride && - --#if defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 -+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 - - #define MERGE_ASM2(sgn, bits) __asm__ ( \ - "vld1." #bits " {d0-d1}, [%[in0]] \n\t" \ -diff --git a/3rdparty/carotene/src/colorconvert.cpp b/3rdparty/carotene/src/colorconvert.cpp -index 3037fe672a..26ae54b15c 100644 ---- a/3rdparty/carotene/src/colorconvert.cpp -+++ b/3rdparty/carotene/src/colorconvert.cpp -@@ -97,7 +97,7 @@ void rgb2gray(const Size2D &size, COLOR_SPACE color_space, - const u32 G2Y = color_space == COLOR_SPACE_BT601 ? G2Y_BT601 : G2Y_BT709; - const u32 B2Y = color_space == COLOR_SPACE_BT601 ? B2Y_BT601 : B2Y_BT709; - --#if defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 -+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 - register int16x4_t v_r2y asm ("d31") = vmov_n_s16(R2Y); - register int16x4_t v_g2y asm ("d30") = vmov_n_s16(G2Y); - register int16x4_t v_b2y asm ("d29") = vmov_n_s16(B2Y); -@@ -116,7 +116,7 @@ void rgb2gray(const Size2D &size, COLOR_SPACE color_space, - u8 * dst = internal::getRowPtr(dstBase, dstStride, i); - size_t sj = 0u, dj = 0u; - --#if defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 -+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 - for (; dj < roiw8; sj += 24, dj += 8) - { - internal::prefetch(src + sj); -@@ -198,7 +198,7 @@ void rgbx2gray(const Size2D &size, COLOR_SPACE color_space, - const u32 G2Y = color_space == COLOR_SPACE_BT601 ? G2Y_BT601 : G2Y_BT709; - const u32 B2Y = color_space == COLOR_SPACE_BT601 ? B2Y_BT601 : B2Y_BT709; - --#if defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 -+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 - register int16x4_t v_r2y asm ("d31") = vmov_n_s16(R2Y); - register int16x4_t v_g2y asm ("d30") = vmov_n_s16(G2Y); - register int16x4_t v_b2y asm ("d29") = vmov_n_s16(B2Y); -@@ -217,7 +217,7 @@ void rgbx2gray(const Size2D &size, COLOR_SPACE color_space, - u8 * dst = internal::getRowPtr(dstBase, dstStride, i); - size_t sj = 0u, dj = 0u; - --#if defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 -+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 - for (; dj < roiw8; sj += 32, dj += 8) - { - internal::prefetch(src + sj); -@@ -300,7 +300,7 @@ void bgr2gray(const Size2D &size, COLOR_SPACE color_space, - const u32 G2Y = color_space == COLOR_SPACE_BT601 ? G2Y_BT601 : G2Y_BT709; - const u32 B2Y = color_space == COLOR_SPACE_BT601 ? B2Y_BT601 : B2Y_BT709; - --#if defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 -+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 - register int16x4_t v_r2y asm ("d31") = vmov_n_s16(R2Y); - register int16x4_t v_g2y asm ("d30") = vmov_n_s16(G2Y); - register int16x4_t v_b2y asm ("d29") = vmov_n_s16(B2Y); -@@ -319,7 +319,7 @@ void bgr2gray(const Size2D &size, COLOR_SPACE color_space, - u8 * dst = internal::getRowPtr(dstBase, dstStride, i); - size_t sj = 0u, dj = 0u; - --#if defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 -+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 - for (; dj < roiw8; sj += 24, dj += 8) - { - internal::prefetch(src + sj); -@@ -402,7 +402,7 @@ void bgrx2gray(const Size2D &size, COLOR_SPACE color_space, - const u32 G2Y = color_space == COLOR_SPACE_BT601 ? G2Y_BT601 : G2Y_BT709; - const u32 B2Y = color_space == COLOR_SPACE_BT601 ? B2Y_BT601 : B2Y_BT709; - --#if defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 -+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 - register int16x4_t v_r2y asm ("d31") = vmov_n_s16(R2Y); - register int16x4_t v_g2y asm ("d30") = vmov_n_s16(G2Y); - register int16x4_t v_b2y asm ("d29") = vmov_n_s16(B2Y); -@@ -421,7 +421,7 @@ void bgrx2gray(const Size2D &size, COLOR_SPACE color_space, - u8 * dst = internal::getRowPtr(dstBase, dstStride, i); - size_t sj = 0u, dj = 0u; - --#if defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 -+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 - for (; dj < roiw8; sj += 32, dj += 8) - { - internal::prefetch(src + sj); -@@ -512,7 +512,7 @@ void gray2rgb(const Size2D &size, - for (; sj < roiw16; sj += 16, dj += 48) - { - internal::prefetch(src + sj); --#if defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 -+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 - __asm__ ( - "vld1.8 {d0-d1}, [%[in0]] \n\t" - "vmov.8 q1, q0 \n\t" -@@ -538,7 +538,7 @@ void gray2rgb(const Size2D &size, - - if (sj < roiw8) - { --#if defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 -+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 - __asm__ ( - "vld1.8 {d0}, [%[in]] \n\t" - "vmov.8 d1, d0 \n\t" -@@ -584,7 +584,7 @@ void gray2rgbx(const Size2D &size, - size_t roiw16 = size.width >= 15 ? size.width - 15 : 0; - size_t roiw8 = size.width >= 7 ? size.width - 7 : 0; - --#if defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 -+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 - register uint8x16_t vc255 asm ("q4") = vmovq_n_u8(255); - #else - uint8x16x4_t vRgba; -@@ -602,7 +602,7 @@ void gray2rgbx(const Size2D &size, - for (; sj < roiw16; sj += 16, dj += 64) - { - internal::prefetch(src + sj); --#if defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 -+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 - __asm__ ( - "vld1.8 {d0-d1}, [%[in0]] \n\t" - "vmov.8 q1, q0 \n\t" -@@ -628,7 +628,7 @@ void gray2rgbx(const Size2D &size, - - if (sj < roiw8) - { --#if defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 -+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 - __asm__ ( - "vld1.8 {d5}, [%[in]] \n\t" - "vmov.8 d6, d5 \n\t" -@@ -672,7 +672,7 @@ void rgb2rgbx(const Size2D &size, - internal::assertSupportedConfiguration(); - #ifdef CAROTENE_NEON - size_t roiw8 = size.width >= 7 ? size.width - 7 : 0; --#if defined(__GNUC__) && defined(__arm__) -+#if !defined(__aarch64__) && defined(__GNUC__) && defined(__arm__) - register uint8x8_t vc255_0 asm ("d3") = vmov_n_u8(255); - #else - size_t roiw16 = size.width >= 15 ? size.width - 15 : 0; -@@ -688,7 +688,7 @@ void rgb2rgbx(const Size2D &size, - u8 * dst = internal::getRowPtr(dstBase, dstStride, i); - size_t sj = 0u, dj = 0u, j = 0u; - --#if defined(__GNUC__) && defined(__arm__) -+#if !defined(__aarch64__) && defined(__GNUC__) && defined(__arm__) - for (; j < roiw8; sj += 24, dj += 32, j += 8) - { - internal::prefetch(src + sj); -@@ -742,7 +742,7 @@ void rgbx2rgb(const Size2D &size, - internal::assertSupportedConfiguration(); - #ifdef CAROTENE_NEON - size_t roiw8 = size.width >= 7 ? size.width - 7 : 0; --#if !defined(__GNUC__) || !defined(__arm__) -+#if !(!defined(__aarch64__) && defined(__GNUC__) && defined(__arm__)) - size_t roiw16 = size.width >= 15 ? size.width - 15 : 0; - union { uint8x16x4_t v4; uint8x16x3_t v3; } v_dst0; - union { uint8x8x4_t v4; uint8x8x3_t v3; } v_dst; -@@ -754,7 +754,7 @@ void rgbx2rgb(const Size2D &size, - u8 * dst = internal::getRowPtr(dstBase, dstStride, i); - size_t sj = 0u, dj = 0u, j = 0u; - --#if defined(__GNUC__) && defined(__arm__) -+#if !defined(__aarch64__) && defined(__GNUC__) && defined(__arm__) - for (; j < roiw8; sj += 32, dj += 24, j += 8) - { - internal::prefetch(src + sj); -@@ -805,7 +805,7 @@ void rgb2bgr(const Size2D &size, - { - internal::assertSupportedConfiguration(); - #ifdef CAROTENE_NEON --#if !defined(__GNUC__) || !defined(__arm__) -+#if !(!defined(__aarch64__) && defined(__GNUC__) && defined(__arm__)) - size_t roiw16 = size.width >= 15 ? size.width - 15 : 0; - #endif - size_t roiw8 = size.width >= 7 ? size.width - 7 : 0; -@@ -817,7 +817,7 @@ void rgb2bgr(const Size2D &size, - size_t sj = 0u, dj = 0u, j = 0u; - - --#if defined(__GNUC__) && defined(__arm__) -+#if !defined(__aarch64__) && defined(__GNUC__) && defined(__arm__) - for (; j < roiw8; sj += 24, dj += 24, j += 8) - { - internal::prefetch(src + sj); -@@ -874,7 +874,7 @@ void rgbx2bgrx(const Size2D &size, - { - internal::assertSupportedConfiguration(); - #ifdef CAROTENE_NEON --#if !defined(__GNUC__) || !defined(__arm__) -+#if !(!defined(__aarch64__) && defined(__GNUC__) && defined(__arm__)) - size_t roiw16 = size.width >= 15 ? size.width - 15 : 0; - #endif - size_t roiw8 = size.width >= 7 ? size.width - 7 : 0; -@@ -885,7 +885,7 @@ void rgbx2bgrx(const Size2D &size, - u8 * dst = internal::getRowPtr(dstBase, dstStride, i); - size_t sj = 0u, dj = 0u, j = 0u; - --#if defined(__GNUC__) && defined(__arm__) -+#if !defined(__aarch64__) && defined(__GNUC__) && defined(__arm__) - for (; j < roiw8; sj += 32, dj += 32, j += 8) - { - internal::prefetch(src + sj); -@@ -943,7 +943,7 @@ void rgbx2bgr(const Size2D &size, - { - internal::assertSupportedConfiguration(); - #ifdef CAROTENE_NEON --#if !defined(__GNUC__) || !defined(__arm__) -+#if !(!defined(__aarch64__) && defined(__GNUC__) && defined(__arm__)) - size_t roiw16 = size.width >= 15 ? size.width - 15 : 0; - #endif - size_t roiw8 = size.width >= 7 ? size.width - 7 : 0; -@@ -954,7 +954,7 @@ void rgbx2bgr(const Size2D &size, - u8 * dst = internal::getRowPtr(dstBase, dstStride, i); - size_t sj = 0u, dj = 0u, j = 0u; - --#if defined(__GNUC__) && defined(__arm__) -+#if !defined(__aarch64__) && defined(__GNUC__) && defined(__arm__) - for (; j < roiw8; sj += 32, dj += 24, j += 8) - { - internal::prefetch(src + sj); -@@ -1010,7 +1010,7 @@ void rgb2bgrx(const Size2D &size, - { - internal::assertSupportedConfiguration(); - #ifdef CAROTENE_NEON --#if defined(__GNUC__) && defined(__arm__) -+#if !defined(__aarch64__) && defined(__GNUC__) && defined(__arm__) - register uint8x8_t vc255 asm ("d3") = vmov_n_u8(255); - #else - union { uint8x16x4_t v4; uint8x16x3_t v3; } vals0; -@@ -1019,7 +1019,7 @@ void rgb2bgrx(const Size2D &size, - vals8.v4.val[3] = vmov_n_u8(255); - #endif - --#if !defined(__GNUC__) || !defined(__arm__) -+#if !(!defined(__aarch64__) && defined(__GNUC__) && defined(__arm__)) - size_t roiw16 = size.width >= 15 ? size.width - 15 : 0; - #endif - size_t roiw8 = size.width >= 7 ? size.width - 7 : 0; -@@ -1030,7 +1030,7 @@ void rgb2bgrx(const Size2D &size, - u8 * dst = internal::getRowPtr(dstBase, dstStride, i); - size_t sj = 0u, dj = 0u, j = 0u; - --#if defined(__GNUC__) && defined(__arm__) -+#if !defined(__aarch64__) && defined(__GNUC__) && defined(__arm__) - for (; j < roiw8; sj += 24, dj += 32, j += 8) - { - internal::prefetch(src + sj); -@@ -1409,7 +1409,7 @@ inline void convertToHSV(const s32 r, const s32 g, const s32 b, - "d24","d25","d26","d27","d28","d29","d30","d31" \ - ); - --#if defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 -+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 - - #define YCRCB_CONSTS \ - register int16x4_t vcYR asm ("d31") = vmov_n_s16(4899); \ -@@ -1555,7 +1555,7 @@ inline uint8x8x3_t convertToYCrCb( const int16x8_t& vR, const int16x8_t& vG, con - #define COEFF_G ( 8663) - #define COEFF_B (-17705) - --#if defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 -+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 - #define YUV420ALPHA3_CONST - #define YUV420ALPHA4_CONST register uint8x16_t c255 asm ("q13") = vmovq_n_u8(255); - #define YUV420ALPHA3_CONVERT -@@ -1852,7 +1852,7 @@ void rgb2hsv(const Size2D &size, - #ifdef CAROTENE_NEON - size_t roiw8 = size.width >= 7 ? size.width - 7 : 0; - const s32 hsv_shift = 12; --#if defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 -+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 - register const f32 vsdiv_table = f32(255 << hsv_shift); - register f32 vhdiv_table = f32(hrange << hsv_shift); - register const s32 vhrange = hrange; -@@ -1871,7 +1871,7 @@ void rgb2hsv(const Size2D &size, - for (; j < roiw8; sj += 24, dj += 24, j += 8) - { - internal::prefetch(src + sj); --#if defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 -+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 - CONVERT_TO_HSV_ASM(vld3.8 {d0-d2}, d0, d2) - #else - uint8x8x3_t vRgb = vld3_u8(src + sj); -@@ -1904,7 +1904,7 @@ void rgbx2hsv(const Size2D &size, - #ifdef CAROTENE_NEON - size_t roiw8 = size.width >= 7 ? size.width - 7 : 0; - const s32 hsv_shift = 12; --#if defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 -+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 - register const f32 vsdiv_table = f32(255 << hsv_shift); - register f32 vhdiv_table = f32(hrange << hsv_shift); - register const s32 vhrange = hrange; -@@ -1923,7 +1923,7 @@ void rgbx2hsv(const Size2D &size, - for (; j < roiw8; sj += 32, dj += 24, j += 8) - { - internal::prefetch(src + sj); --#if defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 -+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 - CONVERT_TO_HSV_ASM(vld4.8 {d0-d3}, d0, d2) - #else - uint8x8x4_t vRgb = vld4_u8(src + sj); -@@ -1956,7 +1956,7 @@ void bgr2hsv(const Size2D &size, - #ifdef CAROTENE_NEON - size_t roiw8 = size.width >= 7 ? size.width - 7 : 0; - const s32 hsv_shift = 12; --#if defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 -+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 - register const f32 vsdiv_table = f32(255 << hsv_shift); - register f32 vhdiv_table = f32(hrange << hsv_shift); - register const s32 vhrange = hrange; -@@ -1975,7 +1975,7 @@ void bgr2hsv(const Size2D &size, - for (; j < roiw8; sj += 24, dj += 24, j += 8) - { - internal::prefetch(src + sj); --#if defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 -+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 - CONVERT_TO_HSV_ASM(vld3.8 {d0-d2}, d2, d0) - #else - uint8x8x3_t vRgb = vld3_u8(src + sj); -@@ -2008,7 +2008,7 @@ void bgrx2hsv(const Size2D &size, - #ifdef CAROTENE_NEON - size_t roiw8 = size.width >= 7 ? size.width - 7 : 0; - const s32 hsv_shift = 12; --#if defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 -+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 - register const f32 vsdiv_table = f32(255 << hsv_shift); - register f32 vhdiv_table = f32(hrange << hsv_shift); - register const s32 vhrange = hrange; -@@ -2027,7 +2027,7 @@ void bgrx2hsv(const Size2D &size, - for (; j < roiw8; sj += 32, dj += 24, j += 8) - { - internal::prefetch(src + sj); --#if defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 -+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 - CONVERT_TO_HSV_ASM(vld4.8 {d0-d3}, d2, d0) - #else - uint8x8x4_t vRgb = vld4_u8(src + sj); -@@ -2068,7 +2068,7 @@ void rgbx2bgr565(const Size2D &size, - for (; j < roiw16; sj += 64, dj += 32, j += 16) - { - internal::prefetch(src + sj); --#if defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 -+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 - __asm__ ( - "vld4.8 {d2, d4, d6, d8}, [%[in0]] @ q0 q1 q2 q3 q4 \n\t" - "vld4.8 {d3, d5, d7, d9}, [%[in1]] @ xxxxxxxx rrrrRRRR ggggGGGG bbbbBBBB xxxxxxxx \n\t" -@@ -2122,7 +2122,7 @@ void rgb2bgr565(const Size2D &size, - for (; j < roiw16; sj += 48, dj += 32, j += 16) - { - internal::prefetch(src + sj); --#if defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 -+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 - __asm__ ( - "vld3.8 {d2, d4, d6}, [%[in0]] @ q0 q1 q2 q3 q4 \n\t" - "vld3.8 {d3, d5, d7}, [%[in1]] @ xxxxxxxx rrrrRRRR ggggGGGG bbbbBBBB xxxxxxxx \n\t" -@@ -2176,7 +2176,7 @@ void rgbx2rgb565(const Size2D &size, - for (; j < roiw16; sj += 64, dj += 32, j += 16) - { - internal::prefetch(src + sj); --#if defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 -+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 - __asm__ ( - "vld4.8 {d0, d2, d4, d6}, [%[in0]] @ q0 q1 q2 q3 \n\t" - "vld4.8 {d1, d3, d5, d7}, [%[in1]] @ rrrrRRRR ggggGGGG bbbbBBBB aaaaAAAA \n\t" -@@ -2230,7 +2230,7 @@ void rgb2rgb565(const Size2D &size, - for (; j < roiw16; sj += 48, dj += 32, j += 16) - { - internal::prefetch(src + sj); --#if defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 -+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 - __asm__ ( - "vld3.8 {d0, d2, d4}, [%[in0]] @ q0 q1 q2 q3 \n\t" - "vld3.8 {d1, d3, d5}, [%[in1]] @ rrrrRRRR ggggGGGG bbbbBBBB xxxxxxxx \n\t" -@@ -2285,7 +2285,7 @@ void rgb2ycrcb(const Size2D &size, - for (; j < roiw8; sj += 24, dj += 24, j += 8) - { - internal::prefetch(src + sj); --#if defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 -+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 - CONVERTTOYCRCB(vld3.8 {d0-d2}, d0, d1, d2) - #else - uint8x8x3_t vRgb = vld3_u8(src + sj); -@@ -2329,7 +2329,7 @@ void rgbx2ycrcb(const Size2D &size, - for (; j < roiw8; sj += 32, dj += 24, j += 8) - { - internal::prefetch(src + sj); --#if defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 -+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 - CONVERTTOYCRCB(vld4.8 {d0-d3}, d0, d1, d2) - #else - uint8x8x4_t vRgba = vld4_u8(src + sj); -@@ -2373,7 +2373,7 @@ void bgr2ycrcb(const Size2D &size, - for (; j < roiw8; sj += 24, dj += 24, j += 8) - { - internal::prefetch(src + sj); --#if defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 -+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 - CONVERTTOYCRCB(vld3.8 {d0-d2}, d2, d1, d0) - #else - uint8x8x3_t vBgr = vld3_u8(src + sj); -@@ -2417,7 +2417,7 @@ void bgrx2ycrcb(const Size2D &size, - for (; j < roiw8; sj += 32, dj += 24, j += 8) - { - internal::prefetch(src + sj); --#if defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 -+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 - CONVERTTOYCRCB(vld4.8 {d0-d3}, d2, d1, d0) - #else - uint8x8x4_t vBgra = vld4_u8(src + sj); -@@ -2499,7 +2499,7 @@ void yuv420sp2rgb(const Size2D &size, - internal::prefetch(uv + j); - internal::prefetch(y1 + j); - internal::prefetch(y2 + j); --#if defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 -+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 - CONVERTYUV420TORGB(3, d1, d0, q5, q6) - #else - convertYUV420.ToRGB(y1 + j, y2 + j, uv + j, dst1 + dj, dst2 + dj); -@@ -2545,7 +2545,7 @@ void yuv420sp2rgbx(const Size2D &size, - internal::prefetch(uv + j); - internal::prefetch(y1 + j); - internal::prefetch(y2 + j); --#if defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 -+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 - CONVERTYUV420TORGB(4, d1, d0, q5, q6) - #else - convertYUV420.ToRGB(y1 + j, y2 + j, uv + j, dst1 + dj, dst2 + dj); -@@ -2591,7 +2591,7 @@ void yuv420i2rgb(const Size2D &size, - internal::prefetch(uv + j); - internal::prefetch(y1 + j); - internal::prefetch(y2 + j); --#if defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 -+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 - CONVERTYUV420TORGB(3, d0, d1, q5, q6) - #else - convertYUV420.ToRGB(y1 + j, y2 + j, uv + j, dst1 + dj, dst2 + dj); -@@ -2637,7 +2637,7 @@ void yuv420i2rgbx(const Size2D &size, - internal::prefetch(uv + j); - internal::prefetch(y1 + j); - internal::prefetch(y2 + j); --#if defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 -+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 - CONVERTYUV420TORGB(4, d0, d1, q5, q6) - #else - convertYUV420.ToRGB(y1 + j, y2 + j, uv + j, dst1 + dj, dst2 + dj); -@@ -2683,7 +2683,7 @@ void yuv420sp2bgr(const Size2D &size, - internal::prefetch(uv + j); - internal::prefetch(y1 + j); - internal::prefetch(y2 + j); --#if defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 -+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 - CONVERTYUV420TORGB(3, d1, d0, q6, q5) - #else - convertYUV420.ToRGB(y1 + j, y2 + j, uv + j, dst1 + dj, dst2 + dj); -@@ -2729,7 +2729,7 @@ void yuv420sp2bgrx(const Size2D &size, - internal::prefetch(uv + j); - internal::prefetch(y1 + j); - internal::prefetch(y2 + j); --#if defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 -+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 - CONVERTYUV420TORGB(4, d1, d0, q6, q5) - #else - convertYUV420.ToRGB(y1 + j, y2 + j, uv + j, dst1 + dj, dst2 + dj); -@@ -2775,7 +2775,7 @@ void yuv420i2bgr(const Size2D &size, - internal::prefetch(uv + j); - internal::prefetch(y1 + j); - internal::prefetch(y2 + j); --#if defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 -+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 - CONVERTYUV420TORGB(3, d0, d1, q6, q5) - #else - convertYUV420.ToRGB(y1 + j, y2 + j, uv + j, dst1 + dj, dst2 + dj); -@@ -2821,7 +2821,7 @@ void yuv420i2bgrx(const Size2D &size, - internal::prefetch(uv + j); - internal::prefetch(y1 + j); - internal::prefetch(y2 + j); --#if defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 -+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 - CONVERTYUV420TORGB(4, d0, d1, q6, q5) - #else - convertYUV420.ToRGB(y1 + j, y2 + j, uv + j, dst1 + dj, dst2 + dj); -diff --git a/3rdparty/carotene/src/convert.cpp b/3rdparty/carotene/src/convert.cpp -index 403f16d86a..64b6db78ab 100644 ---- a/3rdparty/carotene/src/convert.cpp -+++ b/3rdparty/carotene/src/convert.cpp -@@ -101,7 +101,7 @@ CVT_FUNC(u8, s8, 16, - } - }) - --#if defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 -+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 - CVT_FUNC(u8, u16, 16, - register uint8x16_t zero0 asm ("q1") = vmovq_n_u8(0);, - { -@@ -135,7 +135,7 @@ CVT_FUNC(u8, u16, 16, - }) - #endif - --#if defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 -+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 - CVT_FUNC(u8, s32, 16, - register uint8x16_t zero0 asm ("q1") = vmovq_n_u8(0); - register uint8x16_t zero1 asm ("q2") = vmovq_n_u8(0); -@@ -173,7 +173,7 @@ CVT_FUNC(u8, s32, 16, - }) - #endif - --#if defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 6 -+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 6 - CVT_FUNC(u8, f32, 16, - , - { -@@ -248,7 +248,7 @@ CVT_FUNC(s8, u8, 16, - } - }) - --#if defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 -+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 - CVT_FUNC(s8, u16, 16, - register uint8x16_t zero0 asm ("q1") = vmovq_n_u8(0);, - { -@@ -284,7 +284,7 @@ CVT_FUNC(s8, u16, 16, - }) - #endif - --#if defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 6 -+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 6 - CVT_FUNC(s8, s16, 16, - , - { -@@ -323,7 +323,7 @@ CVT_FUNC(s8, s16, 16, - }) - #endif - --#if defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 -+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 - CVT_FUNC(s8, s32, 16, - , - { -@@ -377,7 +377,7 @@ CVT_FUNC(s8, s32, 16, - }) - #endif - --#if defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 6 -+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 6 - CVT_FUNC(s8, f32, 16, - , - { -@@ -440,7 +440,7 @@ CVT_FUNC(s8, f32, 16, - }) - #endif - --#if defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 6 -+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 6 - CVT_FUNC(u16, u8, 16, - , - { -@@ -479,7 +479,7 @@ CVT_FUNC(u16, u8, 16, - }) - #endif - --#if defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 6 -+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 6 - CVT_FUNC(u16, s8, 16, - register uint8x16_t v127 asm ("q4") = vmovq_n_u8(127);, - { -@@ -522,7 +522,7 @@ CVT_FUNC(u16, s8, 16, - }) - #endif - --#if defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 -+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 - CVT_FUNC(u16, s16, 8, - register uint16x8_t v32767 asm ("q4") = vmovq_n_u16(0x7FFF);, - { -@@ -555,7 +555,7 @@ CVT_FUNC(u16, s16, 8, - }) - #endif - --#if defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 -+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 - CVT_FUNC(u16, s32, 8, - register uint16x8_t zero0 asm ("q1") = vmovq_n_u16(0);, - { -@@ -589,7 +589,7 @@ CVT_FUNC(u16, s32, 8, - }) - #endif - --#if defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 6 -+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 6 - CVT_FUNC(u16, f32, 8, - , - { -@@ -633,7 +633,7 @@ CVT_FUNC(u16, f32, 8, - }) - #endif - --#if defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 6 -+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 6 - CVT_FUNC(s16, u8, 16, - , - { -@@ -672,7 +672,7 @@ CVT_FUNC(s16, u8, 16, - }) - #endif - --#if defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 6 -+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 6 - CVT_FUNC(s16, s8, 16, - , - { -@@ -711,7 +711,7 @@ CVT_FUNC(s16, s8, 16, - }) - #endif - --#if defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 -+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 - CVT_FUNC(s16, u16, 8, - register int16x8_t vZero asm ("q4") = vmovq_n_s16(0);, - { -@@ -747,7 +747,7 @@ CVT_FUNC(s16, u16, 8, - }) - #endif - --#if defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 6 -+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 6 - CVT_FUNC(s16, s32, 8, - , - { -@@ -786,7 +786,7 @@ CVT_FUNC(s16, s32, 8, - }) - #endif - --#if defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 6 -+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 6 - CVT_FUNC(s16, f32, 8, - , - { -@@ -829,7 +829,7 @@ CVT_FUNC(s16, f32, 8, - }) - #endif - --#if defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 6 -+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 6 - CVT_FUNC(s32, u8, 8, - , - { -@@ -870,7 +870,7 @@ CVT_FUNC(s32, u8, 8, - }) - #endif - --#if defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 6 -+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 6 - CVT_FUNC(s32, s8, 8, - , - { -@@ -911,7 +911,7 @@ CVT_FUNC(s32, s8, 8, - }) - #endif - --#if defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 6 -+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 6 - CVT_FUNC(s32, u16, 8, - , - { -@@ -950,7 +950,7 @@ CVT_FUNC(s32, u16, 8, - }) - #endif - --#if defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 6 -+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 6 - CVT_FUNC(s32, s16, 8, - , - { -@@ -989,7 +989,7 @@ CVT_FUNC(s32, s16, 8, - }) - #endif - --#if defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 6 -+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 6 - CVT_FUNC(s32, f32, 8, - , - { -@@ -1034,7 +1034,7 @@ CVT_FUNC(s32, f32, 8, - }) - #endif - --#if defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 6 -+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 6 - CVT_FUNC(f32, u8, 8, - register float32x4_t vmult asm ("q0") = vdupq_n_f32((float)(1 << 16)); - register uint32x4_t vmask asm ("q1") = vdupq_n_u32(1<<16);, -@@ -1101,7 +1101,7 @@ CVT_FUNC(f32, u8, 8, - }) - #endif - --#if defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 6 -+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 6 - CVT_FUNC(f32, s8, 8, - register float32x4_t vhalf asm ("q0") = vdupq_n_f32(0.5f);, - { -@@ -1153,7 +1153,7 @@ CVT_FUNC(f32, s8, 8, - }) - #endif - --#if defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 6 -+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 6 - CVT_FUNC(f32, u16, 8, - register float32x4_t vhalf asm ("q0") = vdupq_n_f32(0.5f);, - { -@@ -1212,7 +1212,7 @@ CVT_FUNC(f32, u16, 8, - }) - #endif - --#if defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 6 -+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 6 - CVT_FUNC(f32, s16, 8, - register float32x4_t vhalf asm ("q0") = vdupq_n_f32(0.5f);, - { -@@ -1271,7 +1271,7 @@ CVT_FUNC(f32, s16, 8, - }) - #endif - --#if defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 6 -+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 6 - CVT_FUNC(f32, s32, 8, - register float32x4_t vhalf asm ("q0") = vdupq_n_f32(0.5f);, - { -diff --git a/3rdparty/carotene/src/convert_scale.cpp b/3rdparty/carotene/src/convert_scale.cpp -index 0a14a8035c..ae41a985c8 100644 ---- a/3rdparty/carotene/src/convert_scale.cpp -+++ b/3rdparty/carotene/src/convert_scale.cpp -@@ -135,7 +135,7 @@ namespace CAROTENE_NS { - - #endif - --#if defined(__GNUC__) && defined(__arm__) -+#if !defined(__aarch64__) && defined(__GNUC__) && defined(__arm__) - CVTS_FUNC1(u8, 16, - register float32x4_t vscale asm ("q0") = vdupq_n_f32((f32)alpha); - register float32x4_t vshift asm ("q1") = vdupq_n_f32((f32)beta + 0.5f);, -@@ -220,7 +220,7 @@ CVTS_FUNC1(u8, 16, - }) - #endif - --#if defined(__GNUC__) && defined(__arm__) -+#if !defined(__aarch64__) && defined(__GNUC__) && defined(__arm__) - CVTS_FUNC(u8, s8, 16, - register float32x4_t vscale asm ("q0") = vdupq_n_f32((f32)alpha); - register float32x4_t vshift asm ("q1") = vdupq_n_f32((f32)beta + 0.5f);, -@@ -305,7 +305,7 @@ CVTS_FUNC(u8, s8, 16, - }) - #endif - --#if defined(__GNUC__) && defined(__arm__) -+#if !defined(__aarch64__) && defined(__GNUC__) && defined(__arm__) - CVTS_FUNC(u8, u16, 16, - register float32x4_t vscale asm ("q0") = vdupq_n_f32((f32)alpha); - register float32x4_t vshift asm ("q1") = vdupq_n_f32((f32)beta + 0.5f);, -@@ -389,7 +389,7 @@ CVTS_FUNC(u8, u16, 16, - }) - #endif - --#if defined(__GNUC__) && defined(__arm__) -+#if !defined(__aarch64__) && defined(__GNUC__) && defined(__arm__) - CVTS_FUNC(u8, s16, 16, - register float32x4_t vscale asm ("q0") = vdupq_n_f32((f32)alpha); - register float32x4_t vshift asm ("q1") = vdupq_n_f32((f32)beta + 0.5f);, -@@ -473,7 +473,7 @@ CVTS_FUNC(u8, s16, 16, - }) - #endif - --#if defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 -+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 - CVTS_FUNC(u8, s32, 16, - register float32x4_t vscale asm ("q0") = vdupq_n_f32((f32)alpha); - register float32x4_t vshift asm ("q1") = vdupq_n_f32((f32)beta + 0.5f);, -@@ -562,7 +562,7 @@ CVTS_FUNC(u8, s32, 16, - }) - #endif - --#if defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 -+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 - CVTS_FUNC(u8, f32, 16, - register float32x4_t vscale asm ("q0") = vdupq_n_f32((f32)alpha); - register float32x4_t vshift asm ("q1") = vdupq_n_f32((f32)beta);, -@@ -643,7 +643,7 @@ CVTS_FUNC(u8, f32, 16, - }) - #endif - --#if defined(__GNUC__) && defined(__arm__) -+#if !defined(__aarch64__) && defined(__GNUC__) && defined(__arm__) - CVTS_FUNC(s8, u8, 16, - register float32x4_t vscale asm ("q0") = vdupq_n_f32((f32)alpha); - register float32x4_t vshift asm ("q1") = vdupq_n_f32((f32)beta + 0.5f);, -@@ -728,7 +728,7 @@ CVTS_FUNC(s8, u8, 16, - }) - #endif - --#if defined(__GNUC__) && defined(__arm__) -+#if !defined(__aarch64__) && defined(__GNUC__) && defined(__arm__) - CVTS_FUNC1(s8, 16, - register float32x4_t vscale asm ("q0") = vdupq_n_f32((f32)alpha); - register float32x4_t vshift asm ("q1") = vdupq_n_f32((f32)beta + 0.5f);, -@@ -813,7 +813,7 @@ CVTS_FUNC1(s8, 16, - }) - #endif - --#if defined(__GNUC__) && defined(__arm__) -+#if !defined(__aarch64__) && defined(__GNUC__) && defined(__arm__) - CVTS_FUNC(s8, u16, 16, - register float32x4_t vscale asm ("q0") = vdupq_n_f32((f32)alpha); - register float32x4_t vshift asm ("q1") = vdupq_n_f32((f32)beta + 0.5f);, -@@ -899,7 +899,7 @@ CVTS_FUNC(s8, u16, 16, - }) - #endif - --#if defined(__GNUC__) && defined(__arm__) -+#if !defined(__aarch64__) && defined(__GNUC__) && defined(__arm__) - CVTS_FUNC(s8, s16, 16, - register float32x4_t vscale asm ("q0") = vdupq_n_f32((f32)alpha); - register float32x4_t vshift asm ("q1") = vdupq_n_f32((f32)beta + 0.5f);, -@@ -985,7 +985,7 @@ CVTS_FUNC(s8, s16, 16, - }) - #endif - --#if defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 -+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 - CVTS_FUNC(s8, s32, 16, - register float32x4_t vscale asm ("q0") = vdupq_n_f32((f32)alpha); - register float32x4_t vshift asm ("q1") = vdupq_n_f32((f32)beta + 0.5f);, -@@ -1074,7 +1074,7 @@ CVTS_FUNC(s8, s32, 16, - }) - #endif - --#if defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 -+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 - CVTS_FUNC(s8, f32, 16, - register float32x4_t vscale asm ("q0") = vdupq_n_f32((f32)alpha); - register float32x4_t vshift asm ("q1") = vdupq_n_f32((f32)beta);, -@@ -1155,7 +1155,7 @@ CVTS_FUNC(s8, f32, 16, - }) - #endif - --#if defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 -+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 - CVTS_FUNC(u16, u8, 16, - register float32x4_t vscale asm ("q0") = vdupq_n_f32((f32)alpha); - register float32x4_t vshift asm ("q1") = vdupq_n_f32((f32)beta + 0.5f);, -@@ -1214,7 +1214,7 @@ CVTS_FUNC(u16, u8, 16, - }) - #endif - --#if defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 -+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 - CVTS_FUNC(u16, s8, 16, - register float32x4_t vscale asm ("q0") = vdupq_n_f32((f32)alpha); - register float32x4_t vshift asm ("q1") = vdupq_n_f32((f32)beta + 0.5f);, -@@ -1273,7 +1273,7 @@ CVTS_FUNC(u16, s8, 16, - }) - #endif - --#if defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 -+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 - CVTS_FUNC1(u16, 16, - register float32x4_t vscale asm ("q0") = vdupq_n_f32((f32)alpha); - register float32x4_t vshift asm ("q1") = vdupq_n_f32((f32)beta + 0.5f);, -@@ -1330,7 +1330,7 @@ CVTS_FUNC1(u16, 16, - }) - #endif - --#if defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 -+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 - CVTS_FUNC(u16, s16, 8, - register float32x4_t vscale asm ("q0") = vdupq_n_f32((f32)alpha); - register float32x4_t vshift asm ("q1") = vdupq_n_f32((f32)beta + 0.5f);, -@@ -1387,7 +1387,7 @@ CVTS_FUNC(u16, s16, 8, - }) - #endif - --#if defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 -+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 - CVTS_FUNC(u16, s32, 8, - register float32x4_t vscale asm ("q0") = vdupq_n_f32((f32)alpha); - register float32x4_t vshift asm ("q1") = vdupq_n_f32((f32)beta + 0.5f);, -@@ -1443,7 +1443,7 @@ CVTS_FUNC(u16, s32, 8, - }) - #endif - --#if defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 -+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 - CVTS_FUNC(u16, f32, 8, - register float32x4_t vscale asm ("q0") = vdupq_n_f32((f32)alpha); - register float32x4_t vshift asm ("q1") = vdupq_n_f32((f32)beta);, -@@ -1495,7 +1495,7 @@ CVTS_FUNC(u16, f32, 8, - }) - #endif - --#if defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 -+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 - CVTS_FUNC(s16, u8, 16, - register float32x4_t vscale asm ("q0") = vdupq_n_f32((f32)alpha); - register float32x4_t vshift asm ("q1") = vdupq_n_f32((f32)beta + 0.5f);, -@@ -1554,7 +1554,7 @@ CVTS_FUNC(s16, u8, 16, - }) - #endif - --#if defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 -+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 - CVTS_FUNC(s16, s8, 16, - register float32x4_t vscale asm ("q0") = vdupq_n_f32((f32)alpha); - register float32x4_t vshift asm ("q1") = vdupq_n_f32((f32)beta + 0.5f);, -@@ -1613,7 +1613,7 @@ CVTS_FUNC(s16, s8, 16, - }) - #endif - --#if defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 -+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 - CVTS_FUNC(s16, u16, 8, - register float32x4_t vscale asm ("q0") = vdupq_n_f32((f32)alpha); - register float32x4_t vshift asm ("q1") = vdupq_n_f32((f32)beta + 0.5f);, -@@ -1670,7 +1670,7 @@ CVTS_FUNC(s16, u16, 8, - }) - #endif - --#if defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 -+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 - CVTS_FUNC1(s16, 16, - register float32x4_t vscale asm ("q0") = vdupq_n_f32((f32)alpha); - register float32x4_t vshift asm ("q1") = vdupq_n_f32((f32)beta + 0.5f);, -@@ -1727,7 +1727,7 @@ CVTS_FUNC1(s16, 16, - }) - #endif - --#if defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 -+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 - CVTS_FUNC(s16, s32, 8, - register float32x4_t vscale asm ("q0") = vdupq_n_f32((f32)alpha); - register float32x4_t vshift asm ("q1") = vdupq_n_f32((f32)beta + 0.5f);, -@@ -1783,7 +1783,7 @@ CVTS_FUNC(s16, s32, 8, - }) - #endif - --#if defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 -+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 - CVTS_FUNC(s16, f32, 8, - register float32x4_t vscale asm ("q0") = vdupq_n_f32((f32)alpha); - register float32x4_t vshift asm ("q1") = vdupq_n_f32((f32)beta);, -@@ -1835,7 +1835,7 @@ CVTS_FUNC(s16, f32, 8, - }) - #endif - --#if defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 -+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 - CVTS_FUNC(s32, u8, 8, - register float32x4_t vscale asm ("q0") = vdupq_n_f32((f32)alpha); - register float32x4_t vshift asm ("q1") = vdupq_n_f32((f32)beta + 0.5f);, -@@ -1893,7 +1893,7 @@ CVTS_FUNC(s32, u8, 8, - }) - #endif - --#if defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 -+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 - CVTS_FUNC(s32, s8, 8, - register float32x4_t vscale asm ("q0") = vdupq_n_f32((f32)alpha); - register float32x4_t vshift asm ("q1") = vdupq_n_f32((f32)beta + 0.5f);, -@@ -1951,7 +1951,7 @@ CVTS_FUNC(s32, s8, 8, - }) - #endif - --#if defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 -+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 - CVTS_FUNC(s32, u16, 8, - register float32x4_t vscale asm ("q0") = vdupq_n_f32((f32)alpha); - register float32x4_t vshift asm ("q1") = vdupq_n_f32((f32)beta + 0.5f);, -@@ -2007,7 +2007,7 @@ CVTS_FUNC(s32, u16, 8, - }) - #endif - --#if defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 -+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 - CVTS_FUNC(s32, s16, 8, - register float32x4_t vscale asm ("q0") = vdupq_n_f32((f32)alpha); - register float32x4_t vshift asm ("q1") = vdupq_n_f32((f32)beta + 0.5f);, -@@ -2063,7 +2063,7 @@ CVTS_FUNC(s32, s16, 8, - }) - #endif - --#if defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 -+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 - CVTS_FUNC1(s32, 8, - register float32x4_t vscale asm ("q0") = vdupq_n_f32((f32)alpha); - register float32x4_t vshift asm ("q1") = vdupq_n_f32((f32)beta + 0.5f);, -@@ -2118,7 +2118,7 @@ CVTS_FUNC1(s32, 8, - }) - #endif - --#if defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 -+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 - CVTS_FUNC(s32, f32, 8, - register float32x4_t vscale asm ("q0") = vdupq_n_f32((f32)alpha); - register float32x4_t vshift asm ("q1") = vdupq_n_f32((f32)beta);, -@@ -2169,7 +2169,7 @@ CVTS_FUNC(s32, f32, 8, - }) - #endif - --#if defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 -+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 - CVTS_FUNC(f32, u8, 8, - register float32x4_t vscale asm ("q0") = vdupq_n_f32((f32)((1 << 16)*alpha)); - register float32x4_t vshift asm ("q1") = vdupq_n_f32((f32)((1 << 16)*beta)); -@@ -2239,7 +2239,7 @@ CVTS_FUNC(f32, u8, 8, - }) - #endif - --#if defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 -+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 - CVTS_FUNC(f32, s8, 8, - register float32x4_t vscale asm ("q0") = vdupq_n_f32((f32)alpha); - register float32x4_t vshift asm ("q1") = vdupq_n_f32((f32)beta + 0.5f);, -@@ -2293,7 +2293,7 @@ CVTS_FUNC(f32, s8, 8, - }) - #endif - --#if defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 -+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 - CVTS_FUNC(f32, u16, 8, - register float32x4_t vscale asm ("q0") = vdupq_n_f32((f32)alpha); - register float32x4_t vshift asm ("q1") = vdupq_n_f32((f32)beta + 0.5f);, -@@ -2345,7 +2345,7 @@ CVTS_FUNC(f32, u16, 8, - }) - #endif - --#if defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 -+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 - CVTS_FUNC(f32, s16, 8, - register float32x4_t vscale asm ("q0") = vdupq_n_f32((f32)alpha); - register float32x4_t vshift asm ("q1") = vdupq_n_f32((f32)beta + 0.5f);, -@@ -2397,7 +2397,7 @@ CVTS_FUNC(f32, s16, 8, - }) - #endif - --#if defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 -+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 - CVTS_FUNC(f32, s32, 8, - register float32x4_t vscale asm ("q0") = vdupq_n_f32((f32)alpha); - register float32x4_t vshift asm ("q1") = vdupq_n_f32((f32)beta + 0.5f);, -@@ -2448,7 +2448,7 @@ CVTS_FUNC(f32, s32, 8, - }) - #endif - --#if defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 -+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 - CVTS_FUNC1(f32, 8, - register float32x4_t vscale asm ("q0") = vdupq_n_f32((f32)alpha); - register float32x4_t vshift asm ("q1") = vdupq_n_f32((f32)beta);, -diff --git a/3rdparty/carotene/src/gaussian_blur.cpp b/3rdparty/carotene/src/gaussian_blur.cpp -index 1b5399436f..f7b5f18d79 100644 ---- a/3rdparty/carotene/src/gaussian_blur.cpp -+++ b/3rdparty/carotene/src/gaussian_blur.cpp -@@ -327,7 +327,7 @@ void gaussianBlur5x5(const Size2D &size, s32 cn, - u16* lidx1 = lane + x - 1*2; - u16* lidx3 = lane + x + 1*2; - u16* lidx4 = lane + x + 2*2; --#if defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 -+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 - __asm__ __volatile__ ( - "vld2.16 {d0, d2}, [%[in0]]! \n\t" - "vld2.16 {d1, d3}, [%[in0]] \n\t" -@@ -398,7 +398,7 @@ void gaussianBlur5x5(const Size2D &size, s32 cn, - u16* lidx1 = lane + x - 1*3; - u16* lidx3 = lane + x + 1*3; - u16* lidx4 = lane + x + 2*3; --#if defined(__GNUC__) && defined(__arm__) -+#if !defined(__aarch64__) && defined(__GNUC__) && defined(__arm__) - __asm__ __volatile__ ( - "vld3.16 {d0, d2, d4}, [%[in0]]! \n\t" - "vld3.16 {d1, d3, d5}, [%[in0]] \n\t" -@@ -482,7 +482,7 @@ void gaussianBlur5x5(const Size2D &size, s32 cn, - u16* lidx1 = lane + x - 1*4; - u16* lidx3 = lane + x + 1*4; - u16* lidx4 = lane + x + 2*4; --#if defined(__GNUC__) && defined(__arm__) -+#if !defined(__aarch64__) && defined(__GNUC__) && defined(__arm__) - __asm__ __volatile__ ( - "vld4.16 {d0, d2, d4, d6}, [%[in0]]! \n\t" - "vld4.16 {d1, d3, d5, d7}, [%[in0]] \n\t" -diff --git a/3rdparty/carotene/src/pyramid.cpp b/3rdparty/carotene/src/pyramid.cpp -index 8ef1268933..232ccf3efd 100644 ---- a/3rdparty/carotene/src/pyramid.cpp -+++ b/3rdparty/carotene/src/pyramid.cpp -@@ -331,7 +331,7 @@ void gaussianPyramidDown(const Size2D &srcSize, - for (; x < roiw8; x += 8) - { - internal::prefetch(lane + 2 * x); --#if defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 -+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 - __asm__ ( - "vld2.16 {d0-d3}, [%[in0]] \n\t" - "vld2.16 {d4-d7}, [%[in4]] \n\t" -@@ -538,7 +538,7 @@ void gaussianPyramidDown(const Size2D &srcSize, - for (; x < roiw4; x += 4) - { - internal::prefetch(lane + 2 * x); --#if defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 -+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 - __asm__ ( - "vld2.32 {d0-d3}, [%[in0]] \n\t" - "vld2.32 {d4-d7}, [%[in4]] \n\t" -@@ -672,7 +672,7 @@ void gaussianPyramidDown(const Size2D &srcSize, - std::vector _buf(cn*(srcSize.width + 4) + 32/sizeof(f32)); - f32* lane = internal::alignPtr(&_buf[2*cn], 32); - --#if defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 -+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 - register float32x4_t vc6d4f32 asm ("q11") = vmovq_n_f32(1.5f); // 6/4 - register float32x4_t vc1d4f32 asm ("q12") = vmovq_n_f32(0.25f); // 1/4 - -@@ -739,7 +739,7 @@ void gaussianPyramidDown(const Size2D &srcSize, - for (; x < roiw4; x += 4) - { - internal::prefetch(lane + 2 * x); --#if defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 -+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 - __asm__ __volatile__ ( - "vld2.32 {d0-d3}, [%[in0]] \n\t" - "vld2.32 {d8-d11}, [%[in4]] \n\t" -@@ -932,7 +932,7 @@ pyrUp8uHorizontalConvolution: - for (; x < lim; x += 8) - { - internal::prefetch(lane + x); --#if defined(__GNUC__) && defined(__arm__) -+#if !defined(__aarch64__) && defined(__GNUC__) && defined(__arm__) - __asm__ ( - "vld1.16 {d0-d1}, [%[in0]] /*q0 = v0*/ \n\t" - "vld1.16 {d2-d3}, [%[in2]] /*q1 = v2*/ \n\t" -@@ -973,7 +973,7 @@ pyrUp8uHorizontalConvolution: - for (; x < lim; x += 24) - { - internal::prefetch(lane + x); --#if defined(__GNUC__) && defined(__arm__) -+#if !defined(__aarch64__) && defined(__GNUC__) && defined(__arm__) - __asm__ ( - "vmov.u16 q9, #6 \n\t" - "vld3.16 {d0, d2, d4}, [%[in0]] /*v0*/ \n\t" -@@ -1064,7 +1064,7 @@ pyrUp8uHorizontalConvolution: - for (; x < lim; x += 8) - { - internal::prefetch(lane + x); --#if defined(__GNUC__) && defined(__arm__) -+#if !defined(__aarch64__) && defined(__GNUC__) && defined(__arm__) - __asm__ ( - "vld1.16 {d0-d1}, [%[in0]] /*q0 = v0*/ \n\t" - "vld1.16 {d2-d3}, [%[in2]] /*q1 = v2*/ \n\t" -@@ -1210,7 +1210,7 @@ pyrUp16sHorizontalConvolution: - for (; x < lim; x += 4) - { - internal::prefetch(lane + x); --#if defined(__GNUC__) && defined(__arm__) -+#if !defined(__aarch64__) && defined(__GNUC__) && defined(__arm__) - __asm__ ( - "vld1.32 {d0-d1}, [%[in0]] /*q0 = v0*/ \n\t" - "vld1.32 {d2-d3}, [%[in2]] /*q1 = v2*/ \n\t" -@@ -1251,7 +1251,7 @@ pyrUp16sHorizontalConvolution: - for (; x < lim; x += 12) - { - internal::prefetch(lane + x + 3); --#if defined(__GNUC__) && defined(__arm__) -+#if !defined(__aarch64__) && defined(__GNUC__) && defined(__arm__) - __asm__ ( - "vmov.s32 q9, #6 \n\t" - "vld3.32 {d0, d2, d4}, [%[in0]] /*v0*/ \n\t" -@@ -1343,7 +1343,7 @@ pyrUp16sHorizontalConvolution: - for (; x < lim; x += 4) - { - internal::prefetch(lane + x); --#if defined(__GNUC__) && defined(__arm__) -+#if !defined(__aarch64__) && defined(__GNUC__) && defined(__arm__) - __asm__ ( - "vld1.32 {d0-d1}, [%[in0]] /*q0 = v0*/ \n\t" - "vld1.32 {d2-d3}, [%[in2]] /*q1 = v2*/ \n\t" -diff --git a/3rdparty/carotene/src/scharr.cpp b/3rdparty/carotene/src/scharr.cpp -index 5695804fe4..8d3b6328b1 100644 ---- a/3rdparty/carotene/src/scharr.cpp -+++ b/3rdparty/carotene/src/scharr.cpp -@@ -109,7 +109,7 @@ void ScharrDeriv(const Size2D &size, s32 cn, - internal::prefetch(srow0 + x); - internal::prefetch(srow1 + x); - internal::prefetch(srow2 + x); --#if defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 -+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 - __asm__ ( - "vld1.8 {d0}, [%[src0]] \n\t" - "vld1.8 {d2}, [%[src2]] \n\t" -@@ -161,7 +161,7 @@ void ScharrDeriv(const Size2D &size, s32 cn, - x = 0; - for( ; x < roiw8; x += 8 ) - { --#if defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 6 -+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 6 - __asm__ ( - "vld1.16 {d4-d5}, [%[s2ptr]] \n\t" - "vld1.16 {d8-d9}, [%[s4ptr]] \n\t" --- -2.14.1 - diff --git a/meta-oe/recipes-support/opencv/opencv/0002-Do-not-enable-asm-with-clang.patch b/meta-oe/recipes-support/opencv/opencv/0002-Do-not-enable-asm-with-clang.patch deleted file mode 100644 index 22e868a031..0000000000 --- a/meta-oe/recipes-support/opencv/opencv/0002-Do-not-enable-asm-with-clang.patch +++ /dev/null @@ -1,993 +0,0 @@ -From 333f60165b6737588eb975a5e4393d847011a1cd Mon Sep 17 00:00:00 2001 -From: Khem Raj -Date: Tue, 19 Sep 2017 18:07:35 -0700 -Subject: [PATCH 2/2] Do not enable asm with clang - -clang pretends to be gcc 4.2.0 which means we will -use inline asm for no reason, instead of builtins -on clang when possible. - -Signed-off-by: Khem Raj ---- -Upstream-Status: Submitted - 3rdparty/carotene/src/channel_extract.cpp | 4 +- - 3rdparty/carotene/src/channels_combine.cpp | 2 +- - 3rdparty/carotene/src/colorconvert.cpp | 78 +++++++++++++++--------------- - 3rdparty/carotene/src/convert.cpp | 54 ++++++++++----------- - 3rdparty/carotene/src/convert_scale.cpp | 56 ++++++++++----------- - 3rdparty/carotene/src/gaussian_blur.cpp | 2 +- - 3rdparty/carotene/src/pyramid.cpp | 8 +-- - 3rdparty/carotene/src/scharr.cpp | 4 +- - 8 files changed, 104 insertions(+), 104 deletions(-) - -diff --git a/3rdparty/carotene/src/channel_extract.cpp b/3rdparty/carotene/src/channel_extract.cpp -index 8238a3ece8..ff4fb3770c 100644 ---- a/3rdparty/carotene/src/channel_extract.cpp -+++ b/3rdparty/carotene/src/channel_extract.cpp -@@ -231,7 +231,7 @@ void extract4(const Size2D &size, - srcStride == dst2Stride && \ - srcStride == dst3Stride && - --#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 -+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 && !defined(__clang__) - - #define SPLIT_ASM2(sgn, bits) __asm__ ( \ - "vld2." #bits " {d0, d2}, [%[in0]] \n\t" \ -@@ -351,7 +351,7 @@ void extract4(const Size2D &size, - } \ - } - --#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 -+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 && !defined(__clang__) - - #define ALPHA_QUAD(sgn, bits) { \ - internal::prefetch(src + sj); \ -diff --git a/3rdparty/carotene/src/channels_combine.cpp b/3rdparty/carotene/src/channels_combine.cpp -index fc98fb9181..5d9251d51c 100644 ---- a/3rdparty/carotene/src/channels_combine.cpp -+++ b/3rdparty/carotene/src/channels_combine.cpp -@@ -77,7 +77,7 @@ namespace CAROTENE_NS { - dstStride == src2Stride && \ - dstStride == src3Stride && - --#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 -+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 && !defined(__clang__) - - #define MERGE_ASM2(sgn, bits) __asm__ ( \ - "vld1." #bits " {d0-d1}, [%[in0]] \n\t" \ -diff --git a/3rdparty/carotene/src/colorconvert.cpp b/3rdparty/carotene/src/colorconvert.cpp -index 26ae54b15c..d3a40fe64e 100644 ---- a/3rdparty/carotene/src/colorconvert.cpp -+++ b/3rdparty/carotene/src/colorconvert.cpp -@@ -97,7 +97,7 @@ void rgb2gray(const Size2D &size, COLOR_SPACE color_space, - const u32 G2Y = color_space == COLOR_SPACE_BT601 ? G2Y_BT601 : G2Y_BT709; - const u32 B2Y = color_space == COLOR_SPACE_BT601 ? B2Y_BT601 : B2Y_BT709; - --#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 -+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 && !defined(__clang__) - register int16x4_t v_r2y asm ("d31") = vmov_n_s16(R2Y); - register int16x4_t v_g2y asm ("d30") = vmov_n_s16(G2Y); - register int16x4_t v_b2y asm ("d29") = vmov_n_s16(B2Y); -@@ -116,7 +116,7 @@ void rgb2gray(const Size2D &size, COLOR_SPACE color_space, - u8 * dst = internal::getRowPtr(dstBase, dstStride, i); - size_t sj = 0u, dj = 0u; - --#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 -+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 && !defined(__clang__) - for (; dj < roiw8; sj += 24, dj += 8) - { - internal::prefetch(src + sj); -@@ -198,7 +198,7 @@ void rgbx2gray(const Size2D &size, COLOR_SPACE color_space, - const u32 G2Y = color_space == COLOR_SPACE_BT601 ? G2Y_BT601 : G2Y_BT709; - const u32 B2Y = color_space == COLOR_SPACE_BT601 ? B2Y_BT601 : B2Y_BT709; - --#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 -+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 && !defined(__clang__) - register int16x4_t v_r2y asm ("d31") = vmov_n_s16(R2Y); - register int16x4_t v_g2y asm ("d30") = vmov_n_s16(G2Y); - register int16x4_t v_b2y asm ("d29") = vmov_n_s16(B2Y); -@@ -217,7 +217,7 @@ void rgbx2gray(const Size2D &size, COLOR_SPACE color_space, - u8 * dst = internal::getRowPtr(dstBase, dstStride, i); - size_t sj = 0u, dj = 0u; - --#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 -+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 && !defined(__clang__) - for (; dj < roiw8; sj += 32, dj += 8) - { - internal::prefetch(src + sj); -@@ -300,7 +300,7 @@ void bgr2gray(const Size2D &size, COLOR_SPACE color_space, - const u32 G2Y = color_space == COLOR_SPACE_BT601 ? G2Y_BT601 : G2Y_BT709; - const u32 B2Y = color_space == COLOR_SPACE_BT601 ? B2Y_BT601 : B2Y_BT709; - --#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 -+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 && !defined(__clang__) - register int16x4_t v_r2y asm ("d31") = vmov_n_s16(R2Y); - register int16x4_t v_g2y asm ("d30") = vmov_n_s16(G2Y); - register int16x4_t v_b2y asm ("d29") = vmov_n_s16(B2Y); -@@ -319,7 +319,7 @@ void bgr2gray(const Size2D &size, COLOR_SPACE color_space, - u8 * dst = internal::getRowPtr(dstBase, dstStride, i); - size_t sj = 0u, dj = 0u; - --#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 -+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 && !defined(__clang__) - for (; dj < roiw8; sj += 24, dj += 8) - { - internal::prefetch(src + sj); -@@ -402,7 +402,7 @@ void bgrx2gray(const Size2D &size, COLOR_SPACE color_space, - const u32 G2Y = color_space == COLOR_SPACE_BT601 ? G2Y_BT601 : G2Y_BT709; - const u32 B2Y = color_space == COLOR_SPACE_BT601 ? B2Y_BT601 : B2Y_BT709; - --#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 -+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 && !defined(__clang__) - register int16x4_t v_r2y asm ("d31") = vmov_n_s16(R2Y); - register int16x4_t v_g2y asm ("d30") = vmov_n_s16(G2Y); - register int16x4_t v_b2y asm ("d29") = vmov_n_s16(B2Y); -@@ -421,7 +421,7 @@ void bgrx2gray(const Size2D &size, COLOR_SPACE color_space, - u8 * dst = internal::getRowPtr(dstBase, dstStride, i); - size_t sj = 0u, dj = 0u; - --#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 -+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 && !defined(__clang__) - for (; dj < roiw8; sj += 32, dj += 8) - { - internal::prefetch(src + sj); -@@ -512,7 +512,7 @@ void gray2rgb(const Size2D &size, - for (; sj < roiw16; sj += 16, dj += 48) - { - internal::prefetch(src + sj); --#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 -+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 && !defined(__clang__) - __asm__ ( - "vld1.8 {d0-d1}, [%[in0]] \n\t" - "vmov.8 q1, q0 \n\t" -@@ -538,7 +538,7 @@ void gray2rgb(const Size2D &size, - - if (sj < roiw8) - { --#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 -+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 && !defined(__clang__) - __asm__ ( - "vld1.8 {d0}, [%[in]] \n\t" - "vmov.8 d1, d0 \n\t" -@@ -584,7 +584,7 @@ void gray2rgbx(const Size2D &size, - size_t roiw16 = size.width >= 15 ? size.width - 15 : 0; - size_t roiw8 = size.width >= 7 ? size.width - 7 : 0; - --#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 -+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 && !defined(__clang__) - register uint8x16_t vc255 asm ("q4") = vmovq_n_u8(255); - #else - uint8x16x4_t vRgba; -@@ -602,7 +602,7 @@ void gray2rgbx(const Size2D &size, - for (; sj < roiw16; sj += 16, dj += 64) - { - internal::prefetch(src + sj); --#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 -+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 && !defined(__clang__) - __asm__ ( - "vld1.8 {d0-d1}, [%[in0]] \n\t" - "vmov.8 q1, q0 \n\t" -@@ -628,7 +628,7 @@ void gray2rgbx(const Size2D &size, - - if (sj < roiw8) - { --#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 -+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 && !defined(__clang__) - __asm__ ( - "vld1.8 {d5}, [%[in]] \n\t" - "vmov.8 d6, d5 \n\t" -@@ -1409,7 +1409,7 @@ inline void convertToHSV(const s32 r, const s32 g, const s32 b, - "d24","d25","d26","d27","d28","d29","d30","d31" \ - ); - --#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 -+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 && !defined(__clang__) - - #define YCRCB_CONSTS \ - register int16x4_t vcYR asm ("d31") = vmov_n_s16(4899); \ -@@ -1555,7 +1555,7 @@ inline uint8x8x3_t convertToYCrCb( const int16x8_t& vR, const int16x8_t& vG, con - #define COEFF_G ( 8663) - #define COEFF_B (-17705) - --#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 -+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 && !defined(__clang__) - #define YUV420ALPHA3_CONST - #define YUV420ALPHA4_CONST register uint8x16_t c255 asm ("q13") = vmovq_n_u8(255); - #define YUV420ALPHA3_CONVERT -@@ -1852,7 +1852,7 @@ void rgb2hsv(const Size2D &size, - #ifdef CAROTENE_NEON - size_t roiw8 = size.width >= 7 ? size.width - 7 : 0; - const s32 hsv_shift = 12; --#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 -+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 && !defined(__clang__) - register const f32 vsdiv_table = f32(255 << hsv_shift); - register f32 vhdiv_table = f32(hrange << hsv_shift); - register const s32 vhrange = hrange; -@@ -1871,7 +1871,7 @@ void rgb2hsv(const Size2D &size, - for (; j < roiw8; sj += 24, dj += 24, j += 8) - { - internal::prefetch(src + sj); --#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 -+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 && !defined(__clang__) - CONVERT_TO_HSV_ASM(vld3.8 {d0-d2}, d0, d2) - #else - uint8x8x3_t vRgb = vld3_u8(src + sj); -@@ -1904,7 +1904,7 @@ void rgbx2hsv(const Size2D &size, - #ifdef CAROTENE_NEON - size_t roiw8 = size.width >= 7 ? size.width - 7 : 0; - const s32 hsv_shift = 12; --#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 -+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 && !defined(__clang__) - register const f32 vsdiv_table = f32(255 << hsv_shift); - register f32 vhdiv_table = f32(hrange << hsv_shift); - register const s32 vhrange = hrange; -@@ -1923,7 +1923,7 @@ void rgbx2hsv(const Size2D &size, - for (; j < roiw8; sj += 32, dj += 24, j += 8) - { - internal::prefetch(src + sj); --#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 -+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 && !defined(__clang__) - CONVERT_TO_HSV_ASM(vld4.8 {d0-d3}, d0, d2) - #else - uint8x8x4_t vRgb = vld4_u8(src + sj); -@@ -1956,7 +1956,7 @@ void bgr2hsv(const Size2D &size, - #ifdef CAROTENE_NEON - size_t roiw8 = size.width >= 7 ? size.width - 7 : 0; - const s32 hsv_shift = 12; --#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 -+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 && !defined(__clang__) - register const f32 vsdiv_table = f32(255 << hsv_shift); - register f32 vhdiv_table = f32(hrange << hsv_shift); - register const s32 vhrange = hrange; -@@ -1975,7 +1975,7 @@ void bgr2hsv(const Size2D &size, - for (; j < roiw8; sj += 24, dj += 24, j += 8) - { - internal::prefetch(src + sj); --#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 -+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 && !defined(__clang__) - CONVERT_TO_HSV_ASM(vld3.8 {d0-d2}, d2, d0) - #else - uint8x8x3_t vRgb = vld3_u8(src + sj); -@@ -2008,7 +2008,7 @@ void bgrx2hsv(const Size2D &size, - #ifdef CAROTENE_NEON - size_t roiw8 = size.width >= 7 ? size.width - 7 : 0; - const s32 hsv_shift = 12; --#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 -+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 && !defined(__clang__) - register const f32 vsdiv_table = f32(255 << hsv_shift); - register f32 vhdiv_table = f32(hrange << hsv_shift); - register const s32 vhrange = hrange; -@@ -2027,7 +2027,7 @@ void bgrx2hsv(const Size2D &size, - for (; j < roiw8; sj += 32, dj += 24, j += 8) - { - internal::prefetch(src + sj); --#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 -+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 && !defined(__clang__) - CONVERT_TO_HSV_ASM(vld4.8 {d0-d3}, d2, d0) - #else - uint8x8x4_t vRgb = vld4_u8(src + sj); -@@ -2068,7 +2068,7 @@ void rgbx2bgr565(const Size2D &size, - for (; j < roiw16; sj += 64, dj += 32, j += 16) - { - internal::prefetch(src + sj); --#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 -+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 && !defined(__clang__) - __asm__ ( - "vld4.8 {d2, d4, d6, d8}, [%[in0]] @ q0 q1 q2 q3 q4 \n\t" - "vld4.8 {d3, d5, d7, d9}, [%[in1]] @ xxxxxxxx rrrrRRRR ggggGGGG bbbbBBBB xxxxxxxx \n\t" -@@ -2122,7 +2122,7 @@ void rgb2bgr565(const Size2D &size, - for (; j < roiw16; sj += 48, dj += 32, j += 16) - { - internal::prefetch(src + sj); --#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 -+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 && !defined(__clang__) - __asm__ ( - "vld3.8 {d2, d4, d6}, [%[in0]] @ q0 q1 q2 q3 q4 \n\t" - "vld3.8 {d3, d5, d7}, [%[in1]] @ xxxxxxxx rrrrRRRR ggggGGGG bbbbBBBB xxxxxxxx \n\t" -@@ -2176,7 +2176,7 @@ void rgbx2rgb565(const Size2D &size, - for (; j < roiw16; sj += 64, dj += 32, j += 16) - { - internal::prefetch(src + sj); --#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 -+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 && !defined(__clang__) - __asm__ ( - "vld4.8 {d0, d2, d4, d6}, [%[in0]] @ q0 q1 q2 q3 \n\t" - "vld4.8 {d1, d3, d5, d7}, [%[in1]] @ rrrrRRRR ggggGGGG bbbbBBBB aaaaAAAA \n\t" -@@ -2230,7 +2230,7 @@ void rgb2rgb565(const Size2D &size, - for (; j < roiw16; sj += 48, dj += 32, j += 16) - { - internal::prefetch(src + sj); --#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 -+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 && !defined(__clang__) - __asm__ ( - "vld3.8 {d0, d2, d4}, [%[in0]] @ q0 q1 q2 q3 \n\t" - "vld3.8 {d1, d3, d5}, [%[in1]] @ rrrrRRRR ggggGGGG bbbbBBBB xxxxxxxx \n\t" -@@ -2285,7 +2285,7 @@ void rgb2ycrcb(const Size2D &size, - for (; j < roiw8; sj += 24, dj += 24, j += 8) - { - internal::prefetch(src + sj); --#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 -+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 && !defined(__clang__) - CONVERTTOYCRCB(vld3.8 {d0-d2}, d0, d1, d2) - #else - uint8x8x3_t vRgb = vld3_u8(src + sj); -@@ -2329,7 +2329,7 @@ void rgbx2ycrcb(const Size2D &size, - for (; j < roiw8; sj += 32, dj += 24, j += 8) - { - internal::prefetch(src + sj); --#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 -+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 && !defined(__clang__) - CONVERTTOYCRCB(vld4.8 {d0-d3}, d0, d1, d2) - #else - uint8x8x4_t vRgba = vld4_u8(src + sj); -@@ -2373,7 +2373,7 @@ void bgr2ycrcb(const Size2D &size, - for (; j < roiw8; sj += 24, dj += 24, j += 8) - { - internal::prefetch(src + sj); --#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 -+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 && !defined(__clang__) - CONVERTTOYCRCB(vld3.8 {d0-d2}, d2, d1, d0) - #else - uint8x8x3_t vBgr = vld3_u8(src + sj); -@@ -2417,7 +2417,7 @@ void bgrx2ycrcb(const Size2D &size, - for (; j < roiw8; sj += 32, dj += 24, j += 8) - { - internal::prefetch(src + sj); --#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 -+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 && !defined(__clang__) - CONVERTTOYCRCB(vld4.8 {d0-d3}, d2, d1, d0) - #else - uint8x8x4_t vBgra = vld4_u8(src + sj); -@@ -2499,7 +2499,7 @@ void yuv420sp2rgb(const Size2D &size, - internal::prefetch(uv + j); - internal::prefetch(y1 + j); - internal::prefetch(y2 + j); --#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 -+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 && !defined(__clang__) - CONVERTYUV420TORGB(3, d1, d0, q5, q6) - #else - convertYUV420.ToRGB(y1 + j, y2 + j, uv + j, dst1 + dj, dst2 + dj); -@@ -2545,7 +2545,7 @@ void yuv420sp2rgbx(const Size2D &size, - internal::prefetch(uv + j); - internal::prefetch(y1 + j); - internal::prefetch(y2 + j); --#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 -+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 && !defined(__clang__) - CONVERTYUV420TORGB(4, d1, d0, q5, q6) - #else - convertYUV420.ToRGB(y1 + j, y2 + j, uv + j, dst1 + dj, dst2 + dj); -@@ -2591,7 +2591,7 @@ void yuv420i2rgb(const Size2D &size, - internal::prefetch(uv + j); - internal::prefetch(y1 + j); - internal::prefetch(y2 + j); --#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 -+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 && !defined(__clang__) - CONVERTYUV420TORGB(3, d0, d1, q5, q6) - #else - convertYUV420.ToRGB(y1 + j, y2 + j, uv + j, dst1 + dj, dst2 + dj); -@@ -2637,7 +2637,7 @@ void yuv420i2rgbx(const Size2D &size, - internal::prefetch(uv + j); - internal::prefetch(y1 + j); - internal::prefetch(y2 + j); --#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 -+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 && !defined(__clang__) - CONVERTYUV420TORGB(4, d0, d1, q5, q6) - #else - convertYUV420.ToRGB(y1 + j, y2 + j, uv + j, dst1 + dj, dst2 + dj); -@@ -2683,7 +2683,7 @@ void yuv420sp2bgr(const Size2D &size, - internal::prefetch(uv + j); - internal::prefetch(y1 + j); - internal::prefetch(y2 + j); --#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 -+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 && !defined(__clang__) - CONVERTYUV420TORGB(3, d1, d0, q6, q5) - #else - convertYUV420.ToRGB(y1 + j, y2 + j, uv + j, dst1 + dj, dst2 + dj); -@@ -2729,7 +2729,7 @@ void yuv420sp2bgrx(const Size2D &size, - internal::prefetch(uv + j); - internal::prefetch(y1 + j); - internal::prefetch(y2 + j); --#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 -+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 && !defined(__clang__) - CONVERTYUV420TORGB(4, d1, d0, q6, q5) - #else - convertYUV420.ToRGB(y1 + j, y2 + j, uv + j, dst1 + dj, dst2 + dj); -@@ -2775,7 +2775,7 @@ void yuv420i2bgr(const Size2D &size, - internal::prefetch(uv + j); - internal::prefetch(y1 + j); - internal::prefetch(y2 + j); --#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 -+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 && !defined(__clang__) - CONVERTYUV420TORGB(3, d0, d1, q6, q5) - #else - convertYUV420.ToRGB(y1 + j, y2 + j, uv + j, dst1 + dj, dst2 + dj); -@@ -2821,7 +2821,7 @@ void yuv420i2bgrx(const Size2D &size, - internal::prefetch(uv + j); - internal::prefetch(y1 + j); - internal::prefetch(y2 + j); --#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 -+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 && !defined(__clang__) - CONVERTYUV420TORGB(4, d0, d1, q6, q5) - #else - convertYUV420.ToRGB(y1 + j, y2 + j, uv + j, dst1 + dj, dst2 + dj); -diff --git a/3rdparty/carotene/src/convert.cpp b/3rdparty/carotene/src/convert.cpp -index 64b6db78ab..f0c2d153f2 100644 ---- a/3rdparty/carotene/src/convert.cpp -+++ b/3rdparty/carotene/src/convert.cpp -@@ -101,7 +101,7 @@ CVT_FUNC(u8, s8, 16, - } - }) - --#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 -+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 && !defined(__clang__) - CVT_FUNC(u8, u16, 16, - register uint8x16_t zero0 asm ("q1") = vmovq_n_u8(0);, - { -@@ -135,7 +135,7 @@ CVT_FUNC(u8, u16, 16, - }) - #endif - --#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 -+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 && !defined(__clang__) - CVT_FUNC(u8, s32, 16, - register uint8x16_t zero0 asm ("q1") = vmovq_n_u8(0); - register uint8x16_t zero1 asm ("q2") = vmovq_n_u8(0); -@@ -173,7 +173,7 @@ CVT_FUNC(u8, s32, 16, - }) - #endif - --#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 6 -+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 6 && !defined(__clang__) - CVT_FUNC(u8, f32, 16, - , - { -@@ -248,7 +248,7 @@ CVT_FUNC(s8, u8, 16, - } - }) - --#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 -+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 && !defined(__clang__) - CVT_FUNC(s8, u16, 16, - register uint8x16_t zero0 asm ("q1") = vmovq_n_u8(0);, - { -@@ -284,7 +284,7 @@ CVT_FUNC(s8, u16, 16, - }) - #endif - --#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 6 -+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 6 && !defined(__clang__) - CVT_FUNC(s8, s16, 16, - , - { -@@ -323,7 +323,7 @@ CVT_FUNC(s8, s16, 16, - }) - #endif - --#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 -+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 && !defined(__clang__) - CVT_FUNC(s8, s32, 16, - , - { -@@ -377,7 +377,7 @@ CVT_FUNC(s8, s32, 16, - }) - #endif - --#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 6 -+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 6 && !defined(__clang__) - CVT_FUNC(s8, f32, 16, - , - { -@@ -440,7 +440,7 @@ CVT_FUNC(s8, f32, 16, - }) - #endif - --#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 6 -+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 6 && !defined(__clang__) - CVT_FUNC(u16, u8, 16, - , - { -@@ -479,7 +479,7 @@ CVT_FUNC(u16, u8, 16, - }) - #endif - --#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 6 -+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 6 && !defined(__clang__) - CVT_FUNC(u16, s8, 16, - register uint8x16_t v127 asm ("q4") = vmovq_n_u8(127);, - { -@@ -522,7 +522,7 @@ CVT_FUNC(u16, s8, 16, - }) - #endif - --#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 -+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 && !defined(__clang__) - CVT_FUNC(u16, s16, 8, - register uint16x8_t v32767 asm ("q4") = vmovq_n_u16(0x7FFF);, - { -@@ -555,7 +555,7 @@ CVT_FUNC(u16, s16, 8, - }) - #endif - --#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 -+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 && !defined(__clang__) - CVT_FUNC(u16, s32, 8, - register uint16x8_t zero0 asm ("q1") = vmovq_n_u16(0);, - { -@@ -589,7 +589,7 @@ CVT_FUNC(u16, s32, 8, - }) - #endif - --#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 6 -+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 6 && !defined(__clang__) - CVT_FUNC(u16, f32, 8, - , - { -@@ -633,7 +633,7 @@ CVT_FUNC(u16, f32, 8, - }) - #endif - --#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 6 -+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 6 && !defined(__clang__) - CVT_FUNC(s16, u8, 16, - , - { -@@ -672,7 +672,7 @@ CVT_FUNC(s16, u8, 16, - }) - #endif - --#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 6 -+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 6 && !defined(__clang__) - CVT_FUNC(s16, s8, 16, - , - { -@@ -711,7 +711,7 @@ CVT_FUNC(s16, s8, 16, - }) - #endif - --#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 -+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 && !defined(__clang__) - CVT_FUNC(s16, u16, 8, - register int16x8_t vZero asm ("q4") = vmovq_n_s16(0);, - { -@@ -747,7 +747,7 @@ CVT_FUNC(s16, u16, 8, - }) - #endif - --#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 6 -+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 6 && !defined(__clang__) - CVT_FUNC(s16, s32, 8, - , - { -@@ -786,7 +786,7 @@ CVT_FUNC(s16, s32, 8, - }) - #endif - --#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 6 -+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 6 && !defined(__clang__) - CVT_FUNC(s16, f32, 8, - , - { -@@ -829,7 +829,7 @@ CVT_FUNC(s16, f32, 8, - }) - #endif - --#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 6 -+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 6 && !defined(__clang__) - CVT_FUNC(s32, u8, 8, - , - { -@@ -870,7 +870,7 @@ CVT_FUNC(s32, u8, 8, - }) - #endif - --#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 6 -+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 6 && !defined(__clang__) - CVT_FUNC(s32, s8, 8, - , - { -@@ -911,7 +911,7 @@ CVT_FUNC(s32, s8, 8, - }) - #endif - --#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 6 -+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 6 && !defined(__clang__) - CVT_FUNC(s32, u16, 8, - , - { -@@ -950,7 +950,7 @@ CVT_FUNC(s32, u16, 8, - }) - #endif - --#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 6 -+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 6 && !defined(__clang__) - CVT_FUNC(s32, s16, 8, - , - { -@@ -989,7 +989,7 @@ CVT_FUNC(s32, s16, 8, - }) - #endif - --#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 6 -+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 6 && !defined(__clang__) - CVT_FUNC(s32, f32, 8, - , - { -@@ -1034,7 +1034,7 @@ CVT_FUNC(s32, f32, 8, - }) - #endif - --#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 6 -+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 6 && !defined(__clang__) - CVT_FUNC(f32, u8, 8, - register float32x4_t vmult asm ("q0") = vdupq_n_f32((float)(1 << 16)); - register uint32x4_t vmask asm ("q1") = vdupq_n_u32(1<<16);, -@@ -1101,7 +1101,7 @@ CVT_FUNC(f32, u8, 8, - }) - #endif - --#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 6 -+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 6 && !defined(__clang__) - CVT_FUNC(f32, s8, 8, - register float32x4_t vhalf asm ("q0") = vdupq_n_f32(0.5f);, - { -@@ -1153,7 +1153,7 @@ CVT_FUNC(f32, s8, 8, - }) - #endif - --#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 6 -+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 6 && !defined(__clang__) - CVT_FUNC(f32, u16, 8, - register float32x4_t vhalf asm ("q0") = vdupq_n_f32(0.5f);, - { -@@ -1212,7 +1212,7 @@ CVT_FUNC(f32, u16, 8, - }) - #endif - --#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 6 -+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 6 && !defined(__clang__) - CVT_FUNC(f32, s16, 8, - register float32x4_t vhalf asm ("q0") = vdupq_n_f32(0.5f);, - { -@@ -1271,7 +1271,7 @@ CVT_FUNC(f32, s16, 8, - }) - #endif - --#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 6 -+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 6 && !defined(__clang__) - CVT_FUNC(f32, s32, 8, - register float32x4_t vhalf asm ("q0") = vdupq_n_f32(0.5f);, - { -diff --git a/3rdparty/carotene/src/convert_scale.cpp b/3rdparty/carotene/src/convert_scale.cpp -index ae41a985c8..d599d24c1e 100644 ---- a/3rdparty/carotene/src/convert_scale.cpp -+++ b/3rdparty/carotene/src/convert_scale.cpp -@@ -473,7 +473,7 @@ CVTS_FUNC(u8, s16, 16, - }) - #endif - --#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 -+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 && !defined(__clang__) - CVTS_FUNC(u8, s32, 16, - register float32x4_t vscale asm ("q0") = vdupq_n_f32((f32)alpha); - register float32x4_t vshift asm ("q1") = vdupq_n_f32((f32)beta + 0.5f);, -@@ -562,7 +562,7 @@ CVTS_FUNC(u8, s32, 16, - }) - #endif - --#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 -+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 && !defined(__clang__) - CVTS_FUNC(u8, f32, 16, - register float32x4_t vscale asm ("q0") = vdupq_n_f32((f32)alpha); - register float32x4_t vshift asm ("q1") = vdupq_n_f32((f32)beta);, -@@ -985,7 +985,7 @@ CVTS_FUNC(s8, s16, 16, - }) - #endif - --#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 -+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 && !defined(__clang__) - CVTS_FUNC(s8, s32, 16, - register float32x4_t vscale asm ("q0") = vdupq_n_f32((f32)alpha); - register float32x4_t vshift asm ("q1") = vdupq_n_f32((f32)beta + 0.5f);, -@@ -1074,7 +1074,7 @@ CVTS_FUNC(s8, s32, 16, - }) - #endif - --#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 -+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 && !defined(__clang__) - CVTS_FUNC(s8, f32, 16, - register float32x4_t vscale asm ("q0") = vdupq_n_f32((f32)alpha); - register float32x4_t vshift asm ("q1") = vdupq_n_f32((f32)beta);, -@@ -1155,7 +1155,7 @@ CVTS_FUNC(s8, f32, 16, - }) - #endif - --#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 -+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 && !defined(__clang__) - CVTS_FUNC(u16, u8, 16, - register float32x4_t vscale asm ("q0") = vdupq_n_f32((f32)alpha); - register float32x4_t vshift asm ("q1") = vdupq_n_f32((f32)beta + 0.5f);, -@@ -1214,7 +1214,7 @@ CVTS_FUNC(u16, u8, 16, - }) - #endif - --#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 -+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 && !defined(__clang__) - CVTS_FUNC(u16, s8, 16, - register float32x4_t vscale asm ("q0") = vdupq_n_f32((f32)alpha); - register float32x4_t vshift asm ("q1") = vdupq_n_f32((f32)beta + 0.5f);, -@@ -1273,7 +1273,7 @@ CVTS_FUNC(u16, s8, 16, - }) - #endif - --#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 -+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 && !defined(__clang__) - CVTS_FUNC1(u16, 16, - register float32x4_t vscale asm ("q0") = vdupq_n_f32((f32)alpha); - register float32x4_t vshift asm ("q1") = vdupq_n_f32((f32)beta + 0.5f);, -@@ -1330,7 +1330,7 @@ CVTS_FUNC1(u16, 16, - }) - #endif - --#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 -+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 && !defined(__clang__) - CVTS_FUNC(u16, s16, 8, - register float32x4_t vscale asm ("q0") = vdupq_n_f32((f32)alpha); - register float32x4_t vshift asm ("q1") = vdupq_n_f32((f32)beta + 0.5f);, -@@ -1387,7 +1387,7 @@ CVTS_FUNC(u16, s16, 8, - }) - #endif - --#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 -+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 && !defined(__clang__) - CVTS_FUNC(u16, s32, 8, - register float32x4_t vscale asm ("q0") = vdupq_n_f32((f32)alpha); - register float32x4_t vshift asm ("q1") = vdupq_n_f32((f32)beta + 0.5f);, -@@ -1443,7 +1443,7 @@ CVTS_FUNC(u16, s32, 8, - }) - #endif - --#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 -+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 && !defined(__clang__) - CVTS_FUNC(u16, f32, 8, - register float32x4_t vscale asm ("q0") = vdupq_n_f32((f32)alpha); - register float32x4_t vshift asm ("q1") = vdupq_n_f32((f32)beta);, -@@ -1495,7 +1495,7 @@ CVTS_FUNC(u16, f32, 8, - }) - #endif - --#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 -+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 && !defined(__clang__) - CVTS_FUNC(s16, u8, 16, - register float32x4_t vscale asm ("q0") = vdupq_n_f32((f32)alpha); - register float32x4_t vshift asm ("q1") = vdupq_n_f32((f32)beta + 0.5f);, -@@ -1554,7 +1554,7 @@ CVTS_FUNC(s16, u8, 16, - }) - #endif - --#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 -+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 && !defined(__clang__) - CVTS_FUNC(s16, s8, 16, - register float32x4_t vscale asm ("q0") = vdupq_n_f32((f32)alpha); - register float32x4_t vshift asm ("q1") = vdupq_n_f32((f32)beta + 0.5f);, -@@ -1613,7 +1613,7 @@ CVTS_FUNC(s16, s8, 16, - }) - #endif - --#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 -+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 && !defined(__clang__) - CVTS_FUNC(s16, u16, 8, - register float32x4_t vscale asm ("q0") = vdupq_n_f32((f32)alpha); - register float32x4_t vshift asm ("q1") = vdupq_n_f32((f32)beta + 0.5f);, -@@ -1670,7 +1670,7 @@ CVTS_FUNC(s16, u16, 8, - }) - #endif - --#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 -+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 && !defined(__clang__) - CVTS_FUNC1(s16, 16, - register float32x4_t vscale asm ("q0") = vdupq_n_f32((f32)alpha); - register float32x4_t vshift asm ("q1") = vdupq_n_f32((f32)beta + 0.5f);, -@@ -1727,7 +1727,7 @@ CVTS_FUNC1(s16, 16, - }) - #endif - --#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 -+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 && !defined(__clang__) - CVTS_FUNC(s16, s32, 8, - register float32x4_t vscale asm ("q0") = vdupq_n_f32((f32)alpha); - register float32x4_t vshift asm ("q1") = vdupq_n_f32((f32)beta + 0.5f);, -@@ -1783,7 +1783,7 @@ CVTS_FUNC(s16, s32, 8, - }) - #endif - --#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 -+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 && !defined(__clang__) - CVTS_FUNC(s16, f32, 8, - register float32x4_t vscale asm ("q0") = vdupq_n_f32((f32)alpha); - register float32x4_t vshift asm ("q1") = vdupq_n_f32((f32)beta);, -@@ -1835,7 +1835,7 @@ CVTS_FUNC(s16, f32, 8, - }) - #endif - --#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 -+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 && !defined(__clang__) - CVTS_FUNC(s32, u8, 8, - register float32x4_t vscale asm ("q0") = vdupq_n_f32((f32)alpha); - register float32x4_t vshift asm ("q1") = vdupq_n_f32((f32)beta + 0.5f);, -@@ -1893,7 +1893,7 @@ CVTS_FUNC(s32, u8, 8, - }) - #endif - --#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 -+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 && !defined(__clang__) - CVTS_FUNC(s32, s8, 8, - register float32x4_t vscale asm ("q0") = vdupq_n_f32((f32)alpha); - register float32x4_t vshift asm ("q1") = vdupq_n_f32((f32)beta + 0.5f);, -@@ -1951,7 +1951,7 @@ CVTS_FUNC(s32, s8, 8, - }) - #endif - --#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 -+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 && !defined(__clang__) - CVTS_FUNC(s32, u16, 8, - register float32x4_t vscale asm ("q0") = vdupq_n_f32((f32)alpha); - register float32x4_t vshift asm ("q1") = vdupq_n_f32((f32)beta + 0.5f);, -@@ -2007,7 +2007,7 @@ CVTS_FUNC(s32, u16, 8, - }) - #endif - --#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 -+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 && !defined(__clang__) - CVTS_FUNC(s32, s16, 8, - register float32x4_t vscale asm ("q0") = vdupq_n_f32((f32)alpha); - register float32x4_t vshift asm ("q1") = vdupq_n_f32((f32)beta + 0.5f);, -@@ -2063,7 +2063,7 @@ CVTS_FUNC(s32, s16, 8, - }) - #endif - --#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 -+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 && !defined(__clang__) - CVTS_FUNC1(s32, 8, - register float32x4_t vscale asm ("q0") = vdupq_n_f32((f32)alpha); - register float32x4_t vshift asm ("q1") = vdupq_n_f32((f32)beta + 0.5f);, -@@ -2118,7 +2118,7 @@ CVTS_FUNC1(s32, 8, - }) - #endif - --#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 -+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 && !defined(__clang__) - CVTS_FUNC(s32, f32, 8, - register float32x4_t vscale asm ("q0") = vdupq_n_f32((f32)alpha); - register float32x4_t vshift asm ("q1") = vdupq_n_f32((f32)beta);, -@@ -2169,7 +2169,7 @@ CVTS_FUNC(s32, f32, 8, - }) - #endif - --#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 -+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 && !defined(__clang__) - CVTS_FUNC(f32, u8, 8, - register float32x4_t vscale asm ("q0") = vdupq_n_f32((f32)((1 << 16)*alpha)); - register float32x4_t vshift asm ("q1") = vdupq_n_f32((f32)((1 << 16)*beta)); -@@ -2239,7 +2239,7 @@ CVTS_FUNC(f32, u8, 8, - }) - #endif - --#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 -+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 && !defined(__clang__) - CVTS_FUNC(f32, s8, 8, - register float32x4_t vscale asm ("q0") = vdupq_n_f32((f32)alpha); - register float32x4_t vshift asm ("q1") = vdupq_n_f32((f32)beta + 0.5f);, -@@ -2293,7 +2293,7 @@ CVTS_FUNC(f32, s8, 8, - }) - #endif - --#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 -+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 && !defined(__clang__) - CVTS_FUNC(f32, u16, 8, - register float32x4_t vscale asm ("q0") = vdupq_n_f32((f32)alpha); - register float32x4_t vshift asm ("q1") = vdupq_n_f32((f32)beta + 0.5f);, -@@ -2345,7 +2345,7 @@ CVTS_FUNC(f32, u16, 8, - }) - #endif - --#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 -+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 && !defined(__clang__) - CVTS_FUNC(f32, s16, 8, - register float32x4_t vscale asm ("q0") = vdupq_n_f32((f32)alpha); - register float32x4_t vshift asm ("q1") = vdupq_n_f32((f32)beta + 0.5f);, -@@ -2397,7 +2397,7 @@ CVTS_FUNC(f32, s16, 8, - }) - #endif - --#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 -+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 && !defined(__clang__) - CVTS_FUNC(f32, s32, 8, - register float32x4_t vscale asm ("q0") = vdupq_n_f32((f32)alpha); - register float32x4_t vshift asm ("q1") = vdupq_n_f32((f32)beta + 0.5f);, -@@ -2448,7 +2448,7 @@ CVTS_FUNC(f32, s32, 8, - }) - #endif - --#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 -+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 && !defined(__clang__) - CVTS_FUNC1(f32, 8, - register float32x4_t vscale asm ("q0") = vdupq_n_f32((f32)alpha); - register float32x4_t vshift asm ("q1") = vdupq_n_f32((f32)beta);, -diff --git a/3rdparty/carotene/src/gaussian_blur.cpp b/3rdparty/carotene/src/gaussian_blur.cpp -index f7b5f18d79..e5aa8fc75b 100644 ---- a/3rdparty/carotene/src/gaussian_blur.cpp -+++ b/3rdparty/carotene/src/gaussian_blur.cpp -@@ -327,7 +327,7 @@ void gaussianBlur5x5(const Size2D &size, s32 cn, - u16* lidx1 = lane + x - 1*2; - u16* lidx3 = lane + x + 1*2; - u16* lidx4 = lane + x + 2*2; --#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 -+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 && !defined(__clang__) - __asm__ __volatile__ ( - "vld2.16 {d0, d2}, [%[in0]]! \n\t" - "vld2.16 {d1, d3}, [%[in0]] \n\t" -diff --git a/3rdparty/carotene/src/pyramid.cpp b/3rdparty/carotene/src/pyramid.cpp -index 232ccf3efd..d4e32ea50f 100644 ---- a/3rdparty/carotene/src/pyramid.cpp -+++ b/3rdparty/carotene/src/pyramid.cpp -@@ -331,7 +331,7 @@ void gaussianPyramidDown(const Size2D &srcSize, - for (; x < roiw8; x += 8) - { - internal::prefetch(lane + 2 * x); --#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 -+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 && !defined(__clang__) - __asm__ ( - "vld2.16 {d0-d3}, [%[in0]] \n\t" - "vld2.16 {d4-d7}, [%[in4]] \n\t" -@@ -538,7 +538,7 @@ void gaussianPyramidDown(const Size2D &srcSize, - for (; x < roiw4; x += 4) - { - internal::prefetch(lane + 2 * x); --#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 -+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 && !defined(__clang__) - __asm__ ( - "vld2.32 {d0-d3}, [%[in0]] \n\t" - "vld2.32 {d4-d7}, [%[in4]] \n\t" -@@ -672,7 +672,7 @@ void gaussianPyramidDown(const Size2D &srcSize, - std::vector _buf(cn*(srcSize.width + 4) + 32/sizeof(f32)); - f32* lane = internal::alignPtr(&_buf[2*cn], 32); - --#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 -+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 && !defined(__clang__) - register float32x4_t vc6d4f32 asm ("q11") = vmovq_n_f32(1.5f); // 6/4 - register float32x4_t vc1d4f32 asm ("q12") = vmovq_n_f32(0.25f); // 1/4 - -@@ -739,7 +739,7 @@ void gaussianPyramidDown(const Size2D &srcSize, - for (; x < roiw4; x += 4) - { - internal::prefetch(lane + 2 * x); --#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 -+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 && !defined(__clang__) - __asm__ __volatile__ ( - "vld2.32 {d0-d3}, [%[in0]] \n\t" - "vld2.32 {d8-d11}, [%[in4]] \n\t" -diff --git a/3rdparty/carotene/src/scharr.cpp b/3rdparty/carotene/src/scharr.cpp -index 8d3b6328b1..36f6b2276e 100644 ---- a/3rdparty/carotene/src/scharr.cpp -+++ b/3rdparty/carotene/src/scharr.cpp -@@ -109,7 +109,7 @@ void ScharrDeriv(const Size2D &size, s32 cn, - internal::prefetch(srow0 + x); - internal::prefetch(srow1 + x); - internal::prefetch(srow2 + x); --#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 -+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 7 && !defined(__clang__) - __asm__ ( - "vld1.8 {d0}, [%[src0]] \n\t" - "vld1.8 {d2}, [%[src2]] \n\t" -@@ -161,7 +161,7 @@ void ScharrDeriv(const Size2D &size, s32 cn, - x = 0; - for( ; x < roiw8; x += 8 ) - { --#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 6 -+#if !defined(__aarch64__) && defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ < 6 && !defined(__clang__) - __asm__ ( - "vld1.16 {d4-d5}, [%[s2ptr]] \n\t" - "vld1.16 {d8-d9}, [%[s4ptr]] \n\t" --- -2.14.1 - diff --git a/meta-oe/recipes-support/opencv/opencv/0002-imgcodecs-refactoring-improve-code-quality.patch b/meta-oe/recipes-support/opencv/opencv/0002-imgcodecs-refactoring-improve-code-quality.patch deleted file mode 100644 index 39f33af9de..0000000000 --- a/meta-oe/recipes-support/opencv/opencv/0002-imgcodecs-refactoring-improve-code-quality.patch +++ /dev/null @@ -1,656 +0,0 @@ -Upstream-Status: Backport [https://github.com/opencv/opencv/pull/9376/commits/999f41fb4f4aa94a0cb47256919ae8b5c29ca5f3] - -Fix CVEs for opencv 3.3: - -* CVE-2017-12597 -* CVE-2017-12598 -* CVE-2017-12599 -* CVE-2017-12600 -* CVE-2017-12601 -* CVE-2017-12602 -* CVE-2017-12603 -* CVE-2017-12604 -* CVE-2017-12605 -* CVE-2017-12606 -* CVE-2017-12862 -* CVE-2017-12863 -* CVE-2017-12864 - -Signed-off-by: Kai Kang ---- -From 999f41fb4f4aa94a0cb47256919ae8b5c29ca5f3 Mon Sep 17 00:00:00 2001 -From: Alexander Alekhin -Date: Tue, 15 Aug 2017 22:04:55 +0000 -Subject: [PATCH 2/3] imgcodecs: refactoring, improve code quality - ---- - modules/imgcodecs/src/bitstrm.cpp | 2 + - modules/imgcodecs/src/bitstrm.hpp | 19 +++-- - modules/imgcodecs/src/grfmt_bmp.cpp | 13 ++- - modules/imgcodecs/src/grfmt_pxm.cpp | 122 ++++++++++++++++----------- - modules/imgcodecs/src/loadsave.cpp | 164 +++++++++++++++++++++++++++++------- - 5 files changed, 231 insertions(+), 89 deletions(-) - -diff --git a/modules/imgcodecs/src/bitstrm.cpp b/modules/imgcodecs/src/bitstrm.cpp -index a7e187fa0..0a8941aec 100644 ---- a/modules/imgcodecs/src/bitstrm.cpp -+++ b/modules/imgcodecs/src/bitstrm.cpp -@@ -209,6 +209,8 @@ int RLByteStream::getByte() - current = m_current; - } - -+ CV_Assert(current < m_end); -+ - val = *((uchar*)current); - m_current = current + 1; - return val; -diff --git a/modules/imgcodecs/src/bitstrm.hpp b/modules/imgcodecs/src/bitstrm.hpp -index 465c0a847..26947971f 100644 ---- a/modules/imgcodecs/src/bitstrm.hpp -+++ b/modules/imgcodecs/src/bitstrm.hpp -@@ -48,13 +48,20 @@ - namespace cv - { - --enum --{ -- RBS_THROW_EOS=-123, // exception code -- RBS_THROW_FORB=-124, // exception code -- RBS_HUFF_FORB=2047, // forrbidden huffman code "value" -- RBS_BAD_HEADER=-125 // invalid header -+#define DECLARE_RBS_EXCEPTION(name) \ -+class RBS_ ## name ## _Exception : public cv::Exception \ -+{ \ -+public: \ -+ RBS_ ## name ## _Exception(int code_, const String& err_, const String& func_, const String& file_, int line_) : \ -+ cv::Exception(code_, err_, func_, file_, line_) \ -+ {} \ - }; -+DECLARE_RBS_EXCEPTION(THROW_EOS) -+#define RBS_THROW_EOS RBS_THROW_EOS_Exception(cv::Error::StsError, "Unexpected end of input stream", CV_Func, __FILE__, __LINE__) -+DECLARE_RBS_EXCEPTION(THROW_FORB) -+#define RBS_THROW_FORB RBS_THROW_FORB_Exception(cv::Error::StsError, "Forrbidden huffman code", CV_Func, __FILE__, __LINE__) -+DECLARE_RBS_EXCEPTION(BAD_HEADER) -+#define RBS_BAD_HEADER RBS_BAD_HEADER_Exception(cv::Error::StsError, "Invalid header", CV_Func, __FILE__, __LINE__) - - typedef unsigned long ulong; - -diff --git a/modules/imgcodecs/src/grfmt_bmp.cpp b/modules/imgcodecs/src/grfmt_bmp.cpp -index 86cacd316..257f97c2d 100644 ---- a/modules/imgcodecs/src/grfmt_bmp.cpp -+++ b/modules/imgcodecs/src/grfmt_bmp.cpp -@@ -118,8 +118,9 @@ bool BmpDecoder::readHeader() - - if( m_bpp <= 8 ) - { -- memset( m_palette, 0, sizeof(m_palette)); -- m_strm.getBytes( m_palette, (clrused == 0? 1< 2 ) // absolute mode - { - if( data + code*nch > line_end ) goto decode_rle4_bad; -- m_strm.getBytes( src, (((code + 1)>>1) + 1) & -2 ); -+ int sz = (((code + 1)>>1) + 1) & (~1); -+ CV_Assert((size_t)sz < _src.size()); -+ m_strm.getBytes(src, sz); - if( color ) - data = FillColorRow4( data, src, code, m_palette ); - else -@@ -379,7 +382,9 @@ decode_rle4_bad: ; - - if( data + code3 > line_end ) - goto decode_rle8_bad; -- m_strm.getBytes( src, (code + 1) & -2 ); -+ int sz = (code + 1) & (~1); -+ CV_Assert((size_t)sz < _src.size()); -+ m_strm.getBytes(src, sz); - if( color ) - data = FillColorRow8( data, src, code, m_palette ); - else -diff --git a/modules/imgcodecs/src/grfmt_pxm.cpp b/modules/imgcodecs/src/grfmt_pxm.cpp -index 1750cb705..68bd8fd93 100644 ---- a/modules/imgcodecs/src/grfmt_pxm.cpp -+++ b/modules/imgcodecs/src/grfmt_pxm.cpp -@@ -43,50 +43,58 @@ - #include "precomp.hpp" - #include "utils.hpp" - #include "grfmt_pxm.hpp" -+#include - - namespace cv - { - - ///////////////////////// P?M reader ////////////////////////////// - --static int ReadNumber( RLByteStream& strm, int maxdigits ) -+static int ReadNumber(RLByteStream& strm, int maxdigits = 0) - { - int code; -- int val = 0; -+ int64 val = 0; - int digits = 0; - - code = strm.getByte(); - -- if( !isdigit(code)) -+ while (!isdigit(code)) - { -- do -+ if (code == '#' ) - { -- if( code == '#' ) -+ do - { -- do -- { -- code = strm.getByte(); -- } -- while( code != '\n' && code != '\r' ); -+ code = strm.getByte(); - } -- -+ while (code != '\n' && code != '\r'); - code = strm.getByte(); -- -- while( isspace(code)) -+ } -+ else if (isspace(code)) -+ { -+ while (isspace(code)) - code = strm.getByte(); - } -- while( !isdigit( code )); -+ else -+ { -+#if 1 -+ CV_ErrorNoReturn_(Error::StsError, ("PXM: Unexpected code in ReadNumber(): 0x%x (%d)", code, code)); -+#else -+ code = strm.getByte(); -+#endif -+ } - } - - do - { -- val = val*10 + code - '0'; -- if( ++digits >= maxdigits ) break; -+ val = val*10 + (code - '0'); -+ CV_Assert(val <= INT_MAX && "PXM: ReadNumber(): result is too large"); -+ digits++; -+ if (maxdigits != 0 && digits >= maxdigits) break; - code = strm.getByte(); - } -- while( isdigit(code)); -+ while (isdigit(code)); - -- return val; -+ return (int)val; - } - - -@@ -122,13 +130,13 @@ ImageDecoder PxMDecoder::newDecoder() const - return makePtr(); - } - --void PxMDecoder::close() -+void PxMDecoder::close() - { - m_strm.close(); - } - - --bool PxMDecoder::readHeader() -+bool PxMDecoder::readHeader() - { - bool result = false; - -@@ -158,10 +166,10 @@ bool PxMDecoder::readHeader() - m_binary = code >= '4'; - m_type = m_bpp > 8 ? CV_8UC3 : CV_8UC1; - -- m_width = ReadNumber( m_strm, INT_MAX ); -- m_height = ReadNumber( m_strm, INT_MAX ); -+ m_width = ReadNumber(m_strm); -+ m_height = ReadNumber(m_strm); - -- m_maxval = m_bpp == 1 ? 1 : ReadNumber( m_strm, INT_MAX ); -+ m_maxval = m_bpp == 1 ? 1 : ReadNumber(m_strm); - if( m_maxval > 65535 ) - throw RBS_BAD_HEADER; - -@@ -175,8 +183,14 @@ bool PxMDecoder::readHeader() - result = true; - } - } -- catch(...) -+ catch (const cv::Exception&) -+ { -+ throw; -+ } -+ catch (...) - { -+ std::cerr << "PXM::readHeader(): unknown C++ exception" << std::endl << std::flush; -+ throw; - } - - if( !result ) -@@ -189,33 +203,28 @@ bool PxMDecoder::readHeader() - } - - --bool PxMDecoder::readData( Mat& img ) -+bool PxMDecoder::readData( Mat& img ) - { - int color = img.channels() > 1; - uchar* data = img.ptr(); - PaletteEntry palette[256]; - bool result = false; -- int bit_depth = CV_ELEM_SIZE1(m_type)*8; -- int src_pitch = (m_width*m_bpp*bit_depth/8 + 7)/8; -+ const int bit_depth = CV_ELEM_SIZE1(m_type)*8; -+ const int src_pitch = divUp(m_width*m_bpp*(bit_depth/8), 8); - int nch = CV_MAT_CN(m_type); - int width3 = m_width*nch; -- int i, x, y; - - if( m_offset < 0 || !m_strm.isOpened()) - return false; - -- AutoBuffer _src(src_pitch + 32); -- uchar* src = _src; -- AutoBuffer _gray_palette; -- uchar* gray_palette = _gray_palette; -+ uchar gray_palette[256] = {0}; - - // create LUT for converting colors - if( bit_depth == 8 ) - { -- _gray_palette.allocate(m_maxval + 1); -- gray_palette = _gray_palette; -+ CV_Assert(m_maxval < 256); - -- for( i = 0; i <= m_maxval; i++ ) -+ for (int i = 0; i <= m_maxval; i++) - gray_palette[i] = (uchar)((i*255/m_maxval)^(m_bpp == 1 ? 255 : 0)); - - FillGrayPalette( palette, m_bpp==1 ? 1 : 8 , m_bpp == 1 ); -@@ -229,12 +238,16 @@ bool PxMDecoder::readData( Mat& img ) - { - ////////////////////////// 1 BPP ///////////////////////// - case 1: -+ CV_Assert(CV_MAT_DEPTH(m_type) == CV_8U); - if( !m_binary ) - { -- for( y = 0; y < m_height; y++, data += img.step ) -+ AutoBuffer _src(m_width); -+ uchar* src = _src; -+ -+ for (int y = 0; y < m_height; y++, data += img.step) - { -- for( x = 0; x < m_width; x++ ) -- src[x] = ReadNumber( m_strm, 1 ) != 0; -+ for (int x = 0; x < m_width; x++) -+ src[x] = ReadNumber(m_strm, 1) != 0; - - if( color ) - FillColorRow8( data, src, m_width, palette ); -@@ -244,7 +257,10 @@ bool PxMDecoder::readData( Mat& img ) - } - else - { -- for( y = 0; y < m_height; y++, data += img.step ) -+ AutoBuffer _src(src_pitch); -+ uchar* src = _src; -+ -+ for (int y = 0; y < m_height; y++, data += img.step) - { - m_strm.getBytes( src, src_pitch ); - -@@ -260,13 +276,17 @@ bool PxMDecoder::readData( Mat& img ) - ////////////////////////// 8 BPP ///////////////////////// - case 8: - case 24: -- for( y = 0; y < m_height; y++, data += img.step ) -+ { -+ AutoBuffer _src(std::max(width3*2, src_pitch)); -+ uchar* src = _src; -+ -+ for (int y = 0; y < m_height; y++, data += img.step) - { - if( !m_binary ) - { -- for( x = 0; x < width3; x++ ) -+ for (int x = 0; x < width3; x++) - { -- int code = ReadNumber( m_strm, INT_MAX ); -+ int code = ReadNumber(m_strm); - if( (unsigned)code > (unsigned)m_maxval ) code = m_maxval; - if( bit_depth == 8 ) - src[x] = gray_palette[code]; -@@ -279,7 +299,7 @@ bool PxMDecoder::readData( Mat& img ) - m_strm.getBytes( src, src_pitch ); - if( bit_depth == 16 && !isBigEndian() ) - { -- for( x = 0; x < width3; x++ ) -+ for (int x = 0; x < width3; x++) - { - uchar v = src[x * 2]; - src[x * 2] = src[x * 2 + 1]; -@@ -290,7 +310,7 @@ bool PxMDecoder::readData( Mat& img ) - - if( img.depth() == CV_8U && bit_depth == 16 ) - { -- for( x = 0; x < width3; x++ ) -+ for (int x = 0; x < width3; x++) - { - int v = ((ushort *)src)[x]; - src[x] = (uchar)(v >> 8); -@@ -331,12 +351,19 @@ bool PxMDecoder::readData( Mat& img ) - } - result = true; - break; -+ } - default: -- assert(0); -+ CV_ErrorNoReturn(Error::StsError, "m_bpp is not supported"); - } - } -- catch(...) -+ catch (const cv::Exception&) -+ { -+ throw; -+ } -+ catch (...) - { -+ std::cerr << "PXM::readData(): unknown exception" << std::endl << std::flush; -+ throw; - } - - return result; -@@ -412,8 +439,9 @@ bool PxMEncoder::write( const Mat& img, const std::vector& params ) - char* buffer = _buffer; - - // write header; -- sprintf( buffer, "P%c\n%d %d\n%d\n", -+ sprintf( buffer, "P%c\n# Generated by OpenCV %s\n%d %d\n%d\n", - '2' + (channels > 1 ? 1 : 0) + (isBinary ? 3 : 0), -+ CV_VERSION, - width, height, (1 << depth) - 1 ); - - strm.putBytes( buffer, (int)strlen(buffer) ); -diff --git a/modules/imgcodecs/src/loadsave.cpp b/modules/imgcodecs/src/loadsave.cpp -index 3b2366217..5ee4ca354 100644 ---- a/modules/imgcodecs/src/loadsave.cpp -+++ b/modules/imgcodecs/src/loadsave.cpp -@@ -55,6 +55,27 @@ - /****************************************************************************************\ - * Image Codecs * - \****************************************************************************************/ -+ -+namespace cv { -+ -+// TODO Add runtime configuration -+#define CV_IO_MAX_IMAGE_PARAMS (50) -+#define CV_IO_MAX_IMAGE_WIDTH (1<<20) -+#define CV_IO_MAX_IMAGE_HEIGHT (1<<20) -+#define CV_IO_MAX_IMAGE_PIXELS (1<<30) // 1 Gigapixel -+ -+static Size validateInputImageSize(const Size& size) -+{ -+ CV_Assert(size.width > 0); -+ CV_Assert(size.width <= CV_IO_MAX_IMAGE_WIDTH); -+ CV_Assert(size.height > 0); -+ CV_Assert(size.height <= CV_IO_MAX_IMAGE_HEIGHT); -+ uint64 pixels = (uint64)size.width * (uint64)size.height; -+ CV_Assert(pixels <= CV_IO_MAX_IMAGE_PIXELS); -+ return size; -+} -+ -+ - namespace { - - class ByteStreamBuffer: public std::streambuf -@@ -94,9 +115,6 @@ protected: - - } - --namespace cv --{ -- - /** - * @struct ImageCodecInitializer - * -@@ -408,14 +426,26 @@ imread_( const String& filename, int flags, int hdrtype, Mat* mat=0 ) - /// set the filename in the driver - decoder->setSource( filename ); - -- // read the header to make sure it succeeds -- if( !decoder->readHeader() ) -+ try -+ { -+ // read the header to make sure it succeeds -+ if( !decoder->readHeader() ) -+ return 0; -+ } -+ catch (const cv::Exception& e) -+ { -+ std::cerr << "imread_('" << filename << "'): can't read header: " << e.what() << std::endl << std::flush; - return 0; -+ } -+ catch (...) -+ { -+ std::cerr << "imread_('" << filename << "'): can't read header: unknown exception" << std::endl << std::flush; -+ return 0; -+ } -+ - - // established the required input image size -- CvSize size; -- size.width = decoder->width(); -- size.height = decoder->height(); -+ Size size = validateInputImageSize(Size(decoder->width(), decoder->height())); - - // grab the decoded type - int type = decoder->type(); -@@ -451,7 +481,21 @@ imread_( const String& filename, int flags, int hdrtype, Mat* mat=0 ) - } - - // read the image data -- if( !decoder->readData( *data )) -+ bool success = false; -+ try -+ { -+ if (decoder->readData(*data)) -+ success = true; -+ } -+ catch (const cv::Exception& e) -+ { -+ std::cerr << "imread_('" << filename << "'): can't read data: " << e.what() << std::endl << std::flush; -+ } -+ catch (...) -+ { -+ std::cerr << "imread_('" << filename << "'): can't read data: unknown exception" << std::endl << std::flush; -+ } -+ if (!success) - { - cvReleaseImage( &image ); - cvReleaseMat( &matrix ); -@@ -504,8 +548,22 @@ imreadmulti_(const String& filename, int flags, std::vector& mats) - decoder->setSource(filename); - - // read the header to make sure it succeeds -- if (!decoder->readHeader()) -+ try -+ { -+ // read the header to make sure it succeeds -+ if( !decoder->readHeader() ) -+ return 0; -+ } -+ catch (const cv::Exception& e) -+ { -+ std::cerr << "imreadmulti_('" << filename << "'): can't read header: " << e.what() << std::endl << std::flush; - return 0; -+ } -+ catch (...) -+ { -+ std::cerr << "imreadmulti_('" << filename << "'): can't read header: unknown exception" << std::endl << std::flush; -+ return 0; -+ } - - for (;;) - { -@@ -523,17 +581,32 @@ imreadmulti_(const String& filename, int flags, std::vector& mats) - type = CV_MAKETYPE(CV_MAT_DEPTH(type), 1); - } - -+ // established the required input image size -+ Size size = validateInputImageSize(Size(decoder->width(), decoder->height())); -+ - // read the image data -- Mat mat(decoder->height(), decoder->width(), type); -- if (!decoder->readData(mat)) -+ Mat mat(size.height, size.width, type); -+ bool success = false; -+ try - { -- // optionally rotate the data if EXIF' orientation flag says so -- if( (flags & IMREAD_IGNORE_ORIENTATION) == 0 && flags != IMREAD_UNCHANGED ) -- { -- ApplyExifOrientation(filename, mat); -- } -- -+ if (decoder->readData(mat)) -+ success = true; -+ } -+ catch (const cv::Exception& e) -+ { -+ std::cerr << "imreadmulti_('" << filename << "'): can't read data: " << e.what() << std::endl << std::flush; -+ } -+ catch (...) -+ { -+ std::cerr << "imreadmulti_('" << filename << "'): can't read data: unknown exception" << std::endl << std::flush; -+ } -+ if (!success) - break; -+ -+ // optionally rotate the data if EXIF' orientation flag says so -+ if( (flags & IMREAD_IGNORE_ORIENTATION) == 0 && flags != IMREAD_UNCHANGED ) -+ { -+ ApplyExifOrientation(filename, mat); - } - - mats.push_back(mat); -@@ -616,6 +689,7 @@ static bool imwrite_( const String& filename, const Mat& image, - } - - encoder->setDestination( filename ); -+ CV_Assert(params.size() <= CV_IO_MAX_IMAGE_PARAMS*2); - bool code = encoder->write( *pimage, params ); - - // CV_Assert( code ); -@@ -663,22 +737,35 @@ imdecode_( const Mat& buf, int flags, int hdrtype, Mat* mat=0 ) - decoder->setSource(filename); - } - -- if( !decoder->readHeader() ) -+ bool success = false; -+ try -+ { -+ if (decoder->readHeader()) -+ success = true; -+ } -+ catch (const cv::Exception& e) -+ { -+ std::cerr << "imdecode_('" << filename << "'): can't read header: " << e.what() << std::endl << std::flush; -+ } -+ catch (...) -+ { -+ std::cerr << "imdecode_('" << filename << "'): can't read header: unknown exception" << std::endl << std::flush; -+ } -+ if (!success) - { - decoder.release(); -- if ( !filename.empty() ) -+ if (!filename.empty()) - { -- if ( remove(filename.c_str()) != 0 ) -+ if (0 != remove(filename.c_str())) - { -- CV_Error( CV_StsError, "unable to remove temporary file" ); -+ std::cerr << "unable to remove temporary file:" << filename << std::endl << std::flush; - } - } - return 0; - } - -- CvSize size; -- size.width = decoder->width(); -- size.height = decoder->height(); -+ // established the required input image size -+ Size size = validateInputImageSize(Size(decoder->width(), decoder->height())); - - int type = decoder->type(); - if( (flags & IMREAD_LOAD_GDAL) != IMREAD_LOAD_GDAL && flags != IMREAD_UNCHANGED ) -@@ -712,17 +799,30 @@ imdecode_( const Mat& buf, int flags, int hdrtype, Mat* mat=0 ) - temp = cvarrToMat(image); - } - -- bool code = decoder->readData( *data ); -+ success = false; -+ try -+ { -+ if (decoder->readData(*data)) -+ success = true; -+ } -+ catch (const cv::Exception& e) -+ { -+ std::cerr << "imdecode_('" << filename << "'): can't read data: " << e.what() << std::endl << std::flush; -+ } -+ catch (...) -+ { -+ std::cerr << "imdecode_('" << filename << "'): can't read data: unknown exception" << std::endl << std::flush; -+ } - decoder.release(); -- if ( !filename.empty() ) -+ if (!filename.empty()) - { -- if ( remove(filename.c_str()) != 0 ) -+ if (0 != remove(filename.c_str())) - { -- CV_Error( CV_StsError, "unable to remove temporary file" ); -+ std::cerr << "unable to remove temporary file:" << filename << std::endl << std::flush; - } - } - -- if( !code ) -+ if (!success) - { - cvReleaseImage( &image ); - cvReleaseMat( &matrix ); -@@ -859,7 +959,7 @@ cvSaveImage( const char* filename, const CvArr* arr, const int* _params ) - if( _params ) - { - for( ; _params[i] > 0; i += 2 ) -- ; -+ CV_Assert(i < CV_IO_MAX_IMAGE_PARAMS*2); // Limit number of params for security reasons - } - return cv::imwrite_(filename, cv::cvarrToMat(arr), - i > 0 ? std::vector(_params, _params+i) : std::vector(), -@@ -890,7 +990,7 @@ cvEncodeImage( const char* ext, const CvArr* arr, const int* _params ) - if( _params ) - { - for( ; _params[i] > 0; i += 2 ) -- ; -+ CV_Assert(i < CV_IO_MAX_IMAGE_PARAMS*2); // Limit number of params for security reasons - } - cv::Mat img = cv::cvarrToMat(arr); - if( CV_IS_IMAGE(arr) && ((const IplImage*)arr)->origin == IPL_ORIGIN_BL ) --- -2.14.1 - diff --git a/meta-oe/recipes-support/opencv/opencv/0003-To-fix-errors-as-following.patch b/meta-oe/recipes-support/opencv/opencv/0003-To-fix-errors-as-following.patch index a22b04a905..5270b8c9f5 100644 --- a/meta-oe/recipes-support/opencv/opencv/0003-To-fix-errors-as-following.patch +++ b/meta-oe/recipes-support/opencv/opencv/0003-To-fix-errors-as-following.patch @@ -19,29 +19,21 @@ Signed-off-by: Ismo Puustinen modules/ts/include/opencv2/ts/ts_ext.hpp | 2 +- 3 files changed, 5 insertions(+), 5 deletions(-) -diff --git a/modules/ts/include/opencv2/ts.hpp b/modules/ts/include/opencv2/ts.hpp -index 41a76b13e..205646140 100644 ---- a/modules/ts/include/opencv2/ts.hpp -+++ b/modules/ts/include/opencv2/ts.hpp -@@ -555,7 +555,7 @@ protected: +Index: git/modules/ts/include/opencv2/ts.hpp +=================================================================== +--- git.orig/modules/ts/include/opencv2/ts.hpp ++++ git/modules/ts/include/opencv2/ts.hpp +@@ -608,7 +608,7 @@ protected: } }; -extern uint64 param_seed; +CV_EXPORTS extern uint64 param_seed; - struct CV_EXPORTS DefaultRngAuto + struct DefaultRngAuto { -@@ -611,14 +611,14 @@ CV_EXPORTS std::string findDataFile(const std::string& relative_path, bool requi - - #ifdef HAVE_OPENCL - namespace ocl { --void dumpOpenCLDevice(); -+CV_EXPORTS void dumpOpenCLDevice(); - } - #define TEST_DUMP_OCL_INFO cvtest::ocl::dumpOpenCLDevice(); - #else - #define TEST_DUMP_OCL_INFO +@@ -671,7 +671,7 @@ private: + #endif #endif -void parseCustomOptions(int argc, char **argv); @@ -49,10 +41,10 @@ index 41a76b13e..205646140 100644 #define CV_TEST_INIT0_NOOP (void)0 -diff --git a/modules/ts/include/opencv2/ts/ocl_test.hpp b/modules/ts/include/opencv2/ts/ocl_test.hpp -index 54b33ece8..ef56bf9ef 100644 ---- a/modules/ts/include/opencv2/ts/ocl_test.hpp -+++ b/modules/ts/include/opencv2/ts/ocl_test.hpp +Index: git/modules/ts/include/opencv2/ts/ocl_test.hpp +=================================================================== +--- git.orig/modules/ts/include/opencv2/ts/ocl_test.hpp ++++ git/modules/ts/include/opencv2/ts/ocl_test.hpp @@ -82,7 +82,7 @@ inline UMat ToUMat(InputArray src) return dst; } @@ -62,19 +54,16 @@ index 54b33ece8..ef56bf9ef 100644 #define MAX_VALUE 357 -diff --git a/modules/ts/include/opencv2/ts/ts_ext.hpp b/modules/ts/include/opencv2/ts/ts_ext.hpp -index 0bdd346dd..2cd34dfce 100644 ---- a/modules/ts/include/opencv2/ts/ts_ext.hpp -+++ b/modules/ts/include/opencv2/ts/ts_ext.hpp +Index: git/modules/ts/include/opencv2/ts/ts_ext.hpp +=================================================================== +--- git.orig/modules/ts/include/opencv2/ts/ts_ext.hpp ++++ git/modules/ts/include/opencv2/ts/ts_ext.hpp @@ -9,7 +9,7 @@ #define OPENCV_TS_EXT_HPP namespace cvtest { -void checkIppStatus(); +CV_EXPORTS void checkIppStatus(); - } - - #define CV_TEST_INIT \ --- -2.13.4 - + extern bool skipUnstableTests; + extern bool runBigDataTests; + extern int testThreads; diff --git a/meta-oe/recipes-support/opencv/opencv/0003-imgproc-test-add-checks-for-remove-call.patch b/meta-oe/recipes-support/opencv/opencv/0003-imgproc-test-add-checks-for-remove-call.patch deleted file mode 100644 index 5f4a60c960..0000000000 --- a/meta-oe/recipes-support/opencv/opencv/0003-imgproc-test-add-checks-for-remove-call.patch +++ /dev/null @@ -1,186 +0,0 @@ -Upstream-Status: Backport [https://github.com/opencv/opencv/pull/9376/commits/78a310630fb0a1f6d089576202343e672f27609d] - -Fix CVEs for opencv 3.3. - -* CVE-2017-12597 -* CVE-2017-12598 -* CVE-2017-12599 -* CVE-2017-12600 -* CVE-2017-12601 -* CVE-2017-12602 -* CVE-2017-12603 -* CVE-2017-12604 -* CVE-2017-12605 -* CVE-2017-12606 -* CVE-2017-12862 -* CVE-2017-12863 -* CVE-2017-12864 - -Signed-off-by: Kai Kang ---- -From 78a310630fb0a1f6d089576202343e672f27609d Mon Sep 17 00:00:00 2001 -From: Alexander Alekhin -Date: Wed, 16 Aug 2017 13:53:12 +0300 -Subject: [PATCH 3/3] imgproc(test): add checks for remove() call - ---- - modules/imgcodecs/test/test_grfmt.cpp | 2 +- - modules/imgcodecs/test/test_jpeg.cpp | 12 ++++++------ - modules/imgcodecs/test/test_png.cpp | 2 +- - modules/imgcodecs/test/test_read_write.cpp | 4 ++-- - modules/imgcodecs/test/test_tiff.cpp | 8 ++++---- - modules/imgcodecs/test/test_webp.cpp | 6 +++--- - 6 files changed, 17 insertions(+), 17 deletions(-) - -diff --git a/modules/imgcodecs/test/test_grfmt.cpp b/modules/imgcodecs/test/test_grfmt.cpp -index 64a0c1e3a..74b72c3b3 100644 ---- a/modules/imgcodecs/test/test_grfmt.cpp -+++ b/modules/imgcodecs/test/test_grfmt.cpp -@@ -175,7 +175,7 @@ TEST_P(Imgcodecs_ExtSize, write_imageseq) - EXPECT_LT(n, 1.); - EXPECT_PRED_FORMAT2(cvtest::MatComparator(0, 0), img, img_gt); - } -- remove(filename.c_str()); -+ EXPECT_EQ(0, remove(filename.c_str())); - } - } - -diff --git a/modules/imgcodecs/test/test_jpeg.cpp b/modules/imgcodecs/test/test_jpeg.cpp -index 5546f2d91..6ddb02840 100644 ---- a/modules/imgcodecs/test/test_jpeg.cpp -+++ b/modules/imgcodecs/test/test_jpeg.cpp -@@ -123,8 +123,8 @@ TEST(Imgcodecs_Jpeg, encode_decode_progressive_jpeg) - - EXPECT_EQ(0, cvtest::norm(img_jpg_progressive, img_jpg_normal, NORM_INF)); - -- remove(output_progressive.c_str()); -- remove(output_normal.c_str()); -+ EXPECT_EQ(0, remove(output_progressive.c_str())); -+ EXPECT_EQ(0, remove(output_normal.c_str())); - } - - TEST(Imgcodecs_Jpeg, encode_decode_optimize_jpeg) -@@ -148,8 +148,8 @@ TEST(Imgcodecs_Jpeg, encode_decode_optimize_jpeg) - - EXPECT_EQ(0, cvtest::norm(img_jpg_optimized, img_jpg_normal, NORM_INF)); - -- remove(output_optimized.c_str()); -- remove(output_normal.c_str()); -+ EXPECT_EQ(0, remove(output_optimized.c_str())); -+ EXPECT_EQ(0, remove(output_normal.c_str())); - } - - TEST(Imgcodecs_Jpeg, encode_decode_rst_jpeg) -@@ -173,8 +173,8 @@ TEST(Imgcodecs_Jpeg, encode_decode_rst_jpeg) - - EXPECT_EQ(0, cvtest::norm(img_jpg_rst, img_jpg_normal, NORM_INF)); - -- remove(output_rst.c_str()); -- remove(output_normal.c_str()); -+ EXPECT_EQ(0, remove(output_rst.c_str())); -+ EXPECT_EQ(0, remove(output_normal.c_str())); - } - - #endif // HAVE_JPEG -diff --git a/modules/imgcodecs/test/test_png.cpp b/modules/imgcodecs/test/test_png.cpp -index c46f90119..4e97043e1 100644 ---- a/modules/imgcodecs/test/test_png.cpp -+++ b/modules/imgcodecs/test/test_png.cpp -@@ -17,7 +17,7 @@ TEST(Imgcodecs_Png, write_big) - EXPECT_EQ(13043, img.cols); - EXPECT_EQ(13917, img.rows); - ASSERT_NO_THROW(imwrite(dst_file, img)); -- remove(dst_file.c_str()); -+ EXPECT_EQ(0, remove(dst_file.c_str())); - } - - TEST(Imgcodecs_Png, encode) -diff --git a/modules/imgcodecs/test/test_read_write.cpp b/modules/imgcodecs/test/test_read_write.cpp -index 38f10225f..5119813bf 100644 ---- a/modules/imgcodecs/test/test_read_write.cpp -+++ b/modules/imgcodecs/test/test_read_write.cpp -@@ -50,7 +50,7 @@ TEST(Imgcodecs_Image, read_write_bmp) - psnr = cvtest::PSNR(buf_loaded, image); - EXPECT_GT(psnr, thresDbell); - -- remove(dst_name.c_str()); -+ EXPECT_EQ(0, remove(dst_name.c_str())); - } - } - -@@ -95,7 +95,7 @@ TEST_P(Imgcodecs_Image, read_write) - psnr = cvtest::PSNR(buf_loaded, image); - EXPECT_GT(psnr, thresDbell); - -- remove(full_name.c_str()); -+ EXPECT_EQ(0, remove(full_name.c_str())); - } - - const string exts[] = { -diff --git a/modules/imgcodecs/test/test_tiff.cpp b/modules/imgcodecs/test/test_tiff.cpp -index 0264da4cd..6ef0c1748 100644 ---- a/modules/imgcodecs/test/test_tiff.cpp -+++ b/modules/imgcodecs/test/test_tiff.cpp -@@ -41,8 +41,8 @@ TEST(Imgcodecs_Tiff, decode_tile16384x16384) - // not enough memory - } - -- remove(file3.c_str()); -- remove(file4.c_str()); -+ EXPECT_EQ(0, remove(file3.c_str())); -+ EXPECT_EQ(0, remove(file4.c_str())); - } - - TEST(Imgcodecs_Tiff, write_read_16bit_big_little_endian) -@@ -88,7 +88,7 @@ TEST(Imgcodecs_Tiff, write_read_16bit_big_little_endian) - EXPECT_EQ(0xDEAD, img.at(0,0)); - EXPECT_EQ(0xBEEF, img.at(0,1)); - -- remove(filename.c_str()); -+ EXPECT_EQ(0, remove(filename.c_str())); - } - } - -@@ -143,7 +143,7 @@ TEST(Imgcodecs_Tiff, decode_infinite_rowsperstrip) - - EXPECT_NO_THROW(cv::imread(filename, IMREAD_UNCHANGED)); - -- remove(filename.c_str()); -+ EXPECT_EQ(0, remove(filename.c_str())); - } - - //================================================================================================== -diff --git a/modules/imgcodecs/test/test_webp.cpp b/modules/imgcodecs/test/test_webp.cpp -index 6d40ce21e..d82fdd289 100644 ---- a/modules/imgcodecs/test/test_webp.cpp -+++ b/modules/imgcodecs/test/test_webp.cpp -@@ -44,7 +44,7 @@ TEST(Imgcodecs_WebP, encode_decode_lossless_webp) - } - } - -- remove(output.c_str()); -+ EXPECT_EQ(0, remove(output.c_str())); - - cv::Mat decode = cv::imdecode(buf, IMREAD_COLOR); - ASSERT_FALSE(decode.empty()); -@@ -71,7 +71,7 @@ TEST(Imgcodecs_WebP, encode_decode_lossy_webp) - - EXPECT_NO_THROW(cv::imwrite(output, img, params)); - cv::Mat img_webp = cv::imread(output); -- remove(output.c_str()); -+ EXPECT_EQ(0, remove(output.c_str())); - EXPECT_FALSE(img_webp.empty()); - EXPECT_EQ(3, img_webp.channels()); - EXPECT_EQ(512, img_webp.cols); -@@ -96,7 +96,7 @@ TEST(Imgcodecs_WebP, encode_decode_with_alpha_webp) - - EXPECT_NO_THROW(cv::imwrite(output, img)); - cv::Mat img_webp = cv::imread(output); -- remove(output.c_str()); -+ EXPECT_EQ(0, remove(output.c_str())); - EXPECT_FALSE(img_webp.empty()); - EXPECT_EQ(4, img_webp.channels()); - EXPECT_EQ(512, img_webp.cols); --- -2.14.1 - diff --git a/meta-oe/recipes-support/opencv/opencv/CVE-2017-14136.patch b/meta-oe/recipes-support/opencv/opencv/CVE-2017-14136.patch deleted file mode 100644 index 7ad50a2d2f..0000000000 --- a/meta-oe/recipes-support/opencv/opencv/CVE-2017-14136.patch +++ /dev/null @@ -1,288 +0,0 @@ -Upstream-Status: Backport [https://github.com/opencv/opencv/pull/9448/commits/aacae20] - -Backport patch to fix CVE-2017-14136. - -Ref: https://github.com/opencv/opencv/issues/9443 - -Signed-off-by: Kai Kang ---- -From aacae2065744adb05e858d327198c7bbe7f452b0 Mon Sep 17 00:00:00 2001 -From: Alexander Alekhin -Date: Wed, 23 Aug 2017 15:15:27 +0300 -Subject: [PATCH] imgcodesc: fix code problems with integer overflow / address - arithmetic / UB - ---- - modules/imgcodecs/src/grfmt_bmp.cpp | 8 ++--- - modules/imgcodecs/src/grfmt_exr.cpp | 10 +++---- - modules/imgcodecs/src/grfmt_jpeg.cpp | 2 +- - modules/imgcodecs/src/grfmt_jpeg2000.cpp | 6 ++-- - modules/imgcodecs/src/grfmt_pam.cpp | 2 +- - modules/imgcodecs/src/grfmt_sunras.cpp | 6 ++-- - modules/imgcodecs/src/utils.cpp | 51 +++++++++++++++++++------------- - modules/imgcodecs/src/utils.hpp | 2 ++ - 8 files changed, 50 insertions(+), 37 deletions(-) - -diff --git a/modules/imgcodecs/src/grfmt_bmp.cpp b/modules/imgcodecs/src/grfmt_bmp.cpp -index 257f97c2d8b..69768e276a3 100644 ---- a/modules/imgcodecs/src/grfmt_bmp.cpp -+++ b/modules/imgcodecs/src/grfmt_bmp.cpp -@@ -193,7 +193,7 @@ bool BmpDecoder::readHeader() - bool BmpDecoder::readData( Mat& img ) - { - uchar* data = img.ptr(); -- int step = (int)img.step; -+ int step = validateToInt(img.step); - bool color = img.channels() > 1; - uchar gray_palette[256] = {0}; - bool result = false; -@@ -206,7 +206,7 @@ bool BmpDecoder::readData( Mat& img ) - - if( m_origin == IPL_ORIGIN_BL ) - { -- data += (m_height - 1)*step; -+ data += (m_height - 1)*(size_t)step; - step = -step; - } - -@@ -530,7 +530,7 @@ bool BmpEncoder::write( const Mat& img, const std::vector& ) - int bitmapHeaderSize = 40; - int paletteSize = channels > 1 ? 0 : 1024; - int headerSize = 14 /* fileheader */ + bitmapHeaderSize + paletteSize; -- int fileSize = fileStep*height + headerSize; -+ size_t fileSize = (size_t)fileStep*height + headerSize; - PaletteEntry palette[256]; - - if( m_buf ) -@@ -540,7 +540,7 @@ bool BmpEncoder::write( const Mat& img, const std::vector& ) - strm.putBytes( fmtSignBmp, (int)strlen(fmtSignBmp) ); - - // write file header -- strm.putDWord( fileSize ); // file size -+ strm.putDWord( validateToInt(fileSize) ); // file size - strm.putDWord( 0 ); - strm.putDWord( headerSize ); - -diff --git a/modules/imgcodecs/src/grfmt_exr.cpp b/modules/imgcodecs/src/grfmt_exr.cpp -index 0d2ae9fa7d2..78ffe6c7668 100644 ---- a/modules/imgcodecs/src/grfmt_exr.cpp -+++ b/modules/imgcodecs/src/grfmt_exr.cpp -@@ -195,7 +195,7 @@ bool ExrDecoder::readData( Mat& img ) - bool color = img.channels() > 1; - - uchar* data = img.ptr(); -- int step = img.step; -+ size_t step = img.step; - bool justcopy = m_native_depth; - bool chromatorgb = false; - bool rgbtogray = false; -@@ -203,8 +203,8 @@ bool ExrDecoder::readData( Mat& img ) - FrameBuffer frame; - int xsample[3] = {1, 1, 1}; - char *buffer; -- int xstep; -- int ystep; -+ size_t xstep = 0; -+ size_t ystep = 0; - - xstep = m_native_depth ? 4 : 1; - -@@ -593,7 +593,7 @@ bool ExrEncoder::write( const Mat& img, const std::vector& ) - bool issigned = depth == CV_8S || depth == CV_16S || depth == CV_32S; - bool isfloat = depth == CV_32F || depth == CV_64F; - depth = CV_ELEM_SIZE1(depth)*8; -- const int step = img.step; -+ const size_t step = img.step; - - Header header( width, height ); - Imf::PixelType type; -@@ -623,7 +623,7 @@ bool ExrEncoder::write( const Mat& img, const std::vector& ) - FrameBuffer frame; - - char *buffer; -- int bufferstep; -+ size_t bufferstep; - int size; - if( type == FLOAT && depth == 32 ) - { -diff --git a/modules/imgcodecs/src/grfmt_jpeg.cpp b/modules/imgcodecs/src/grfmt_jpeg.cpp -index ce942ca1995..caf768d2569 100644 ---- a/modules/imgcodecs/src/grfmt_jpeg.cpp -+++ b/modules/imgcodecs/src/grfmt_jpeg.cpp -@@ -396,7 +396,7 @@ int my_jpeg_load_dht (struct jpeg_decompress_struct *info, unsigned char *dht, - bool JpegDecoder::readData( Mat& img ) - { - volatile bool result = false; -- int step = (int)img.step; -+ size_t step = img.step; - bool color = img.channels() > 1; - - if( m_state && m_width && m_height ) -diff --git a/modules/imgcodecs/src/grfmt_jpeg2000.cpp b/modules/imgcodecs/src/grfmt_jpeg2000.cpp -index 950ec21375f..24dfb38bb9d 100644 ---- a/modules/imgcodecs/src/grfmt_jpeg2000.cpp -+++ b/modules/imgcodecs/src/grfmt_jpeg2000.cpp -@@ -156,7 +156,7 @@ bool Jpeg2KDecoder::readData( Mat& img ) - bool result = false; - int color = img.channels() > 1; - uchar* data = img.ptr(); -- int step = (int)img.step; -+ size_t step = img.step; - jas_stream_t* stream = (jas_stream_t*)m_stream; - jas_image_t* image = (jas_image_t*)m_image; - -@@ -252,9 +252,9 @@ bool Jpeg2KDecoder::readData( Mat& img ) - if( !jas_image_readcmpt( image, cmptlut[i], 0, 0, xend / xstep, yend / ystep, buffer )) - { - if( img.depth() == CV_8U ) -- result = readComponent8u( data + i, buffer, step, cmptlut[i], maxval, offset, ncmpts ); -+ result = readComponent8u( data + i, buffer, validateToInt(step), cmptlut[i], maxval, offset, ncmpts ); - else -- result = readComponent16u( ((unsigned short *)data) + i, buffer, step / 2, cmptlut[i], maxval, offset, ncmpts ); -+ result = readComponent16u( ((unsigned short *)data) + i, buffer, validateToInt(step / 2), cmptlut[i], maxval, offset, ncmpts ); - if( !result ) - { - i = ncmpts; -diff --git a/modules/imgcodecs/src/grfmt_pam.cpp b/modules/imgcodecs/src/grfmt_pam.cpp -index 11195dc342c..8eb9e012309 100644 ---- a/modules/imgcodecs/src/grfmt_pam.cpp -+++ b/modules/imgcodecs/src/grfmt_pam.cpp -@@ -479,7 +479,7 @@ bool PAMDecoder::readData( Mat& img ) - { - uchar* data = img.ptr(); - int target_channels = img.channels(); -- int imp_stride = (int)img.step; -+ size_t imp_stride = img.step; - int sample_depth = CV_ELEM_SIZE1(m_type); - int src_elems_per_row = m_width*m_channels; - int src_stride = src_elems_per_row*sample_depth; -diff --git a/modules/imgcodecs/src/grfmt_sunras.cpp b/modules/imgcodecs/src/grfmt_sunras.cpp -index aca9b369318..6d448f94ed3 100644 ---- a/modules/imgcodecs/src/grfmt_sunras.cpp -+++ b/modules/imgcodecs/src/grfmt_sunras.cpp -@@ -160,7 +160,7 @@ bool SunRasterDecoder::readData( Mat& img ) - { - int color = img.channels() > 1; - uchar* data = img.ptr(); -- int step = (int)img.step; -+ size_t step = img.step; - uchar gray_palette[256] = {0}; - bool result = false; - int src_pitch = ((m_width*m_bpp + 7)/8 + 1) & -2; -@@ -308,11 +308,11 @@ bool SunRasterDecoder::readData( Mat& img ) - code = m_strm.getByte(); - - if( color ) -- data = FillUniColor( data, line_end, step, width3, -+ data = FillUniColor( data, line_end, validateToInt(step), width3, - y, m_height, len, - m_palette[code] ); - else -- data = FillUniGray( data, line_end, step, width3, -+ data = FillUniGray( data, line_end, validateToInt(step), width3, - y, m_height, len, - gray_palette[code] ); - if( y >= m_height ) -diff --git a/modules/imgcodecs/src/utils.cpp b/modules/imgcodecs/src/utils.cpp -index 2ee5bafc712..474dae008ca 100644 ---- a/modules/imgcodecs/src/utils.cpp -+++ b/modules/imgcodecs/src/utils.cpp -@@ -42,6 +42,13 @@ - #include "precomp.hpp" - #include "utils.hpp" - -+int validateToInt(size_t sz) -+{ -+ int valueInt = (int)sz; -+ CV_Assert((size_t)valueInt == sz); -+ return valueInt; -+} -+ - #define SCALE 14 - #define cR (int)(0.299*(1 << SCALE) + 0.5) - #define cG (int)(0.587*(1 << SCALE) + 0.5) -@@ -537,23 +544,25 @@ uchar* FillColorRow1( uchar* data, uchar* indices, int len, PaletteEntry* palett - { - uchar* end = data + len*3; - -+ const PaletteEntry p0 = palette[0], p1 = palette[1]; -+ - while( (data += 24) < end ) - { - int idx = *indices++; -- *((PaletteEntry*)(data - 24)) = palette[(idx & 128) != 0]; -- *((PaletteEntry*)(data - 21)) = palette[(idx & 64) != 0]; -- *((PaletteEntry*)(data - 18)) = palette[(idx & 32) != 0]; -- *((PaletteEntry*)(data - 15)) = palette[(idx & 16) != 0]; -- *((PaletteEntry*)(data - 12)) = palette[(idx & 8) != 0]; -- *((PaletteEntry*)(data - 9)) = palette[(idx & 4) != 0]; -- *((PaletteEntry*)(data - 6)) = palette[(idx & 2) != 0]; -- *((PaletteEntry*)(data - 3)) = palette[(idx & 1) != 0]; -+ *((PaletteEntry*)(data - 24)) = (idx & 128) ? p1 : p0; -+ *((PaletteEntry*)(data - 21)) = (idx & 64) ? p1 : p0; -+ *((PaletteEntry*)(data - 18)) = (idx & 32) ? p1 : p0; -+ *((PaletteEntry*)(data - 15)) = (idx & 16) ? p1 : p0; -+ *((PaletteEntry*)(data - 12)) = (idx & 8) ? p1 : p0; -+ *((PaletteEntry*)(data - 9)) = (idx & 4) ? p1 : p0; -+ *((PaletteEntry*)(data - 6)) = (idx & 2) ? p1 : p0; -+ *((PaletteEntry*)(data - 3)) = (idx & 1) ? p1 : p0; - } - -- int idx = indices[0] << 24; -+ int idx = indices[0]; - for( data -= 24; data < end; data += 3, idx += idx ) - { -- PaletteEntry clr = palette[idx < 0]; -+ const PaletteEntry clr = (idx & 128) ? p1 : p0; - WRITE_PIX( data, clr ); - } - -@@ -565,23 +574,25 @@ uchar* FillGrayRow1( uchar* data, uchar* indices, int len, uchar* palette ) - { - uchar* end = data + len; - -+ const uchar p0 = palette[0], p1 = palette[1]; -+ - while( (data += 8) < end ) - { - int idx = *indices++; -- *((uchar*)(data - 8)) = palette[(idx & 128) != 0]; -- *((uchar*)(data - 7)) = palette[(idx & 64) != 0]; -- *((uchar*)(data - 6)) = palette[(idx & 32) != 0]; -- *((uchar*)(data - 5)) = palette[(idx & 16) != 0]; -- *((uchar*)(data - 4)) = palette[(idx & 8) != 0]; -- *((uchar*)(data - 3)) = palette[(idx & 4) != 0]; -- *((uchar*)(data - 2)) = palette[(idx & 2) != 0]; -- *((uchar*)(data - 1)) = palette[(idx & 1) != 0]; -+ *((uchar*)(data - 8)) = (idx & 128) ? p1 : p0; -+ *((uchar*)(data - 7)) = (idx & 64) ? p1 : p0; -+ *((uchar*)(data - 6)) = (idx & 32) ? p1 : p0; -+ *((uchar*)(data - 5)) = (idx & 16) ? p1 : p0; -+ *((uchar*)(data - 4)) = (idx & 8) ? p1 : p0; -+ *((uchar*)(data - 3)) = (idx & 4) ? p1 : p0; -+ *((uchar*)(data - 2)) = (idx & 2) ? p1 : p0; -+ *((uchar*)(data - 1)) = (idx & 1) ? p1 : p0; - } - -- int idx = indices[0] << 24; -+ int idx = indices[0]; - for( data -= 8; data < end; data++, idx += idx ) - { -- data[0] = palette[idx < 0]; -+ data[0] = (idx & 128) ? p1 : p0; - } - - return data; -diff --git a/modules/imgcodecs/src/utils.hpp b/modules/imgcodecs/src/utils.hpp -index cab10609db2..7af4c6174ee 100644 ---- a/modules/imgcodecs/src/utils.hpp -+++ b/modules/imgcodecs/src/utils.hpp -@@ -42,6 +42,8 @@ - #ifndef _UTILS_H_ - #define _UTILS_H_ - -+int validateToInt(size_t step); -+ - struct PaletteEntry - { - unsigned char b, g, r, a; diff --git a/meta-oe/recipes-support/opencv/opencv/already-exists.patch b/meta-oe/recipes-support/opencv/opencv/already-exists.patch deleted file mode 100644 index 6e24f2de87..0000000000 --- a/meta-oe/recipes-support/opencv/opencv/already-exists.patch +++ /dev/null @@ -1,394 +0,0 @@ -From e4bf148cddf277834e57c9afeec8daff8378a655 Mon Sep 17 00:00:00 2001 -From: Ricardo Ribalda Delgado -Date: Wed, 22 Nov 2017 15:27:07 +0100 -Subject: [PATCH] Fix: File already exists in database: caffe.proto - -Fixes error when importing python cv - -Upstream-status: Backport https://github.com/opencv/opencv/pull/10092 -Signed-off-by: Ricardo Ribalda Delgado ---- - modules/dnn/CMakeLists.txt | 6 +++--- - modules/dnn/src/caffe/caffe_importer.cpp | 1 - - modules/dnn/src/caffe/caffe_io.cpp | 1 - - modules/dnn/src/caffe/caffe_io.hpp | 2 +- - modules/dnn/src/caffe/{caffe.proto => opencv-caffe.proto} | 0 - 5 files changed, 4 insertions(+), 6 deletions(-) - rename modules/dnn/src/caffe/{caffe.proto => opencv-caffe.proto} (100%) - -diff --git a/modules/dnn/CMakeLists.txt b/modules/dnn/CMakeLists.txt -index c6329a742263..8ef00ef983ff 100644 ---- a/modules/dnn/CMakeLists.txt -+++ b/modules/dnn/CMakeLists.txt -@@ -55,13 +55,13 @@ ocv_warnings_disable(CMAKE_CXX_FLAGS - - if(PROTOBUF_UPDATE_FILES) - file(GLOB proto_files src/tensorflow/*.proto) -- list(APPEND proto_files src/caffe/caffe.proto) -+ list(APPEND proto_files src/caffe/opencv-caffe.proto) - PROTOBUF_GENERATE_CPP(Protobuf_HDRS Protobuf_SRCS ${proto_files}) - else() - file(GLOB fw_srcs ${CMAKE_CURRENT_SOURCE_DIR}/misc/tensorflow/*.cc) - file(GLOB fw_hdrs ${CMAKE_CURRENT_SOURCE_DIR}/misc/tensorflow/*.h) -- list(APPEND fw_srcs ${CMAKE_CURRENT_SOURCE_DIR}/misc/caffe/caffe.pb.cc) -- list(APPEND fw_hdrs ${CMAKE_CURRENT_SOURCE_DIR}/misc/caffe/caffe.pb.h) -+ list(APPEND fw_srcs ${CMAKE_CURRENT_SOURCE_DIR}/misc/caffe/opencv-caffe.pb.cc) -+ list(APPEND fw_hdrs ${CMAKE_CURRENT_SOURCE_DIR}/misc/caffe/opencv-caffe.pb.h) - list(APPEND Protobuf_SRCS ${fw_srcs}) - list(APPEND Protobuf_HDRS ${fw_hdrs}) - list(APPEND Protobuf_INCLUDE_DIRS ${CMAKE_CURRENT_SOURCE_DIR}/misc/caffe) -diff --git a/modules/dnn/src/caffe/caffe_importer.cpp b/modules/dnn/src/caffe/caffe_importer.cpp -index c075651b95b3..2c977c84b0f4 100644 ---- a/modules/dnn/src/caffe/caffe_importer.cpp -+++ b/modules/dnn/src/caffe/caffe_importer.cpp -@@ -42,7 +42,6 @@ - #include "../precomp.hpp" - - #ifdef HAVE_PROTOBUF --#include "caffe.pb.h" - - #include - #include -diff --git a/modules/dnn/src/caffe/caffe_io.cpp b/modules/dnn/src/caffe/caffe_io.cpp -index 0f46ea77df9a..1d3c518f1328 100644 ---- a/modules/dnn/src/caffe/caffe_io.cpp -+++ b/modules/dnn/src/caffe/caffe_io.cpp -@@ -99,7 +99,6 @@ - #include - #include - --#include "caffe.pb.h" - #include "caffe_io.hpp" - #include "glog_emulator.hpp" - -diff --git a/modules/dnn/src/caffe/caffe_io.hpp b/modules/dnn/src/caffe/caffe_io.hpp -index 09bc5709a24e..f5912c3bcec1 100644 ---- a/modules/dnn/src/caffe/caffe_io.hpp -+++ b/modules/dnn/src/caffe/caffe_io.hpp -@@ -91,7 +91,7 @@ - #define __OPENCV_DNN_CAFFE_IO_HPP__ - #ifdef HAVE_PROTOBUF - --#include "caffe.pb.h" -+#include "opencv-caffe.pb.h" - - namespace cv { - namespace dnn { -diff --git a/modules/dnn/src/caffe/caffe.proto b/modules/dnn/src/caffe/opencv-caffe.proto -similarity index 100% -rename from modules/dnn/src/caffe/caffe.proto -rename to modules/dnn/src/caffe/opencv-caffe.proto -diff --git a/modules/dnn/src/layers/detection_output_layer.cpp b/modules/dnn/src/layers/detection_output_layer.cpp -index 0b72326f7e7d..f413bad5b81a 100644 ---- a/modules/dnn/src/layers/detection_output_layer.cpp -+++ b/modules/dnn/src/layers/detection_output_layer.cpp -@@ -44,7 +44,7 @@ - #include "layers_common.hpp" - #include - #include --#include -+#include - - namespace cv - { -diff --git a/modules/dnn/src/caffe/caffe_importer.cpp b/modules/dnn/src/caffe/caffe_importer.cpp -index 2c977c84b0f4..a1827a381117 100644 ---- a/modules/dnn/src/caffe/caffe_importer.cpp -+++ b/modules/dnn/src/caffe/caffe_importer.cpp -@@ -78,8 +78,8 @@ static cv::String toString(const T &v) - - class CaffeImporter : public Importer - { -- caffe::NetParameter net; -- caffe::NetParameter netBinary; -+ opencvcaffe::NetParameter net; -+ opencvcaffe::NetParameter netBinary; - - public: - -@@ -197,7 +197,7 @@ public: - } - } - -- void blobShapeFromProto(const caffe::BlobProto &pbBlob, MatShape& shape) -+ void blobShapeFromProto(const opencvcaffe::BlobProto &pbBlob, MatShape& shape) - { - shape.clear(); - if (pbBlob.has_num() || pbBlob.has_channels() || pbBlob.has_height() || pbBlob.has_width()) -@@ -209,7 +209,7 @@ public: - } - else if (pbBlob.has_shape()) - { -- const caffe::BlobShape &_shape = pbBlob.shape(); -+ const opencvcaffe::BlobShape &_shape = pbBlob.shape(); - - for (int i = 0; i < _shape.dim_size(); i++) - shape.push_back((int)_shape.dim(i)); -@@ -218,7 +218,7 @@ public: - CV_Error(Error::StsError, "Unknown shape of input blob"); - } - -- void blobFromProto(const caffe::BlobProto &pbBlob, cv::Mat &dstBlob) -+ void blobFromProto(const opencvcaffe::BlobProto &pbBlob, cv::Mat &dstBlob) - { - MatShape shape; - blobShapeFromProto(pbBlob, shape); -@@ -233,7 +233,7 @@ public: - dstData[i] = pbBlob.data(i); - } - -- void extractBinaryLayerParms(const caffe::LayerParameter& layer, LayerParams& layerParams) -+ void extractBinaryLayerParms(const opencvcaffe::LayerParameter& layer, LayerParams& layerParams) - { - const std::string &name = layer.name(); - -@@ -247,7 +247,7 @@ public: - if (li == netBinary.layer_size() || netBinary.layer(li).blobs_size() == 0) - return; - -- const caffe::LayerParameter &binLayer = netBinary.layer(li); -+ const opencvcaffe::LayerParameter &binLayer = netBinary.layer(li); - layerParams.blobs.resize(binLayer.blobs_size()); - for (int bi = 0; bi < binLayer.blobs_size(); bi++) - { -@@ -289,7 +289,7 @@ public: - - for (int li = 0; li < layersSize; li++) - { -- const caffe::LayerParameter &layer = net.layer(li); -+ const opencvcaffe::LayerParameter &layer = net.layer(li); - String name = layer.name(); - String type = layer.type(); - LayerParams layerParams; -@@ -313,7 +313,7 @@ public: - addedBlobs.clear(); - } - -- void addOutput(const caffe::LayerParameter &layer, int layerId, int outNum) -+ void addOutput(const opencvcaffe::LayerParameter &layer, int layerId, int outNum) - { - const std::string &name = layer.top(outNum); - -diff --git a/modules/dnn/src/caffe/caffe_io.hpp b/modules/dnn/src/caffe/caffe_io.hpp -index f5912c3bcec1..24cd5fa254eb 100644 ---- a/modules/dnn/src/caffe/caffe_io.hpp -+++ b/modules/dnn/src/caffe/caffe_io.hpp -@@ -98,9 +98,9 @@ namespace dnn { - - // Read parameters from a file into a NetParameter proto message. - void ReadNetParamsFromTextFileOrDie(const char* param_file, -- caffe::NetParameter* param); -+ opencvcaffe::NetParameter* param); - void ReadNetParamsFromBinaryFileOrDie(const char* param_file, -- caffe::NetParameter* param); -+ opencvcaffe::NetParameter* param); - - } - } -diff --git a/modules/dnn/src/caffe/opencv-caffe.proto b/modules/dnn/src/caffe/opencv-caffe.proto -index 3d23fb48ea6a..df4e1d3269ae 100644 ---- a/modules/dnn/src/caffe/opencv-caffe.proto -+++ b/modules/dnn/src/caffe/opencv-caffe.proto -@@ -48,7 +48,7 @@ - - syntax = "proto2"; - --package caffe; -+package opencvcaffe; - - // Specifies the shape (dimensions) of a Blob. - message BlobShape { -diff --git a/modules/dnn/src/layers/detection_output_layer.cpp b/modules/dnn/src/layers/detection_output_layer.cpp -index f413bad5b81a..832c257eebf9 100644 ---- a/modules/dnn/src/layers/detection_output_layer.cpp -+++ b/modules/dnn/src/layers/detection_output_layer.cpp -@@ -72,7 +72,7 @@ public: - - int _backgroundLabelId; - -- typedef caffe::PriorBoxParameter_CodeType CodeType; -+ typedef opencvcaffe::PriorBoxParameter_CodeType CodeType; - CodeType _codeType; - - bool _varianceEncodedInTarget; -@@ -85,7 +85,7 @@ public: - enum { _numAxes = 4 }; - static const std::string _layerName; - -- typedef std::map > LabelBBox; -+ typedef std::map > LabelBBox; - - bool getParameterDict(const LayerParams ¶ms, - const std::string ¶meterName, -@@ -131,11 +131,11 @@ public: - { - String codeTypeString = params.get("code_type").toLowerCase(); - if (codeTypeString == "corner") -- _codeType = caffe::PriorBoxParameter_CodeType_CORNER; -+ _codeType = opencvcaffe::PriorBoxParameter_CodeType_CORNER; - else if (codeTypeString == "center_size") -- _codeType = caffe::PriorBoxParameter_CodeType_CENTER_SIZE; -+ _codeType = opencvcaffe::PriorBoxParameter_CodeType_CENTER_SIZE; - else -- _codeType = caffe::PriorBoxParameter_CodeType_CORNER; -+ _codeType = opencvcaffe::PriorBoxParameter_CodeType_CORNER; - } - - DetectionOutputLayerImpl(const LayerParams ¶ms) -@@ -215,7 +215,7 @@ public: - GetConfidenceScores(confidenceData, num, numPriors, _numClasses, allConfidenceScores); - - // Retrieve all prior bboxes -- std::vector priorBBoxes; -+ std::vector priorBBoxes; - std::vector > priorVariances; - GetPriorBBoxes(priorData, numPriors, priorBBoxes, priorVariances); - -@@ -272,7 +272,7 @@ public: - for (size_t j = 0; j < indices.size(); ++j, ++count) - { - int idx = indices[j]; -- const caffe::NormalizedBBox& decode_bbox = label_bboxes->second[idx]; -+ const opencvcaffe::NormalizedBBox& decode_bbox = label_bboxes->second[idx]; - outputsData[count * 7] = i; - outputsData[count * 7 + 1] = label; - outputsData[count * 7 + 2] = scores[idx]; -@@ -355,7 +355,7 @@ public: - - // Compute bbox size - template -- static float BBoxSize(const caffe::NormalizedBBox& bbox) -+ static float BBoxSize(const opencvcaffe::NormalizedBBox& bbox) - { - if (bbox.xmax() < bbox.xmin() || bbox.ymax() < bbox.ymin()) - { -@@ -388,10 +388,10 @@ public: - // Decode a bbox according to a prior bbox - template - static void DecodeBBox( -- const caffe::NormalizedBBox& prior_bbox, const std::vector& prior_variance, -+ const opencvcaffe::NormalizedBBox& prior_bbox, const std::vector& prior_variance, - const CodeType code_type, -- const bool clip_bbox, const caffe::NormalizedBBox& bbox, -- caffe::NormalizedBBox& decode_bbox) -+ const bool clip_bbox, const opencvcaffe::NormalizedBBox& bbox, -+ opencvcaffe::NormalizedBBox& decode_bbox) - { - float bbox_xmin = variance_encoded_in_target ? bbox.xmin() : prior_variance[0] * bbox.xmin(); - float bbox_ymin = variance_encoded_in_target ? bbox.ymin() : prior_variance[1] * bbox.ymin(); -@@ -399,13 +399,13 @@ public: - float bbox_ymax = variance_encoded_in_target ? bbox.ymax() : prior_variance[3] * bbox.ymax(); - switch(code_type) - { -- case caffe::PriorBoxParameter_CodeType_CORNER: -+ case opencvcaffe::PriorBoxParameter_CodeType_CORNER: - decode_bbox.set_xmin(prior_bbox.xmin() + bbox_xmin); - decode_bbox.set_ymin(prior_bbox.ymin() + bbox_ymin); - decode_bbox.set_xmax(prior_bbox.xmax() + bbox_xmax); - decode_bbox.set_ymax(prior_bbox.ymax() + bbox_ymax); - break; -- case caffe::PriorBoxParameter_CodeType_CENTER_SIZE: -+ case opencvcaffe::PriorBoxParameter_CodeType_CENTER_SIZE: - { - float prior_width = prior_bbox.xmax() - prior_bbox.xmin(); - CV_Assert(prior_width > 0); -@@ -431,7 +431,7 @@ public: - }; - if (clip_bbox) - { -- // Clip the caffe::NormalizedBBox such that the range for each corner is [0, 1] -+ // Clip the opencvcaffe::NormalizedBBox such that the range for each corner is [0, 1] - decode_bbox.set_xmin(std::max(std::min(decode_bbox.xmin(), 1.f), 0.f)); - decode_bbox.set_ymin(std::max(std::min(decode_bbox.ymin(), 1.f), 0.f)); - decode_bbox.set_xmax(std::max(std::min(decode_bbox.xmax(), 1.f), 0.f)); -@@ -443,11 +443,11 @@ public: - - // Decode a set of bboxes according to a set of prior bboxes - static void DecodeBBoxes( -- const std::vector& prior_bboxes, -+ const std::vector& prior_bboxes, - const std::vector >& prior_variances, - const CodeType code_type, const bool variance_encoded_in_target, -- const bool clip_bbox, const std::vector& bboxes, -- std::vector& decode_bboxes) -+ const bool clip_bbox, const std::vector& bboxes, -+ std::vector& decode_bboxes) - { - CV_Assert(prior_bboxes.size() == prior_variances.size()); - CV_Assert(prior_bboxes.size() == bboxes.size()); -@@ -470,7 +470,7 @@ public: - - // Decode all bboxes in a batch - static void DecodeBBoxesAll(const std::vector& all_loc_preds, -- const std::vector& prior_bboxes, -+ const std::vector& prior_bboxes, - const std::vector >& prior_variances, - const int num, const bool share_location, - const int num_loc_classes, const int background_label_id, -@@ -503,10 +503,10 @@ public: - // Get prior bounding boxes from prior_data - // prior_data: 1 x 2 x num_priors * 4 x 1 blob. - // num_priors: number of priors. -- // prior_bboxes: stores all the prior bboxes in the format of caffe::NormalizedBBox. -+ // prior_bboxes: stores all the prior bboxes in the format of opencvcaffe::NormalizedBBox. - // prior_variances: stores all the variances needed by prior bboxes. - static void GetPriorBBoxes(const float* priorData, const int& numPriors, -- std::vector& priorBBoxes, -+ std::vector& priorBBoxes, - std::vector >& priorVariances) - { - priorBBoxes.clear(); priorBBoxes.resize(numPriors); -@@ -514,7 +514,7 @@ public: - for (int i = 0; i < numPriors; ++i) - { - int startIdx = i * 4; -- caffe::NormalizedBBox& bbox = priorBBoxes[i]; -+ opencvcaffe::NormalizedBBox& bbox = priorBBoxes[i]; - bbox.set_xmin(priorData[startIdx]); - bbox.set_ymin(priorData[startIdx + 1]); - bbox.set_xmax(priorData[startIdx + 2]); -@@ -565,7 +565,7 @@ public: - { - labelBBox[label].resize(numPredsPerClass); - } -- caffe::NormalizedBBox& bbox = labelBBox[label][p]; -+ opencvcaffe::NormalizedBBox& bbox = labelBBox[label][p]; - bbox.set_xmin(locData[startIdx + c * 4]); - bbox.set_ymin(locData[startIdx + c * 4 + 1]); - bbox.set_xmax(locData[startIdx + c * 4 + 2]); -@@ -612,7 +612,7 @@ public: - // nms_threshold: a threshold used in non maximum suppression. - // top_k: if not -1, keep at most top_k picked indices. - // indices: the kept indices of bboxes after nms. -- static void ApplyNMSFast(const std::vector& bboxes, -+ static void ApplyNMSFast(const std::vector& bboxes, - const std::vector& scores, const float score_threshold, - const float nms_threshold, const float eta, const int top_k, - std::vector& indices) -@@ -674,10 +674,10 @@ public: - - // Compute the jaccard (intersection over union IoU) overlap between two bboxes. - template -- static float JaccardOverlap(const caffe::NormalizedBBox& bbox1, -- const caffe::NormalizedBBox& bbox2) -+ static float JaccardOverlap(const opencvcaffe::NormalizedBBox& bbox1, -+ const opencvcaffe::NormalizedBBox& bbox2) - { -- caffe::NormalizedBBox intersect_bbox; -+ opencvcaffe::NormalizedBBox intersect_bbox; - if (bbox2.xmin() > bbox1.xmax() || bbox2.xmax() < bbox1.xmin() || - bbox2.ymin() > bbox1.ymax() || bbox2.ymax() < bbox1.ymin()) - { -diff --git a/modules/dnn/src/caffe/caffe_io.cpp b/modules/dnn/src/caffe/caffe_io.cpp -index 1d3c518f1328..3cf6e255aa60 100644 ---- a/modules/dnn/src/caffe/caffe_io.cpp -+++ b/modules/dnn/src/caffe/caffe_io.cpp -@@ -107,7 +107,7 @@ namespace dnn { - - using std::string; - using std::map; --using namespace caffe; -+using namespace opencvcaffe; - using namespace ::google::protobuf; - using namespace ::google::protobuf::io; - diff --git a/meta-oe/recipes-support/opencv/opencv/fixpkgconfig.patch b/meta-oe/recipes-support/opencv/opencv/fixpkgconfig.patch index 3aeda7d443..3ed3468d5c 100644 --- a/meta-oe/recipes-support/opencv/opencv/fixpkgconfig.patch +++ b/meta-oe/recipes-support/opencv/opencv/fixpkgconfig.patch @@ -1,24 +1,25 @@ -diff --git a/cmake/OpenCVGenPkgconfig.cmake b/cmake/OpenCVGenPkgconfig.cmake -index b8cb8777c06b..75281ee964fd 100644 ---- a/cmake/OpenCVGenPkgconfig.cmake -+++ b/cmake/OpenCVGenPkgconfig.cmake -@@ -27,7 +27,7 @@ macro(fix_prefix lst isown) +Index: git/cmake/OpenCVGenPkgconfig.cmake +=================================================================== +--- git.orig/cmake/OpenCVGenPkgconfig.cmake ++++ git/cmake/OpenCVGenPkgconfig.cmake +@@ -31,7 +31,7 @@ macro(fix_prefix lst isown) get_filename_component(libdir "${item}" PATH) - get_filename_component(libname "${item}" NAME_WE) - string(REGEX REPLACE "^lib(.*)" "\\1" libname "${libname}") + get_filename_component(_libname "${item}" NAME) + ocv_get_libname(libname "${_libname}") - list(APPEND _lst "-L${libdir}" "-l${libname}") + list(APPEND _lst "-l${libname}") else() list(APPEND _lst "-l${item}") endif() -@@ -66,10 +66,14 @@ ocv_list_unique(_3rdparty) +@@ -124,11 +124,14 @@ ocv_list_unique(_extra) + ocv_list_unique(_3rdparty) set(OPENCV_PC_LIBS - "-L\${exec_prefix}/${OPENCV_LIB_INSTALL_PATH}" +- "-L\${exec_prefix}/${OPENCV_LIB_INSTALL_PATH}" + "-L\${exec_prefix}/${OPENCV_3P_LIB_INSTALL_PATH}" "${_modules}" ) - if (BUILD_SHARED_LIBS) + if(BUILD_SHARED_LIBS) - set(OPENCV_PC_LIBS_PRIVATE "${_extra}") + set(OPENCV_PC_LIBS_PRIVATE + "-L\${exec_prefix}/${OPENCV_LIB_INSTALL_PATH}" diff --git a/meta-oe/recipes-support/opencv/opencv/javagen.patch b/meta-oe/recipes-support/opencv/opencv/javagen.patch deleted file mode 100644 index 56526ecd80..0000000000 --- a/meta-oe/recipes-support/opencv/opencv/javagen.patch +++ /dev/null @@ -1,16 +0,0 @@ -Upstream-status: Inappropriate [OE specific] https://github.com/opencv/opencv/pull/10039#issuecomment-342539288 - -Signed-off-by: Ricardo Ribalda -diff --git a/modules/java/CMakeLists.txt b/modules/java/CMakeLists.txt -index 74bc0ef04169..4622fbf9a5f1 100644 ---- a/modules/java/CMakeLists.txt -+++ b/modules/java/CMakeLists.txt -@@ -291,7 +291,7 @@ foreach(java_file ${step3_input_files}) - endif() - if(__configure) - configure_file("${java_file}" "${java_src_dir}/${output_name}" @ONLY) -- elseif(NOT "${java_file}" MATCHES "${OpenCV_BINARY_DIR}/") -+ elseif(EXISTS "${java_file}" AND NOT "${java_file}" MATCHES "${OpenCV_BINARY_DIR}/") - configure_file("${java_file}" "${java_src_dir}/${output_name}" COPYONLY) - else() - add_custom_command(OUTPUT "${java_src_dir}/${output_name}" diff --git a/meta-oe/recipes-support/opencv/opencv/protobuf.patch b/meta-oe/recipes-support/opencv/opencv/protobuf.patch deleted file mode 100644 index c63dc142ea..0000000000 --- a/meta-oe/recipes-support/opencv/opencv/protobuf.patch +++ /dev/null @@ -1,57 +0,0 @@ -Upstream-status: Inappropriate [OE specific] - -Signed-off-by: Ricardo Ribalda -diff --git a/cmake/OpenCVFindLibProtobuf.cmake b/cmake/OpenCVFindLibProtobuf.cmake -index b6ce1e7fd56b..e916ec0df2a6 100644 ---- a/cmake/OpenCVFindLibProtobuf.cmake -+++ b/cmake/OpenCVFindLibProtobuf.cmake -@@ -7,21 +7,21 @@ OCV_OPTION(BUILD_PROTOBUF "Force to build libprotobuf from sources" ON) - OCV_OPTION(PROTOBUF_UPDATE_FILES "Force to rebuild .proto files" OFF) - - if(PROTOBUF_UPDATE_FILES) -- if(NOT DEFINED Protobuf_PROTOC_EXECUTABLE) -+ if(NOT DEFINED PROTOBUF_PROTOC_EXECUTABLE) - find_package(Protobuf QUIET) - endif() -- if(DEFINED Protobuf_PROTOC_EXECUTABLE AND EXISTS ${Protobuf_PROTOC_EXECUTABLE}) -- message(STATUS "The protocol buffer compiler is found (${Protobuf_PROTOC_EXECUTABLE})") -+ if(DEFINED PROTOBUF_PROTOC_EXECUTABLE AND EXISTS ${PROTOBUF_PROTOC_EXECUTABLE}) -+ message(STATUS "The protocol buffer compiler is found (${PROTOBUF_PROTOC_EXECUTABLE})") - else() -- message(FATAL_ERROR "The protocol buffer compiler is not found (Protobuf_PROTOC_EXECUTABLE='${Protobuf_PROTOC_EXECUTABLE}')") -+ message(FATAL_ERROR "The protocol buffer compiler is not found (PROTOBUF_PROTOC_EXECUTABLE='${PROTOBUF_PROTOC_EXECUTABLE}')") - endif() - endif() - --if(NOT BUILD_PROTOBUF AND NOT (DEFINED Protobuf_INCLUDE_DIRS AND DEFINED Protobuf_LIBRARIES)) -+if(NOT BUILD_PROTOBUF AND NOT (DEFINED PROTOBUF_INCLUDE_DIR AND DEFINED PROTOBUF_LIBRARIES)) - find_package(Protobuf QUIET) - endif() - --if(Protobuf_FOUND) -+if(PROTOBUF_FOUND OR (DEFINED PROTOBUF_INCLUDE_DIR AND DEFINED PROTOBUF_LIBRARIES)) - # nothing - else() - set(Protobuf_LIBRARIES libprotobuf) -diff --git a/modules/dnn/CMakeLists.txt b/modules/dnn/CMakeLists.txt -index 2a71568d1a44..c6329a742263 100644 ---- a/modules/dnn/CMakeLists.txt -+++ b/modules/dnn/CMakeLists.txt -@@ -7,7 +7,7 @@ if(DEFINED BUILD_opencv_dnn AND NOT BUILD_opencv_dnn) - endif() - - include(${OpenCV_SOURCE_DIR}/cmake/OpenCVFindLibProtobuf.cmake) --if(NOT Protobuf_FOUND) -+if(NOT PROTOBUF_FOUND) - ocv_module_disable(opencv_dnn) - endif() - -@@ -72,7 +72,7 @@ ocv_source_group("Src\\protobuf" FILES ${Protobuf_SRCS} ${Protobuf_HDRS}) - ocv_module_include_directories(include ${Protobuf_INCLUDE_DIRS}) - - ocv_glob_module_sources(${Protobuf_SRCS} ${Protobuf_HDRS} ${CBLAS_H_PROXY_PATH}) --ocv_create_module(${Protobuf_LIBRARIES} ${LAPACK_LIBRARIES}) -+ocv_create_module(${PROTOBUF_LIBRARIES} ${LAPACK_LIBRARIES}) - ocv_add_samples() - ocv_add_accuracy_tests() - ocv_add_perf_tests() diff --git a/meta-oe/recipes-support/opencv/opencv/tinydnn.patch b/meta-oe/recipes-support/opencv/opencv/tinydnn.patch deleted file mode 100644 index c433fc312d..0000000000 --- a/meta-oe/recipes-support/opencv/opencv/tinydnn.patch +++ /dev/null @@ -1,34 +0,0 @@ -Upstream-status: Inappropriate [OE specific] - -Signed-off-by: Ricardo Ribalda -diff --git a/modules/dnn_modern/CMakeLists.txt b/modules/dnn_modern/CMakeLists.txt -index 79b64b12160b..ba06a0a163e4 100644 ---- a/modules/dnn_modern/CMakeLists.txt -+++ b/modules/dnn_modern/CMakeLists.txt -@@ -15,24 +15,8 @@ list(APPEND CMAKE_MODULE_PATH ${CMAKE_CURRENT_SOURCE_DIR}/cmake) - # MODULE REQUIREMENTS - # ---------------------------------------------------------------------------- - --set(TINY_DNN_CPP_PATH "${OpenCV_BINARY_DIR}/3rdparty/tinydnn") --set(TINY_DNN_CPP_ROOT "${TINY_DNN_CPP_PATH}/tiny-dnn-1.0.0a3") --ocv_download(FILENAME "v1.0.0a3.tar.gz" -- HASH "adb1c512e09ca2c7a6faef36f9c53e59" -- URL -- "${OPENCV_TINY_DNN_URL}" -- "$ENV{OPENCV_TINY_DNN_URL}" -- "https://github.com/tiny-dnn/tiny-dnn/archive/" -- DESTINATION_DIR "${TINY_DNN_CPP_PATH}" -- STATUS TINY_DNN_DOWNLOAD_SUCCESS -- ID "tiny-dnn" -- UNPACK RELATIVE_URL) -- --if(NOT TINY_DNN_DOWNLOAD_SUCCESS) -- message(STATUS "Failed to download tiny-dnn sources") --endif() -- --find_package(TinyDNN QUIET) -+set(TINYDNN_INCLUDE_DIRS "${OpenCV_SOURCE_DIR}/3rdparty/tinydnn/tiny-dnn-1.0.0a3") -+set(TinyDNN_FOUND TRUE) - - include(CheckCXXCompilerFlag) - CHECK_CXX_COMPILER_FLAG("-std=c++11" COMPILER_SUPPORTS_CXX11) diff --git a/meta-oe/recipes-support/opencv/opencv_3.3.bb b/meta-oe/recipes-support/opencv/opencv_3.4.3.bb similarity index 88% rename from meta-oe/recipes-support/opencv/opencv_3.3.bb rename to meta-oe/recipes-support/opencv/opencv_3.4.3.bb index b697f44d1e..5591481b7d 100644 --- a/meta-oe/recipes-support/opencv/opencv_3.3.bb +++ b/meta-oe/recipes-support/opencv/opencv_3.4.3.bb @@ -3,16 +3,16 @@ HOMEPAGE = "http://opencv.org/" SECTION = "libs" LICENSE = "BSD-3-Clause" -LIC_FILES_CHKSUM = "file://LICENSE;md5=2b2f8752cc5edf504d283107d033f544" +LIC_FILES_CHKSUM = "file://LICENSE;md5=62d89c5dcb0583609ea919c56be0ee76" ARM_INSTRUCTION_SET_armv4 = "arm" ARM_INSTRUCTION_SET_armv5 = "arm" DEPENDS = "libtool swig-native bzip2 zlib glib-2.0 libwebp" -SRCREV_opencv = "87c27a074db9f6d9d60513f351daa903606ca370" -SRCREV_contrib = "2a9d1b22ed76eb22fad1a5edf6faf4d05f207b13" -SRCREV_ipp = "a62e20676a60ee0ad6581e217fe7e4bada3b95db" +SRCREV_opencv = "b38c50b3d0c31e82294315ec44b54b7ef559ef12" +SRCREV_contrib = "1f6d6f06266e1ef336437ae5404bee1c65d42cda" +SRCREV_ipp = "bdb7bb85f34a8cb0d35e40a81f58da431aa1557a" SRCREV_boostdesc = "34e4206aef44d50e6bbcd0ab06354b52e7466d26" SRCREV_vgg = "fccf7cd6a4b12079f73bbfb21745f9babcd4eb1d" SRC_URI[tinydnn.md5sum] = "adb1c512e09ca2c7a6faef36f9c53e59" @@ -22,17 +22,17 @@ def ipp_filename(d): import re arch = d.getVar('TARGET_ARCH', True) if re.match("i.86$", arch): - return "ippicv_2017u2_lnx_ia32_20170418.tgz" + return "ippicv_2017u3_lnx_ia32_general_20180518.tgz" else: - return "ippicv_2017u2_lnx_intel64_20170418.tgz" + return "ippicv_2017u3_lnx_intel64_general_20180518.tgz" def ipp_md5sum(d): import re arch = d.getVar('TARGET_ARCH', True) if re.match("i.86$", arch): - return "f2cece00d802d4dea86df52ed095257e" + return "ea72de74dae3c604eb6348395366e78e" else: - return "808b791a6eac9ed78d32a7666804320e" + return "b7cc351267db2d34b9efa1cd22ff0572" IPP_FILENAME = "${@ipp_filename(d)}" IPP_MD5 = "${@ipp_md5sum(d)}" @@ -40,29 +40,18 @@ IPP_MD5 = "${@ipp_md5sum(d)}" SRCREV_FORMAT = "opencv_contrib_ipp_boostdesc_vgg" SRC_URI = "git://github.com/opencv/opencv.git;name=opencv \ git://github.com/opencv/opencv_contrib.git;destsuffix=contrib;name=contrib \ - git://github.com/opencv/opencv_3rdparty.git;branch=ippicv/master_20170418;destsuffix=ipp;name=ipp \ + git://github.com/opencv/opencv_3rdparty.git;branch=ippicv/master_20180518;destsuffix=ipp;name=ipp \ git://github.com/opencv/opencv_3rdparty.git;branch=contrib_xfeatures2d_boostdesc_20161012;destsuffix=boostdesc;name=boostdesc \ git://github.com/opencv/opencv_3rdparty.git;branch=contrib_xfeatures2d_vgg_20160317;destsuffix=vgg;name=vgg \ https://github.com/tiny-dnn/tiny-dnn/archive/v1.0.0a3.tar.gz;destsuffix=git/3rdparty/tinydnn/tiny-dnn-1.0.0a3;name=tinydnn;unpack=false \ file://0001-3rdparty-ippicv-Use-pre-downloaded-ipp.patch \ - file://fixpkgconfig.patch \ file://uselocalxfeatures.patch;patchdir=../contrib/ \ - file://tinydnn.patch;patchdir=../contrib/ \ file://0002-Make-opencv-ts-create-share-library-intead-of-static.patch \ file://0003-To-fix-errors-as-following.patch \ - file://0001-build-workaround-GCC-7.1.1-compilation-issue-with-sa.patch \ - file://0002-imgcodecs-refactoring-improve-code-quality.patch \ - file://0003-imgproc-test-add-checks-for-remove-call.patch \ - file://0001-Dont-use-isystem.patch \ - file://0001-carotene-don-t-use-__asm__-with-aarch64.patch \ - file://0002-Do-not-enable-asm-with-clang.patch \ - file://CVE-2017-14136.patch \ - file://javagen.patch \ - file://protobuf.patch \ - file://already-exists.patch \ + file://fixpkgconfig.patch \ file://0001-Temporarliy-work-around-deprecated-ffmpeg-RAW-functi.patch \ " -PV = "3.3+git${SRCPV}" +PV = "3.4.3+git${SRCPV}" S = "${WORKDIR}/git" @@ -77,6 +66,7 @@ addtask unpack_extra after do_unpack before do_patch EXTRA_OECMAKE = "-DOPENCV_EXTRA_MODULES_PATH=${WORKDIR}/contrib/modules \ -DWITH_1394=OFF \ + -DENABLE_PRECOMPILED_HEADERS=OFF \ -DCMAKE_SKIP_RPATH=ON \ -DOPENCV_ICV_HASH=${IPP_MD5} \ -DIPPROOT=${WORKDIR}/ippicv_lnx \ @@ -196,9 +186,4 @@ do_install_append() { mv ${D}/usr/lib/* ${D}/${libdir}/ rm -rf ${D}/usr/lib fi - - if ${@bb.utils.contains("PACKAGECONFIG", "samples", "true", "false", d)}; then - install -d ${D}${datadir}/OpenCV/samples/bin/ - cp -f bin/*-tutorial-* bin/*-example-* ${D}${datadir}/OpenCV/samples/bin/ - fi } From patchwork Mon Sep 10 05:06:26 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Khem Raj X-Patchwork-Id: 146274 Delivered-To: patch@linaro.org Received: by 2002:a2e:1648:0:0:0:0:0 with SMTP id 8-v6csp2078685ljw; Sun, 9 Sep 2018 22:08:06 -0700 (PDT) X-Google-Smtp-Source: ANB0VdaJYLrivfS4wcm6HMsWI+iBlddrtqS3g2ZS2Bzv2uKZkK7M0quEU9JQ23kuWJz+C6oQJS7i X-Received: by 2002:a17:902:47c2:: with SMTP id d2-v6mr20185729plh.317.1536556086520; Sun, 09 Sep 2018 22:08:06 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1536556086; cv=none; d=google.com; s=arc-20160816; b=depAVdNtOC9twCzV/LatUeKT4NNxa5op81wod9ZjQ9uv83+vA37v6HhzfE5cjzc2RF 3JJMLRHvLWnUaOg93Ak/FWV0QSLJj1YZUEKZNAkrWcmJ0eHyCQrlYUJmOwJDDxalVcbn tMEv79pnvVfpQ76mJU1sCk/iTbDgL7M9YfwslO8Uo/k60EOU58CA8yvA7jLP73KzjRRr L4668Una7gyDC4co/DQMmlliB2JBOyTziIpb2cxyscwVVMj0M3CWXM2qNhpTJ65a4AV/ pIIMD/6WWK7UsX6qer8F1yfQFCNein9qmE2Vk6t6jFbLwY2dxTLmlBx7YmjyoGXNbxPg hc2Q== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=errors-to:sender:content-transfer-encoding:mime-version :list-subscribe:list-help:list-post:list-archive:list-unsubscribe :list-id:precedence:subject:references:in-reply-to:message-id:date :to:from:dkim-signature:delivered-to; bh=nbQCLJYjqlXXcOeSfDE2rHU+2R7wArZYP4D9L3Mx25E=; b=Q47jxOs4cD+Q8hAD7RdGxaxi3MZ4emmvVAV34qOEGSQKRA5Hqn/KTigNFDyUiTsy+U bI/dnPAk0yW65eFGfXtD77gB/f/LzzIql+s6tN6rnjfKfTPNVTRzowU1dZnSD26DzMYw c/iaQaMQ5boSbazntjH4/MBTWSbR4JJ9CSPhGLaKi5EoWzoMapqbjCUXF/c2WJP21Wcp uja5FzcnisXBM3mGF7p2M5z8wecX9cKLbHb33L956Tg2jGL/tLaoFbhslE57Vh98p6Wy aU0945TlC7KcjxfrZ9t01XHlVThk/+pwG+4syk5eSFu9oWYeAWlREwXwYdC14pFVCATu dhig== ARC-Authentication-Results: i=1; mx.google.com; dkim=neutral (body hash did not verify) header.i=@gmail.com header.s=20161025 header.b=ojQoQcKX; 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 b5-v6si15200533ple.241.2018.09.09.22.08.06; Sun, 09 Sep 2018 22:08:06 -0700 (PDT) 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=ojQoQcKX; 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 layers.openembedded.org (localhost [127.0.0.1]) by mail.openembedded.org (Postfix) with ESMTP id 5171379731; Mon, 10 Sep 2018 05:07:44 +0000 (UTC) X-Original-To: openembedded-devel@lists.openembedded.org Delivered-To: openembedded-devel@lists.openembedded.org Received: from mail-pf1-f196.google.com (mail-pf1-f196.google.com [209.85.210.196]) by mail.openembedded.org (Postfix) with ESMTP id E6FE97951E for ; Mon, 10 Sep 2018 05:06:43 +0000 (UTC) Received: by mail-pf1-f196.google.com with SMTP id u24-v6so9818683pfn.13 for ; Sun, 09 Sep 2018 22:06:45 -0700 (PDT) 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; bh=78X99agxSlACH3uBg/FhjLlBpjg5Be63hEH368BdioQ=; b=ojQoQcKXhW5qt1b93gTOSFVuf8J3I90LBJRwNBO/vwIUFE9Ni6sT6RX71ekJJVKtPp eeB5xLMp1ONSRHLbXP7yr/MHzF5MSzRsav2wbtp/dPSwKBcI6XJ6pXRjG9JOrr5vf78s dG1vXYoesLIftsvfgT/jxVjjXL1HG97U4tLUa1E5Hc7Xyj0LQj6xw0BvGnnohLqokhvk t46NW61MaqCtNOvRIxpTgkXamtwGAqy8o/KJgu0teVKLx6VgUEI6hIbz/9UEvC9zvlyE Jy2pYuiFb7b4fts12eUtIBWf1KIU4VO47UpVXhNtwqHPn7Af3+YMowHFPsVNTl16Fihj VMlA== 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=78X99agxSlACH3uBg/FhjLlBpjg5Be63hEH368BdioQ=; b=f/D+cXXySAn9pX8SCwlFtm7fRTQG3NCS6niaMzRymsD3z5LldpNTY8JMA6xdEKSC9w 4/lNbVc5Ep5m8S2jyJ8OEaviBmfY0SNHuclcEPkIxxJAlVNLJPjKLSWnotPTSbWO5Vx6 rTGfter1jeAIYW1n6sQKlGS+01gEQughSYIE/hlAljxVpWrF14O/hYrNeCulHjoxqTnf ZJEsly6F3BhNeODEdMARszwTRjAy7OOPql09ETiQBLq0I/bvPDpWhVkpIxAqAN23zTob w+3e9feM33paEr+lbmPDX+tvW0wljj6cpdrhOf/PIFOWwgk4LaL7Zkr+pi1PYyOtVpPh YkFA== X-Gm-Message-State: APzg51COVGPgAfM3WhOXNvjvd2fbtj0kiEvGu2B6+BgKOL/8+BtAmBYz 087zg69Jiq/Uaqbg+FU7dQEu0sq6 X-Received: by 2002:a63:eb0e:: with SMTP id t14-v6mr20652473pgh.198.1536556004382; Sun, 09 Sep 2018 22:06:44 -0700 (PDT) Received: from localhost.localdomain ([2601:646:877f:9499::2887]) by smtp.gmail.com with ESMTPSA id x24-v6sm18819188pfh.67.2018.09.09.22.06.43 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Sun, 09 Sep 2018 22:06:43 -0700 (PDT) From: Khem Raj To: openembedded-devel@lists.openembedded.org Date: Sun, 9 Sep 2018 22:06:26 -0700 Message-Id: <20180910050629.16170-7-raj.khem@gmail.com> X-Mailer: git-send-email 2.18.0 In-Reply-To: <20180910050629.16170-1-raj.khem@gmail.com> References: <20180910050629.16170-1-raj.khem@gmail.com> Subject: [oe] [meta-oe][PATCH V2 07/10] wvstreams: Add openssl 1.1.x support 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: , MIME-Version: 1.0 Sender: openembedded-devel-bounces@lists.openembedded.org Errors-To: openembedded-devel-bounces@lists.openembedded.org * Backport a pull request to support OpenSSL 1.1.x Signed-off-by: Khem Raj --- V2: Fix build with openssl 1.1.x .../0001-Forward-port-to-OpenSSL-1.1.x.patch | 557 ++++++++++++++++++ .../wvdial/wvstreams/05_gcc.diff | 13 - .../wvdial/wvstreams/openssl-buildfix.patch | 16 + .../wvdial/wvstreams_4.6.1.bb | 2 + 4 files changed, 575 insertions(+), 13 deletions(-) create mode 100644 meta-oe/recipes-connectivity/wvdial/wvstreams/0001-Forward-port-to-OpenSSL-1.1.x.patch create mode 100644 meta-oe/recipes-connectivity/wvdial/wvstreams/openssl-buildfix.patch -- 2.18.0 -- _______________________________________________ Openembedded-devel mailing list Openembedded-devel@lists.openembedded.org http://lists.openembedded.org/mailman/listinfo/openembedded-devel diff --git a/meta-oe/recipes-connectivity/wvdial/wvstreams/0001-Forward-port-to-OpenSSL-1.1.x.patch b/meta-oe/recipes-connectivity/wvdial/wvstreams/0001-Forward-port-to-OpenSSL-1.1.x.patch new file mode 100644 index 0000000000..19a2e26f2a --- /dev/null +++ b/meta-oe/recipes-connectivity/wvdial/wvstreams/0001-Forward-port-to-OpenSSL-1.1.x.patch @@ -0,0 +1,557 @@ +From 0c35749891bf834c1f3c1c4c330266bd2f4733cc Mon Sep 17 00:00:00 2001 +From: Khem Raj +Date: Sun, 9 Sep 2018 10:40:09 -0700 +Subject: [PATCH] Forward port to OpenSSL 1.1.x + +* import patch from debian +https://sources.debian.org/src/wvstreams/4.6.1-14/debian/patches/wvstreams_openssl1.1.patch +Author: Reiner Herrmann + +Upstream-Status: Submitted [https://github.com/apenwarr/wvstreams/pull/2] +Signed-off-by: Khem Raj +--- + crypto/wvcrl.cc | 38 +++++++++++++------------------------- + crypto/wvdiffiehellman.cc | 30 +++++++++++++++++++----------- + crypto/wvdigest.cc | 16 ++++++++-------- + crypto/wvocsp.cc | 35 +++++++++-------------------------- + crypto/wvx509.cc | 31 ++++++++++++++++--------------- + crypto/wvx509mgr.cc | 27 ++++++++++++++++----------- + include/wvdiffiehellman.h | 2 +- + include/wvdigest.h | 14 ++++++-------- + include/wvtripledes.h | 10 +++++----- + 9 files changed, 93 insertions(+), 110 deletions(-) + +diff --git a/crypto/wvcrl.cc b/crypto/wvcrl.cc +index fa00c76..880ad85 100644 +--- a/crypto/wvcrl.cc ++++ b/crypto/wvcrl.cc +@@ -357,31 +357,19 @@ bool WvCRL::isrevoked(WvStringParm serial_number) const + ASN1_INTEGER *serial = serial_to_int(serial_number); + if (serial) + { +- X509_REVOKED mayberevoked; +- mayberevoked.serialNumber = serial; +- if (crl->crl->revoked) +- { +- int idx = sk_X509_REVOKED_find(crl->crl->revoked, +- &mayberevoked); +- ASN1_INTEGER_free(serial); +- if (idx >= 0) +- { +- debug("Certificate is revoked.\n"); +- return true; +- } +- else +- { +- debug("Certificate is not revoked.\n"); +- return false; +- } +- } +- else +- { +- ASN1_INTEGER_free(serial); +- debug("CRL does not have revoked list.\n"); +- return false; +- } +- ++ X509_REVOKED *revoked_entry = NULL; ++ int idx = X509_CRL_get0_by_serial(crl, &revoked_entry, serial); ++ ASN1_INTEGER_free(serial); ++ if (idx >= 1 || revoked_entry) ++ { ++ debug("Certificate is revoked.\n"); ++ return true; ++ } ++ else ++ { ++ debug("Certificate is not revoked.\n"); ++ return false; ++ } + } + else + debug(WvLog::Warning, "Can't convert serial number to ASN1 format. " +diff --git a/crypto/wvdiffiehellman.cc b/crypto/wvdiffiehellman.cc +index 7c0bf32..15cd104 100644 +--- a/crypto/wvdiffiehellman.cc ++++ b/crypto/wvdiffiehellman.cc +@@ -39,24 +39,25 @@ WvDiffieHellman::WvDiffieHellman(const unsigned char *_key, int _keylen, + { + int problems; + int check; +- { ++ + info = DH_new(); +- info->p = BN_bin2bn(_key, _keylen, NULL); ++ BIGNUM *p = BN_bin2bn(_key, _keylen, NULL); + // info->p->top = 0; + // info->p->dmax = _keylen * 8 / BN_BITS2; + // info->p->neg = 0; + // info->p->flags = 0; + +- info->g = BN_new(); +- BN_set_word(info->g, generator); ++ BIGNUM *g = BN_new(); ++ BN_set_word(g, generator); + // info->g->d = &generator; + // info->g->top = 0; + // info->g->dmax = 1; + // info->g->neg = 0; + // info->g->flags = 0; +- } + +- check = BN_mod_word(info->p, 24); ++ DH_set0_pqg(info, p, NULL, g); ++ ++ check = BN_mod_word(p, 24); + DH_check(info, &problems); + if (problems & DH_CHECK_P_NOT_PRIME) + log(WvLog::Error, "Using a composite number for authentication.\n"); +@@ -64,7 +65,7 @@ WvDiffieHellman::WvDiffieHellman(const unsigned char *_key, int _keylen, + log(WvLog::Error,"Using an unsafe prime number for authentication.\n"); + if (problems & DH_NOT_SUITABLE_GENERATOR) + log(WvLog::Error, "Can you just use 2 instead of %s (%s)!!\n", +- BN_bn2hex(info->g), check); ++ BN_bn2hex(g), check); + if (problems & DH_UNABLE_TO_CHECK_GENERATOR) + log(WvLog::Notice, "Using a strange argument for diffie-hellman.\n"); + DH_generate_key(info); +@@ -72,18 +73,23 @@ WvDiffieHellman::WvDiffieHellman(const unsigned char *_key, int _keylen, + + int WvDiffieHellman::pub_key_len() + { +- return BN_num_bytes(info->pub_key); ++ const BIGNUM *pub_key = NULL; ++ DH_get0_key(info, &pub_key, NULL); ++ return BN_num_bytes(pub_key); + } + + int WvDiffieHellman::get_public_value(WvBuf &outbuf, int len) + { +- int key_len = BN_num_bytes(info->pub_key); ++ const BIGNUM *pub_key = NULL; ++ DH_get0_key(info, &pub_key, NULL); ++ ++ int key_len = BN_num_bytes(pub_key); + if (key_len < len) + len = key_len; + + // alloca is stack allocated, don't free it. + unsigned char *foo = (unsigned char*)alloca(key_len); +- BN_bn2bin(info->pub_key, foo); ++ BN_bn2bin(pub_key, foo); + outbuf.put(foo, len); + + return len; +@@ -91,8 +97,10 @@ int WvDiffieHellman::get_public_value(WvBuf &outbuf, int len) + + bool WvDiffieHellman::create_secret(WvBuf &inbuf, size_t in_len, WvBuf& outbuf) + { ++ const BIGNUM *pub_key = NULL; ++ DH_get0_key(info, &pub_key, NULL); + unsigned char *foo = (unsigned char *)alloca(DH_size(info)); +- log("My public value\n%s\nYour public value\n%s\n",BN_bn2hex(info->pub_key), ++ log("My public value\n%s\nYour public value\n%s\n",BN_bn2hex(pub_key), + hexdump_buffer(inbuf.peek(0, in_len), in_len, false)); + int len = DH_compute_key (foo, BN_bin2bn(inbuf.get(in_len), in_len, NULL), + info); +diff --git a/crypto/wvdigest.cc b/crypto/wvdigest.cc +index 150edee..73ebb5d 100644 +--- a/crypto/wvdigest.cc ++++ b/crypto/wvdigest.cc +@@ -13,10 +13,10 @@ + + /***** WvEVPMDDigest *****/ + +-WvEVPMDDigest::WvEVPMDDigest(const env_md_st *_evpmd) : ++WvEVPMDDigest::WvEVPMDDigest(const EVP_MD*_evpmd) : + evpmd(_evpmd), active(false) + { +- evpctx = new EVP_MD_CTX; ++ evpctx = EVP_MD_CTX_new(); + _reset(); + } + +@@ -24,7 +24,7 @@ WvEVPMDDigest::WvEVPMDDigest(const env_md_st *_evpmd) : + WvEVPMDDigest::~WvEVPMDDigest() + { + cleanup(); +- delete evpctx; ++ EVP_MD_CTX_free(evpctx); + } + + +@@ -60,7 +60,7 @@ bool WvEVPMDDigest::_reset() + // the typecast is necessary for API compatibility with different + // versions of openssl. None of them *actually* change the contents of + // the pointer. +- EVP_DigestInit(evpctx, (env_md_st *)evpmd); ++ EVP_DigestInit(evpctx, evpmd); + active = true; + return true; + } +@@ -79,7 +79,7 @@ void WvEVPMDDigest::cleanup() + + size_t WvEVPMDDigest::digestsize() const + { +- return EVP_MD_size((env_md_st *)evpmd); ++ return EVP_MD_size(evpmd); + } + + +@@ -104,14 +104,14 @@ WvHMACDigest::WvHMACDigest(WvEVPMDDigest *_digest, + { + key = new unsigned char[keysize]; + memcpy(key, _key, keysize); +- hmacctx = new HMAC_CTX; ++ hmacctx = HMAC_CTX_new(); + _reset(); + } + + WvHMACDigest::~WvHMACDigest() + { + cleanup(); +- delete hmacctx; ++ HMAC_CTX_free(hmacctx); + deletev key; + delete digest; + } +@@ -145,7 +145,7 @@ bool WvHMACDigest::_finish(WvBuf &outbuf) + bool WvHMACDigest::_reset() + { + cleanup(); +- HMAC_Init(hmacctx, key, keysize, (env_md_st *)digest->getevpmd()); ++ HMAC_Init(hmacctx, key, keysize, digest->getevpmd()); + active = true; + return true; + } +diff --git a/crypto/wvocsp.cc b/crypto/wvocsp.cc +index ddb2de4..7d5da07 100644 +--- a/crypto/wvocsp.cc ++++ b/crypto/wvocsp.cc +@@ -118,9 +118,10 @@ bool WvOCSPResp::check_nonce(const WvOCSPReq &req) const + + bool WvOCSPResp::signedbycert(const WvX509 &cert) const + { +- EVP_PKEY *skey = X509_get_pubkey(cert.cert); +- int i = OCSP_BASICRESP_verify(bs, skey, 0); +- EVP_PKEY_free(skey); ++ STACK_OF(X509) *sk = sk_X509_new_null(); ++ sk_X509_push(sk, cert.cert); ++ int i = OCSP_basic_verify(bs, sk, NULL, OCSP_NOVERIFY); ++ sk_X509_free(sk); + + if(i > 0) + return true; +@@ -131,33 +132,15 @@ bool WvOCSPResp::signedbycert(const WvX509 &cert) const + + WvX509 WvOCSPResp::get_signing_cert() const + { +- if (!bs || !sk_X509_num(bs->certs)) ++ const STACK_OF(X509) *certs = OCSP_resp_get0_certs(bs); ++ if (!bs || !sk_X509_num(certs)) + return WvX509(); + +- // note: the following bit of code is taken almost verbatim from +- // ocsp_vfy.c in OpenSSL 0.9.8. Copyright and attribution should +- // properly belong to them +- +- OCSP_RESPID *id = bs->tbsResponseData->responderId; +- +- if (id->type == V_OCSP_RESPID_NAME) +- { +- X509 *x = X509_find_by_subject(bs->certs, id->value.byName); +- if (x) +- return WvX509(X509_dup(x)); ++ X509 *signer = NULL; ++ if (OCSP_resp_get0_signer(bs, &signer, NULL) == 1) { ++ return WvX509(X509_dup(signer)); + } + +- if (id->value.byKey->length != SHA_DIGEST_LENGTH) return NULL; +- unsigned char tmphash[SHA_DIGEST_LENGTH]; +- unsigned char *keyhash = id->value.byKey->data; +- for (int i = 0; i < sk_X509_num(bs->certs); i++) +- { +- X509 *x = sk_X509_value(bs->certs, i); +- X509_pubkey_digest(x, EVP_sha1(), tmphash, NULL); +- if(!memcmp(keyhash, tmphash, SHA_DIGEST_LENGTH)) +- return WvX509(X509_dup(x)); +- } +- + return WvX509(); + } + +diff --git a/crypto/wvx509.cc b/crypto/wvx509.cc +index e4925ce..984156c 100644 +--- a/crypto/wvx509.cc ++++ b/crypto/wvx509.cc +@@ -974,7 +974,7 @@ static void add_aia(WvStringParm type, WvString identifier, + sk_ACCESS_DESCRIPTION_push(ainfo, acc); + acc->method = OBJ_txt2obj(type.cstr(), 0); + acc->location->type = GEN_URI; +- acc->location->d.ia5 = M_ASN1_IA5STRING_new(); ++ acc->location->d.ia5 = ASN1_IA5STRING_new(); + unsigned char *cident + = reinterpret_cast(identifier.edit()); + ASN1_STRING_set(acc->location->d.ia5, cident, identifier.len()); +@@ -1059,7 +1059,7 @@ void WvX509::set_crl_urls(WvStringList &urls) + GENERAL_NAMES *uris = GENERAL_NAMES_new(); + GENERAL_NAME *uri = GENERAL_NAME_new(); + uri->type = GEN_URI; +- uri->d.ia5 = M_ASN1_IA5STRING_new(); ++ uri->d.ia5 = ASN1_IA5STRING_new(); + unsigned char *cident + = reinterpret_cast(i().edit()); + ASN1_STRING_set(uri->d.ia5, cident, i().len()); +@@ -1162,10 +1162,11 @@ WvString WvX509::get_extension(int nid) const + #else + X509V3_EXT_METHOD *method = X509V3_EXT_get(ext); + #endif ++ ASN1_OCTET_STRING *ext_data_str = X509_EXTENSION_get_data(ext); + if (!method) + { + WvDynBuf buf; +- buf.put(ext->value->data, ext->value->length); ++ buf.put(ext_data_str->data, ext_data_str->length); + retval = buf.getstr(); + } + else +@@ -1176,21 +1177,21 @@ WvString WvX509::get_extension(int nid) const + // even though it's const (at least as of version 0.9.8e). + // gah. + #if OPENSSL_VERSION_NUMBER >= 0x0090800fL +- const unsigned char * ext_value_data = ext->value->data; ++ const unsigned char * ext_value_data = ext_data_str->data; + #else + unsigned char *ext_value_data = ext->value->data; + #endif + if (method->it) + { + ext_data = ASN1_item_d2i(NULL, &ext_value_data, +- ext->value->length, ++ ext_data_str->length, + ASN1_ITEM_ptr(method->it)); + TRACE("Applied generic conversion!\n"); + } + else + { + ext_data = method->d2i(NULL, &ext_value_data, +- ext->value->length); ++ ext_data_str->length); + TRACE("Applied method specific conversion!\n"); + } + +@@ -1325,13 +1326,13 @@ bool WvX509::verify(WvBuf &original, WvStringParm signature) const + return false; + + /* Verify the signature */ +- EVP_MD_CTX sig_ctx; +- EVP_VerifyInit(&sig_ctx, EVP_sha1()); +- EVP_VerifyUpdate(&sig_ctx, original.peek(0, original.used()), ++ EVP_MD_CTX *sig_ctx = EVP_MD_CTX_new(); ++ EVP_VerifyInit(sig_ctx, EVP_sha1()); ++ EVP_VerifyUpdate(sig_ctx, original.peek(0, original.used()), + original.used()); +- int sig_err = EVP_VerifyFinal(&sig_ctx, sig_buf, sig_size, pk); ++ int sig_err = EVP_VerifyFinal(sig_ctx, sig_buf, sig_size, pk); + EVP_PKEY_free(pk); +- EVP_MD_CTX_cleanup(&sig_ctx); // Again, not my fault... ++ EVP_MD_CTX_free(sig_ctx); // Again, not my fault... + if (sig_err != 1) + { + debug("Verify failed!\n"); +@@ -1450,19 +1451,19 @@ void WvX509::set_ski() + { + CHECK_CERT_EXISTS_SET("ski"); + +- ASN1_OCTET_STRING *oct = M_ASN1_OCTET_STRING_new(); +- ASN1_BIT_STRING *pk = cert->cert_info->key->public_key; ++ ASN1_OCTET_STRING *oct = ASN1_OCTET_STRING_new(); ++ ASN1_BIT_STRING *pk = X509_get0_pubkey_bitstr(cert); + unsigned char pkey_dig[EVP_MAX_MD_SIZE]; + unsigned int diglen; + + EVP_Digest(pk->data, pk->length, pkey_dig, &diglen, EVP_sha1(), NULL); + +- M_ASN1_OCTET_STRING_set(oct, pkey_dig, diglen); ++ ASN1_OCTET_STRING_set(oct, pkey_dig, diglen); + X509_EXTENSION *ext = X509V3_EXT_i2d(NID_subject_key_identifier, 0, + oct); + X509_add_ext(cert, ext, -1); + X509_EXTENSION_free(ext); +- M_ASN1_OCTET_STRING_free(oct); ++ ASN1_OCTET_STRING_free(oct); + } + + +diff --git a/crypto/wvx509mgr.cc b/crypto/wvx509mgr.cc +index f249eec..156d3a4 100644 +--- a/crypto/wvx509mgr.cc ++++ b/crypto/wvx509mgr.cc +@@ -350,6 +350,8 @@ bool WvX509Mgr::signcert(WvX509 &unsignedcert) const + return false; + } + ++ uint32_t ex_flags = X509_get_extension_flags(cert); ++ uint32_t ex_kusage = X509_get_key_usage(cert); + if (cert == unsignedcert.cert) + { + debug("Self Signing!\n"); +@@ -362,8 +364,8 @@ bool WvX509Mgr::signcert(WvX509 &unsignedcert) const + return false; + } + #endif +- else if (!((cert->ex_flags & EXFLAG_KUSAGE) && +- (cert->ex_kusage & KU_KEY_CERT_SIGN))) ++ else if (!((ex_flags & EXFLAG_KUSAGE) && ++ (ex_kusage & KU_KEY_CERT_SIGN))) + { + debug("This Certificate is not allowed to sign certificates!\n"); + return false; +@@ -390,6 +392,8 @@ bool WvX509Mgr::signcert(WvX509 &unsignedcert) const + + bool WvX509Mgr::signcrl(WvCRL &crl) const + { ++ uint32_t ex_flags = X509_get_extension_flags(cert); ++ uint32_t ex_kusage = X509_get_key_usage(cert); + if (!isok() || !crl.isok()) + { + debug(WvLog::Warning, "Asked to sign CRL, but certificate or CRL (or " +@@ -403,12 +407,12 @@ bool WvX509Mgr::signcrl(WvCRL &crl) const + "CRLs!\n"); + return false; + } +- else if (!((cert->ex_flags & EXFLAG_KUSAGE) && +- (cert->ex_kusage & KU_CRL_SIGN))) ++ else if (!((ex_flags & EXFLAG_KUSAGE) && ++ (ex_kusage & KU_CRL_SIGN))) + { + debug("Certificate not allowed to sign CRLs! (%s %s)\n", +- (cert->ex_flags & EXFLAG_KUSAGE), +- (cert->ex_kusage & KU_CRL_SIGN)); ++ (ex_flags & EXFLAG_KUSAGE), ++ (ex_kusage & KU_CRL_SIGN)); + return false; + } + #endif +@@ -454,7 +458,6 @@ WvString WvX509Mgr::sign(WvBuf &data) const + { + assert(rsa); + +- EVP_MD_CTX sig_ctx; + unsigned char sig_buf[4096]; + + EVP_PKEY *pk = EVP_PKEY_new(); +@@ -467,20 +470,22 @@ WvString WvX509Mgr::sign(WvBuf &data) const + return WvString::null; + } + +- EVP_SignInit(&sig_ctx, EVP_sha1()); +- EVP_SignUpdate(&sig_ctx, data.peek(0, data.used()), data.used()); ++ EVP_MD_CTX *sig_ctx = EVP_MD_CTX_new(); ++ EVP_SignInit(sig_ctx, EVP_sha1()); ++ EVP_SignUpdate(sig_ctx, data.peek(0, data.used()), data.used()); + unsigned int sig_len = sizeof(sig_buf); +- int sig_err = EVP_SignFinal(&sig_ctx, sig_buf, ++ int sig_err = EVP_SignFinal(sig_ctx, sig_buf, + &sig_len, pk); + if (sig_err != 1) + { + debug("Error while signing.\n"); + EVP_PKEY_free(pk); ++ EVP_MD_CTX_free(sig_ctx); + return WvString::null; + } + + EVP_PKEY_free(pk); +- EVP_MD_CTX_cleanup(&sig_ctx); // this isn't my fault :// ++ EVP_MD_CTX_free(sig_ctx); // this isn't my fault :// + WvDynBuf buf; + buf.put(sig_buf, sig_len); + debug("Signature size: %s\n", buf.used()); +diff --git a/include/wvdiffiehellman.h b/include/wvdiffiehellman.h +index af75ffa..a2d001f 100644 +--- a/include/wvdiffiehellman.h ++++ b/include/wvdiffiehellman.h +@@ -27,7 +27,7 @@ public: + bool create_secret(WvBuf &inbuf, size_t in_len, WvBuf& outbuf); + + protected: +- struct dh_st *info; ++ DH *info; + BN_ULONG generator; + + private: +diff --git a/include/wvdigest.h b/include/wvdigest.h +index fdc39bd..f2eed40 100644 +--- a/include/wvdigest.h ++++ b/include/wvdigest.h +@@ -9,10 +9,8 @@ + + #include "wvencoder.h" + #include ++#include + +-struct env_md_st; +-struct env_md_ctx_st; +-struct hmac_ctx_st; + + /** + * Superclass for all message digests. +@@ -45,8 +43,8 @@ public: + class WvEVPMDDigest : public WvDigest + { + friend class WvHMACDigest; +- const env_md_st *evpmd; +- env_md_ctx_st *evpctx; ++ const EVP_MD *evpmd; ++ EVP_MD_CTX *evpctx; + bool active; + + public: +@@ -54,13 +52,13 @@ public: + virtual size_t digestsize() const; + + protected: +- WvEVPMDDigest(const env_md_st *_evpmd); ++ WvEVPMDDigest(const EVP_MD *_evpmd); + virtual bool _encode(WvBuf &inbuf, WvBuf &outbuf, + bool flush); // consumes input + virtual bool _finish(WvBuf &outbuf); // outputs digest + virtual bool _reset(); // supported: resets digest value + +- const env_md_st *getevpmd() ++ const EVP_MD *getevpmd() + { return evpmd; } + + private: +@@ -104,7 +102,7 @@ class WvHMACDigest : public WvDigest + WvEVPMDDigest *digest; + unsigned char *key; + size_t keysize; +- hmac_ctx_st *hmacctx; ++ HMAC_CTX *hmacctx; + bool active; + + public: +diff --git a/include/wvtripledes.h b/include/wvtripledes.h +index 185fe8a..a442e7a 100644 +--- a/include/wvtripledes.h ++++ b/include/wvtripledes.h +@@ -70,11 +70,11 @@ protected: + + private: + Mode mode; +- des_cblock key; +- des_key_schedule deskey1; +- des_key_schedule deskey2; +- des_key_schedule deskey3; +- des_cblock ivec; // initialization vector ++ DES_cblock key; ++ DES_key_schedule deskey1; ++ DES_key_schedule deskey2; ++ DES_key_schedule deskey3; ++ DES_cblock ivec; // initialization vector + int ivecoff; // current offset into initvec + }; + diff --git a/meta-oe/recipes-connectivity/wvdial/wvstreams/05_gcc.diff b/meta-oe/recipes-connectivity/wvdial/wvstreams/05_gcc.diff index 8e4fd03298..616843d4ae 100644 --- a/meta-oe/recipes-connectivity/wvdial/wvstreams/05_gcc.diff +++ b/meta-oe/recipes-connectivity/wvdial/wvstreams/05_gcc.diff @@ -1,16 +1,3 @@ -Index: wvstreams-4.6.1/crypto/wvx509.cc -=================================================================== ---- wvstreams-4.6.1.orig/crypto/wvx509.cc 2011-05-20 00:02:38.119136584 +0200 -+++ wvstreams-4.6.1/crypto/wvx509.cc 2011-05-20 00:02:26.035136589 +0200 -@@ -1157,7 +1157,7 @@ - - if (ext) - { -- X509V3_EXT_METHOD *method = X509V3_EXT_get(ext); -+ X509V3_EXT_METHOD *method = (X509V3_EXT_METHOD *)X509V3_EXT_get(ext); - if (!method) - { - WvDynBuf buf; Index: wvstreams-4.6.1/ipstreams/wvunixdgsocket.cc =================================================================== --- wvstreams-4.6.1.orig/ipstreams/wvunixdgsocket.cc 2011-05-20 00:02:38.391136584 +0200 diff --git a/meta-oe/recipes-connectivity/wvdial/wvstreams/openssl-buildfix.patch b/meta-oe/recipes-connectivity/wvdial/wvstreams/openssl-buildfix.patch new file mode 100644 index 0000000000..1c7005c2fe --- /dev/null +++ b/meta-oe/recipes-connectivity/wvdial/wvstreams/openssl-buildfix.patch @@ -0,0 +1,16 @@ +Index: wvstreams-4.6.1/crypto/wvx509.cc +=================================================================== +--- wvstreams-4.6.1.orig/crypto/wvx509.cc ++++ wvstreams-4.6.1/crypto/wvx509.cc +@@ -1157,7 +1157,11 @@ WvString WvX509::get_extension(int nid) + + if (ext) + { ++#if OPENSSL_VERSION_NUMBER >= 0x10000000L ++ const X509V3_EXT_METHOD *method = X509V3_EXT_get(ext); ++#else + X509V3_EXT_METHOD *method = X509V3_EXT_get(ext); ++#endif + if (!method) + { + WvDynBuf buf; diff --git a/meta-oe/recipes-connectivity/wvdial/wvstreams_4.6.1.bb b/meta-oe/recipes-connectivity/wvdial/wvstreams_4.6.1.bb index e3d5e7d20b..293949d711 100644 --- a/meta-oe/recipes-connectivity/wvdial/wvstreams_4.6.1.bb +++ b/meta-oe/recipes-connectivity/wvdial/wvstreams_4.6.1.bb @@ -21,6 +21,8 @@ SRC_URI = "http://${BPN}.googlecode.com/files/${BP}.tar.gz \ file://0005-check-for-libexecinfo-during-configure.patch \ file://0001-build-fix-parallel-make.patch \ file://0002-wvrules.mk-Use-_DEFAULT_SOURCE.patch \ + file://openssl-buildfix.patch \ + file://0001-Forward-port-to-OpenSSL-1.1.x.patch \ " SRC_URI[md5sum] = "2760dac31a43d452a19a3147bfde571c" From patchwork Mon Sep 10 05:06:27 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Khem Raj X-Patchwork-Id: 146276 Delivered-To: patch@linaro.org Received: by 2002:a2e:1648:0:0:0:0:0 with SMTP id 8-v6csp2078962ljw; Sun, 9 Sep 2018 22:08:27 -0700 (PDT) X-Google-Smtp-Source: ANB0VdY1RMDMkC2itRHUb0KnHKvXYr7bxyMG4iYcRVFCEWwFE2c1yx+kez75DQI2IVP9j4CrKNRb X-Received: by 2002:a17:902:1101:: with SMTP id d1-v6mr20205920pla.131.1536556107475; Sun, 09 Sep 2018 22:08:27 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1536556107; cv=none; d=google.com; s=arc-20160816; b=a6w6jsSWTHA6qesL+LzR0LaHnkj2VA31YlYWLlWQ2Azutna3pR2jpBAu57gSU/rYmB 8NN2JMctp3WIfMeBGZ8/PapBPD4E+XIQOV+cUY9YcQLcmb64WeKQ1U36YIn/0qI5GqiG 2lJ03WGm95raNhLGXvT+SqXDKqq726U/etM6d10QfmhNWjboAu31VRVvHOKeXH3fBFrw oX3KlPjPQejvh8eXJFgWXhQ0lKe2LQBiN4dFontt0Thatv+Ff0HANqSfUVZgCmiDwyd4 ovPiuRA8c+IrUxPn6QHrtGaG6u/Ktpy9zm2xLI48Cpr7JsmfnJFlfTn7rO5e+9oFRXLH D21A== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=errors-to:sender:content-transfer-encoding:mime-version :list-subscribe:list-help:list-post:list-archive:list-unsubscribe :list-id:precedence:subject:references:in-reply-to:message-id:date :to:from:dkim-signature:delivered-to; bh=oMzkiMYHs2eGYK2mH0BLW4pt3GUstTyFwdgSsOFXToU=; b=JMl0SE7/Zq/AvbYLt1K/WKH8h4s24usXpKNJ/fDSkC34ohvkFWT6SXJ6P9niIOlprN kaSxc0QKLm9LmvXLK8K/jFNDdr8Tg7LJOEvnRVG4/9uAb7bE1ILiqm4uJZXVdwVR8CtX lFY7urFVb28crDI8FMJDk33/mKQg1959El1tkmw03Y0tym8kWqCkYnZnG4dA3VOJueYU FmzyUEwEPGxC+at297BxNil8GW6Ws+/J4wa6ve4ZTg0LjNjBV8PINLNZ5BvcHT3bUZcP R82ujD0KkVm6OoUkxF3bMImMFBu8jGYeh+DjOJCebTIUyJ7DeClSwqihy2z7Jj2ZnXN+ Y1EA== ARC-Authentication-Results: i=1; mx.google.com; dkim=neutral (body hash did not verify) header.i=@gmail.com header.s=20161025 header.b=e37WuuiG; 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 e22-v6si15803999pgi.111.2018.09.09.22.08.27; Sun, 09 Sep 2018 22:08:27 -0700 (PDT) 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=e37WuuiG; 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 layers.openembedded.org (localhost [127.0.0.1]) by mail.openembedded.org (Postfix) with ESMTP id 93AAF79748; Mon, 10 Sep 2018 05:07:46 +0000 (UTC) X-Original-To: openembedded-devel@lists.openembedded.org Delivered-To: openembedded-devel@lists.openembedded.org Received: from mail-pf1-f174.google.com (mail-pf1-f174.google.com [209.85.210.174]) by mail.openembedded.org (Postfix) with ESMTP id 781257951E for ; Mon, 10 Sep 2018 05:06:44 +0000 (UTC) Received: by mail-pf1-f174.google.com with SMTP id b11-v6so9837513pfo.3 for ; Sun, 09 Sep 2018 22:06:45 -0700 (PDT) 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; bh=HFdKsVij6b3su3pPNYPrOOa4Bjzbj4lbL3p/mMNPOQ0=; b=e37WuuiGNX5JFMXJgS3NHDW0ZrF+jZpapvHkRhNxMrWLGjERhAuCywRLNrRPv/OKjR /SBfufA6DPNO5lj67BESOWzLmhTmkU5ZzxqumK+/HKom12FgU+1StL5Jcj1tGzY9WsGG gvI//18+R2BRnSvAvLavI8txQeDjtYt6AMSyKydHzCoZw+brHTdhuiKbigviZ/waCbS1 oj2TVxOjifqIa5SOTuMF3ueCJxSB1NhZlv8CHaTHTFG2RVCyA36Ohr0DkR6DxEQpB356 +RFzvo7kgZ1+dJ1nV4HW7YwAhvlULPLZroUvN+z2OKCciodHFUsW3kSk10too17WaRUT ni2w== 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=HFdKsVij6b3su3pPNYPrOOa4Bjzbj4lbL3p/mMNPOQ0=; b=I6gcEAHdN9nLp4/gIUJyH77yDrFxIihC3sDQUvWtJSGLsopWju00KOTC6B7zRPMROa stY37NuZG2VvUHtKnrg0wfOSmTF0arphub49M+30kg9yMLoFr2D7mcWB/ocP9i2Zf4JC zQSdrOAllzkmJCHv/OV9eCsbfsop+WdvtsCm7htH0XxMJEnaaYOmBEGnKQegBsn/l8/L A6rfrkc58GbKAeLaflRsE1xjc4sQSU84k8kxl+Mlg/QD8DH79Cgc01r1dncmFcWMOehQ z0wXFfMKF99vfE3/n/W0NN8AYWqVVoV04AxbgrNcsZ9nivWcOdIO1YQNrEpE1klxNAsx UhAw== X-Gm-Message-State: APzg51C2UVUA/+odC+x7EmdnPLFua26y0o4H6aoRdo4BeHZ+H3A71Hb6 Tny1RbcXCjyHh4QUQb9xwb4FT0eS X-Received: by 2002:a62:9e08:: with SMTP id s8-v6mr21724537pfd.23.1536556005120; Sun, 09 Sep 2018 22:06:45 -0700 (PDT) Received: from localhost.localdomain ([2601:646:877f:9499::2887]) by smtp.gmail.com with ESMTPSA id x24-v6sm18819188pfh.67.2018.09.09.22.06.44 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Sun, 09 Sep 2018 22:06:44 -0700 (PDT) From: Khem Raj To: openembedded-devel@lists.openembedded.org Date: Sun, 9 Sep 2018 22:06:27 -0700 Message-Id: <20180910050629.16170-8-raj.khem@gmail.com> X-Mailer: git-send-email 2.18.0 In-Reply-To: <20180910050629.16170-1-raj.khem@gmail.com> References: <20180910050629.16170-1-raj.khem@gmail.com> Subject: [oe] [meta-oe][PATCH 08/10] breakpad: Pass correct type name to sizeof() 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: , MIME-Version: 1.0 Sender: openembedded-devel-bounces@lists.openembedded.org Errors-To: openembedded-devel-bounces@lists.openembedded.org memset is clearing memory area address starting at contect.context but it needs the correct size of type 'ucontext_t', currently its getting size of 'ucontext_t*' Signed-off-by: Khem Raj Cc: Andre McCurdy --- ...01-disable-calls-to-getcontext-with-musl.patch | 15 ++++++--------- 1 file changed, 6 insertions(+), 9 deletions(-) -- 2.18.0 -- _______________________________________________ Openembedded-devel mailing list Openembedded-devel@lists.openembedded.org http://lists.openembedded.org/mailman/listinfo/openembedded-devel diff --git a/meta-oe/recipes-devtools/breakpad/breakpad/0001-disable-calls-to-getcontext-with-musl.patch b/meta-oe/recipes-devtools/breakpad/breakpad/0001-disable-calls-to-getcontext-with-musl.patch index c762754ad1..bc79727edd 100644 --- a/meta-oe/recipes-devtools/breakpad/breakpad/0001-disable-calls-to-getcontext-with-musl.patch +++ b/meta-oe/recipes-devtools/breakpad/breakpad/0001-disable-calls-to-getcontext-with-musl.patch @@ -8,11 +8,11 @@ Signed-off-by: Andre McCurdy src/client/linux/handler/exception_handler.cc | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) -diff --git a/src/client/linux/handler/exception_handler.cc b/src/client/linux/handler/exception_handler.cc -index cca023f..f3e460c 100644 ---- a/src/client/linux/handler/exception_handler.cc -+++ b/src/client/linux/handler/exception_handler.cc -@@ -495,7 +495,19 @@ bool ExceptionHandler::SimulateSignalDelivery(int sig) { +Index: git/src/client/linux/handler/exception_handler.cc +=================================================================== +--- git.orig/src/client/linux/handler/exception_handler.cc ++++ git/src/client/linux/handler/exception_handler.cc +@@ -495,7 +495,19 @@ bool ExceptionHandler::SimulateSignalDel siginfo.si_code = SI_USER; siginfo.si_pid = getpid(); ucontext_t context; @@ -42,11 +42,8 @@ index cca023f..f3e460c 100644 return false; +#else + // Extreme hack - see comments above. -+ memset (&context.context, 0, sizeof(&context.context)); ++ memset (&context.context, 0, sizeof(context.context)); +#endif #if defined(__i386__) // In CPUFillFromUContext in minidumpwriter.cc the stack pointer is retrieved --- -1.9.1 - From patchwork Mon Sep 10 05:06:28 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Khem Raj X-Patchwork-Id: 146277 Delivered-To: patch@linaro.org Received: by 2002:a2e:1648:0:0:0:0:0 with SMTP id 8-v6csp2079064ljw; Sun, 9 Sep 2018 22:08:37 -0700 (PDT) X-Google-Smtp-Source: ANB0VdboN9wr1/MDByXVIHkgb59OdIYA8+SaEYnXnaC9vh0uu1VIfNz/K3B6V6BgjxSpO7/nap+y X-Received: by 2002:a17:902:8bc4:: with SMTP id r4-v6mr19355197plo.124.1536556116846; Sun, 09 Sep 2018 22:08:36 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1536556116; cv=none; d=google.com; s=arc-20160816; b=VlV4vl8SPaUMiX1l+D8U6mgarVmd6EUuzH8vSc+UloW+jrQ4eIbDbgrUUM7c3gv5j+ Mkz/MPQRYGz0o3mnHbbphKr9CmMavnJ2I6VdEv2LLu4b6rB9bEXUMbzQaWFdo51RR0CS u8e1ja2hyTAalXBKutBq6YGe0Gw7d2EKFQH+QWX6skU9Q67jk2RvtsH8yaWYnH0ffP0A dSC9xnqxNjFnrs7z/ZAuqlLgRQDXHh/mtTTStBI9AnU+7UNL35DDO5LC6ldFmR3xuAH5 baAgtzAoPO7f+KpNnqOduGoCq2NVMOFnQG8YxjVfi5C2S4FiCI0S7iVe5FBSDyPisbbi tRmQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=errors-to:sender:content-transfer-encoding:mime-version :list-subscribe:list-help:list-post:list-archive:list-unsubscribe :list-id:precedence:subject:references:in-reply-to:message-id:date :to:from:dkim-signature:delivered-to; bh=ryfOR3AnVvHXa7KHSd2K9YIgGppiqxXEgK8iVoFqCoo=; b=vZ+RdEDvsyi+RTBOQPG8OT+6Rc0Dzx39bJ089NMPFdCWoxlQa6UPFXPZVwB5lQHoyF uV7PuHnNGf90bIaSvqyfs7AVxOhHQvrcC5CKIAzFPYzYPiMtPzhJM+UGyyAjAYWGSgqI 8NrJYaQ6weCrwjWuG4G5Kz9Qo+QApkGNPN29ANTlJFmbfSU1t+MVsq7H3l/YvL2gsINW 4sVnE3wLyId9IZCQMsp2djZjanTnd4os47DZhfZX9i5doTiex/mXsiOlKXaQppc9SG1s 8Ol+zDd3+RO+x0B3S/Wbtz5SlJnB8JL0oIrc1EzErSVRVRS4E/qTNAuk3nx0SZYAJK27 HXhQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=neutral (body hash did not verify) header.i=@gmail.com header.s=20161025 header.b=gYDPPHjf; 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 u1-v6si13576375plb.291.2018.09.09.22.08.36; Sun, 09 Sep 2018 22:08:36 -0700 (PDT) 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=gYDPPHjf; 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 layers.openembedded.org (localhost [127.0.0.1]) by mail.openembedded.org (Postfix) with ESMTP id 3CE9679702; Mon, 10 Sep 2018 05:07:48 +0000 (UTC) X-Original-To: openembedded-devel@lists.openembedded.org Delivered-To: openembedded-devel@lists.openembedded.org Received: from mail-pf1-f196.google.com (mail-pf1-f196.google.com [209.85.210.196]) by mail.openembedded.org (Postfix) with ESMTP id C04427931A for ; Mon, 10 Sep 2018 05:06:45 +0000 (UTC) Received: by mail-pf1-f196.google.com with SMTP id h69-v6so9840268pfd.4 for ; Sun, 09 Sep 2018 22:06:47 -0700 (PDT) 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; bh=p+sxttF17PTfCx3W8jnpjbZdkZl4bY+xY++WGJCXDmQ=; b=gYDPPHjf2l75V1/UAUEzk74JDPhHSr+TQOL6dr6+CNBmk+jYBwmlK8fFnk0kXBZrT4 zFgF/ekYorDhCYW1coIJ+ZZSB3XLDxnRsLFFegt4kTROMNZ+c5v9Pn8HaidLjbrEZEoO PxkgQ4hzsyE3NudsqpiKtq9ZpWt11bV3kCG1ygbBAViQqxlvjs8mktaMZmxwNpOM7wWN RevvcyJAzpWIPMP/YP5bTYPuc+tGZ2Qx5QXuQQoakXUAlIBNsLto7FPd8YiZ3M48CRnE vMZlcQ28WAZhK4PIDXDoUmf1OdBi5ZL53o0MDNdaokeAH/FJ8HdrMhtgX+XB4BiiXVPG ZgCg== 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=p+sxttF17PTfCx3W8jnpjbZdkZl4bY+xY++WGJCXDmQ=; b=QPsf+Ovb14lQNQIcvRBRfWJGL7ftpOrBY+omtkj/ovhGLgs5+l2t4b8W//AArG7B1I HzlhWSm3efbALZRBhzaOIBKZOc0o64EedZUpPwkfCcfByr3NR5taoHdOlw3sk5xvELNb GQbwCFvuOTHJJRUyJbVMzXvim/mn4Ae4ov4mKz7Hmb6tzpPrxB/TFH4Ht7uqDbyULU/w tAwyxXZ+OdG2HwSGC8KXkAnGsOJi5VYh2fLV488o5tZm8VRW9TSZuT69R8G41sPv8/Ne x1PGDCyLdxjKxwbgdyTT4szVPBJuwR7HV5kw3EAeUGFVJT5r6Pjr3D+SD8aO36D19JYx JzuQ== X-Gm-Message-State: APzg51CGgzGiTCfmv/gA/pp2DNu0ypK/i8Me9ny7ShMMtWpygOrH6NOe c7LF4QhEie/yjlkoYydhEFyNypIU X-Received: by 2002:a63:170b:: with SMTP id x11-v6mr19978061pgl.364.1536556006459; Sun, 09 Sep 2018 22:06:46 -0700 (PDT) Received: from localhost.localdomain ([2601:646:877f:9499::2887]) by smtp.gmail.com with ESMTPSA id x24-v6sm18819188pfh.67.2018.09.09.22.06.45 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Sun, 09 Sep 2018 22:06:45 -0700 (PDT) From: Khem Raj To: openembedded-devel@lists.openembedded.org Date: Sun, 9 Sep 2018 22:06:28 -0700 Message-Id: <20180910050629.16170-9-raj.khem@gmail.com> X-Mailer: git-send-email 2.18.0 In-Reply-To: <20180910050629.16170-1-raj.khem@gmail.com> References: <20180910050629.16170-1-raj.khem@gmail.com> Subject: [oe] [meta-oe][PATCH 09/10] libkcapi: Disable Wsign-compare warning with clang/musl 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: , MIME-Version: 1.0 Sender: openembedded-devel-bounces@lists.openembedded.org Errors-To: openembedded-devel-bounces@lists.openembedded.org clang 7.0 is grumpy and complains about cmsg structures and macros from sys/socket.h kcapi-kernel-if.c:25:11: error: comparison of integers of different signs: 'unsigned long' and 'long' [-Werror,-Wsign-compare] header = CMSG_NXTHDR(&msg, header); Signed-off-by: Khem Raj --- meta-oe/recipes-crypto/libkcapi/libkcapi_git.bb | 2 ++ 1 file changed, 2 insertions(+) -- 2.18.0 -- _______________________________________________ Openembedded-devel mailing list Openembedded-devel@lists.openembedded.org http://lists.openembedded.org/mailman/listinfo/openembedded-devel diff --git a/meta-oe/recipes-crypto/libkcapi/libkcapi_git.bb b/meta-oe/recipes-crypto/libkcapi/libkcapi_git.bb index addd169a8d..a93ddc8237 100644 --- a/meta-oe/recipes-crypto/libkcapi/libkcapi_git.bb +++ b/meta-oe/recipes-crypto/libkcapi/libkcapi_git.bb @@ -24,3 +24,5 @@ do_install_append() { # when no binaries are installed (empty bin_PROGRAMS in Makefile.am), rmdir --ignore-fail-on-non-empty ${D}${bindir} } + +CPPFLAGS_append_libc-musl_toolchain-clang = " -Wno-error=sign-compare" From patchwork Mon Sep 10 05:06:29 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Khem Raj X-Patchwork-Id: 146278 Delivered-To: patch@linaro.org Received: by 2002:a2e:1648:0:0:0:0:0 with SMTP id 8-v6csp2079157ljw; Sun, 9 Sep 2018 22:08:44 -0700 (PDT) X-Google-Smtp-Source: ANB0Vdas5WlZK3VXfuMvA9H902Ipv8y/Mseq3B4gu7jUmWkXusBKaz8rwigkj2qf/Hl9zqSF2572 X-Received: by 2002:a63:f043:: with SMTP id s3-v6mr20036921pgj.94.1536556124226; Sun, 09 Sep 2018 22:08:44 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1536556124; cv=none; d=google.com; s=arc-20160816; b=qW5yoKCimgM06PB2tvDQJ8FDJJD3EC77VNptBzmVPFDFoWn7S5+uQNve9gjpH21B+G LF0dEfZHocRjIS/pK9j8stkqs1+rSojagQA7aByhUwGMEWev+Scjr+HDy5yqnFp0VFzs fj+A5v6qIwxdXGI05RUMD/2YPpVNP11X2z1In3zRC8SWm1ioBlO3oRs6GdpYD5TMQEbp k6K6eHWOEtRqEUKbSi9GA+zf1sbhSRypg9TsFE714yUGPVOypU1XPIn9xn9ArcjgsTwO RlerCsX3nDbq1KoSpcPS8lgPf0g+uJuHe1SHI9lgX91rckpZkSxg4cM7x00LwyZZePQ4 4HyA== 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 :cc:mime-version:references:in-reply-to:message-id:date:to:from :dkim-signature:delivered-to; bh=O21yWjqVO6IZTDofT686+bXwfNmLHuoSgWxq0ZiEuU0=; b=JoYrEObgwTa9s8ICKZdnQcEb9nmZz3yoiySrZrKLHTTJD8dwuabJgZfUSQLlngcftY 2mcXnjJGh6ZTlTz823hUSUEDQZJqYEt3l93vuLFLbOszQG/XiosotQVH9FfrgWj1prhu cIcrMgf0fvfkjNWwLxi3bIlnGSJpHs5FeTeexOM+NXGybNHSWBTzO1gkoTmMoyx/tyNe oIQXeuvkYz6HIHFNw3MlHumeEhSBMCKCvqY40U5ARbXKqTk2druksNnWrT9FeN6BNvHh iY12QRMhxELA/OvyYgNdd0d4FdpoiqkuJewaYLBTaHVoDisYtFjNJIYdHDhV4fg5IHOu H4BA== ARC-Authentication-Results: i=1; mx.google.com; dkim=neutral (body hash did not verify) header.i=@gmail.com header.s=20161025 header.b=n8quAECa; 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 i135-v6si16067998pgc.154.2018.09.09.22.08.43; Sun, 09 Sep 2018 22:08:44 -0700 (PDT) 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=n8quAECa; 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 layers.openembedded.org (localhost [127.0.0.1]) by mail.openembedded.org (Postfix) with ESMTP id 648C979773; Mon, 10 Sep 2018 05:07:49 +0000 (UTC) X-Original-To: openembedded-devel@lists.openembedded.org Delivered-To: openembedded-devel@lists.openembedded.org Received: from mail-pg1-f171.google.com (mail-pg1-f171.google.com [209.85.215.171]) by mail.openembedded.org (Postfix) with ESMTP id E48F86007A for ; Mon, 10 Sep 2018 05:06:46 +0000 (UTC) Received: by mail-pg1-f171.google.com with SMTP id b129-v6so9797643pga.13 for ; Sun, 09 Sep 2018 22:06:48 -0700 (PDT) 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=dHQWh/BiJQaHl7zrJF1uPs1MKRH3v+F0o9cO+gbMvww=; b=n8quAECaQdZ/v10jBnhSl05MGjz8x73cMT57+ZL//1o2a7Q8s5OWNd8d43TFJnK8Sg ZI3OlyPijXiplPSGn1zJ1Q/89zNFueoZWf9R7sS1o6HAKZNDys1YfUxJO5k+hOyntAPj h/N0CPxjvacJU6KRispSX4NUim8NHQpgEIjJRYsFCDmRlkezKb7X7dJSO/P+NXAcxxTD 84MWgpp5ikoQus5kPpL33Eyg98MB2xaBo4bQiTxxDMqVoM2jo3urxXCk5j+1vIS7G2KL gSjBK8FRjvGMjR5B6eAlcuwR6e/7rFJOm+gJdSkNHQP47f1H14t9iv7Ij4dexBWfsJIB 97Zg== 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=dHQWh/BiJQaHl7zrJF1uPs1MKRH3v+F0o9cO+gbMvww=; b=V8zsovLtNOFkPRA6ZpLxCW9Iz2JHO+Odfu4QgLYLThE/TdXUmXmtQtlbjiSimzDn9o Y8K2MWEq3d4rtgJyit9eyYCUIDBZPhoNQJ0iyFv9i4DosHxLrSCbJkmn+tKKanXSDXpa F+qvVtD2kf/dNN1GD5qM6y9ecybHWu7LYo+iVBAYNA3GbBeQUW9xqZpAfy1ejBgYkguT y8+6VmGdhNLObB+fkSbs84PKOVa/7miBOv2pD5DIfm+GpWNHqcLSKQmhqJnuKQn80q+v L+3X0dZEyiwtlsDZfYyCdTZmses3xw7dQ2RHPuJheBkb4pvQS6FymVNvG2L91f9Z1aEE w11g== X-Gm-Message-State: APzg51CQG35y1MxMd/EOElmK4rbaMeCWYA3CwtiqygUAUtmDbDxcRY0t +qRKl3ZUiLRthVnSzCC+ZDF+poqk X-Received: by 2002:a63:e116:: with SMTP id z22-v6mr20342443pgh.89.1536556007596; Sun, 09 Sep 2018 22:06:47 -0700 (PDT) Received: from localhost.localdomain ([2601:646:877f:9499::2887]) by smtp.gmail.com with ESMTPSA id x24-v6sm18819188pfh.67.2018.09.09.22.06.46 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Sun, 09 Sep 2018 22:06:47 -0700 (PDT) From: Khem Raj To: openembedded-devel@lists.openembedded.org Date: Sun, 9 Sep 2018 22:06:29 -0700 Message-Id: <20180910050629.16170-10-raj.khem@gmail.com> X-Mailer: git-send-email 2.18.0 In-Reply-To: <20180910050629.16170-1-raj.khem@gmail.com> References: <20180910050629.16170-1-raj.khem@gmail.com> MIME-Version: 1.0 Cc: =?utf-8?q?Andreas_M=C3=BCller?= Subject: [oe] [meta-gnome][PATCH 10/10] evince: Fix build 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 The added patch aids clang to avoid format warnings Signed-off-by: Khem Raj Cc: Andreas Müller --- ...001-add-a-formatting-attribute-check.patch | 34 +++++++++++++++++++ .../recipes-gnome/evince/evince_3.28.2.bb | 1 + 2 files changed, 35 insertions(+) create mode 100644 meta-gnome/recipes-gnome/evince/evince/0001-add-a-formatting-attribute-check.patch diff --git a/meta-gnome/recipes-gnome/evince/evince/0001-add-a-formatting-attribute-check.patch b/meta-gnome/recipes-gnome/evince/evince/0001-add-a-formatting-attribute-check.patch new file mode 100644 index 0000000000..e87da90bce --- /dev/null +++ b/meta-gnome/recipes-gnome/evince/evince/0001-add-a-formatting-attribute-check.patch @@ -0,0 +1,34 @@ +From ef170dda7fbab53682c9bc287dec93fa86130bc9 Mon Sep 17 00:00:00 2001 +From: Khem Raj +Date: Sun, 9 Sep 2018 21:49:59 -0700 +Subject: [PATCH] add a formatting attribute check + +Tell Clang that parameter is a printf style format using the +attribute flag + +This helps in avoiding below warnings seen with clang + +unarr.c:106:22: error: format string is not a string literal +[-Werror,-Wformat-nonliteral] +| vfprintf(stderr, msg, args); +| ^~~ + +Upstream-Status: Pending +Signed-off-by: Khem Raj +--- + cut-n-paste/unarr/common/unarr.c | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/cut-n-paste/unarr/common/unarr.c b/cut-n-paste/unarr/common/unarr.c +index 97ec92a..9e6e3ad 100644 +--- a/cut-n-paste/unarr/common/unarr.c ++++ b/cut-n-paste/unarr/common/unarr.c +@@ -92,7 +92,7 @@ size_t ar_get_global_comment(ar_archive *ar, void *buffer, size_t count) + return ar->get_comment(ar, buffer, count); + } + +-void ar_log(const char *prefix, const char *file, int line, const char *msg, ...) ++void __attribute__((__format__ (__printf__, 4, 0))) ar_log(const char *prefix, const char *file, int line, const char *msg, ...) + { + va_list args; + va_start(args, msg); diff --git a/meta-gnome/recipes-gnome/evince/evince_3.28.2.bb b/meta-gnome/recipes-gnome/evince/evince_3.28.2.bb index c5b5484324..8bf8a04e2a 100644 --- a/meta-gnome/recipes-gnome/evince/evince_3.28.2.bb +++ b/meta-gnome/recipes-gnome/evince/evince_3.28.2.bb @@ -11,6 +11,7 @@ REQUIRED_DISTRO_FEATURES = "x11" SRC_URI = "${GNOME_MIRROR}/${GNOMEBN}/${@gnome_verdir("${PV}")}/${GNOMEBN}-${PV}.tar.${GNOME_COMPRESS_TYPE};name=archive \ file://0001-help-remove-YELP-macro.patch \ file://0001-Add-format-attribute-to-_synctex_malloc.patch \ + file://0001-add-a-formatting-attribute-check.patch \ " SRC_URI[archive.md5sum] = "66aa1766eaaa37536e48def11a0e67a3" SRC_URI[archive.sha256sum] = "0955d22d85c9f6d322b6cbb464f1cc4c352db619017ec95dad4cc5c3440f73e1"