From patchwork Sun Oct 13 00:51:17 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Khem Raj X-Patchwork-Id: 176067 Delivered-To: patch@linaro.org Received: by 2002:a92:7e96:0:0:0:0:0 with SMTP id q22csp2716234ill; Sat, 12 Oct 2019 17:51:31 -0700 (PDT) X-Google-Smtp-Source: APXvYqzuMB07Z8aqEJ+1Dzv7T4SG/lIfaCp6j7itMsRBrGXpFQP0AD1BUoNen7+C1pCg95II0UAL X-Received: by 2002:a63:78f:: with SMTP id 137mr6631478pgh.110.1570927891697; Sat, 12 Oct 2019 17:51:31 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1570927891; cv=none; d=google.com; s=arc-20160816; b=JArxadXdBLtYjL3K8QGAojUmA5xhO9Rv1h8r5fA1bn+Zsd2+RQspFPiIOhEwN70nhN QvemHdMZKf2ZAy5D/QjcC8g3G7+xyNMrvAT3rK7fGUCgY1m81aZgX0RJUUnJMVQmePg2 3DdZ5+cYm0qo4WTJMAHXbZzkAfXzf3y3gUqBOL+pZZgBz9HgR8gBN0gK9fAFSR2ZKajY FXKR0Pk+ykdJhGKeWkBEesggzEXbXwxUOwacE8jOOdl1Xg8zOXrRfT8ff6n9dEul3cG1 qUGlx1kBO4savsWAWHHbZsZ8WOV24tT6rLZI77bc+/EZUWXkszu8mhVqGpBF1+2o1Jp1 CvmA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=errors-to:sender:content-transfer-encoding:list-subscribe:list-help :list-post:list-archive:list-unsubscribe:list-id:precedence:subject :mime-version:message-id:date:to:from:dkim-signature:delivered-to; bh=Rf61ptTWDX1Vzn4Lfm0dr5MbSlmT53XIP8oQhi34G2Q=; b=VxiQwgI6YUurVobQExJoq7EV4EnD4v0XoRIl+FQpEnclCt0RAGfAytRfBh7lstpjj2 S+dbdygn81OHoXSLem4nHfMlw2uetVEOnoVqG9AIgtaWOFFEQBJ8Q/STbZQ/Ku0YtIiL Cx3BYCOhmwKrhf5Fl1Bux4cAq5LZpx1OHHdQdcvnxNIjKW4s/CUR+yDVWyUyDa4gWGc/ xazbO+0rR4iRs847faDZx3RZFUnhXYLUQ4itJL0kcfUWzxz5bAwEnbOgswoGYdvzu3sd tIKWH9z4uMuGZRVYwhrcSJT1hEB0Q63UJF7MkDghAPJbWNEteyJB7+uPnkOHYwCNHPu8 7FbQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=neutral (body hash did not verify) header.i=@gmail.com header.s=20161025 header.b=I6xoSXbX; spf=pass (google.com: best guess record for domain of openembedded-core-bounces@lists.openembedded.org designates 140.211.169.62 as permitted sender) smtp.mailfrom=openembedded-core-bounces@lists.openembedded.org; dmarc=fail (p=NONE sp=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 o192si14373118pgo.289.2019.10.12.17.51.30; Sat, 12 Oct 2019 17:51:31 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of openembedded-core-bounces@lists.openembedded.org designates 140.211.169.62 as permitted sender) client-ip=140.211.169.62; Authentication-Results: mx.google.com; dkim=neutral (body hash did not verify) header.i=@gmail.com header.s=20161025 header.b=I6xoSXbX; spf=pass (google.com: best guess record for domain of openembedded-core-bounces@lists.openembedded.org designates 140.211.169.62 as permitted sender) smtp.mailfrom=openembedded-core-bounces@lists.openembedded.org; dmarc=fail (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Received: from ec2-34-214-78-129.us-west-2.compute.amazonaws.com (localhost [127.0.0.1]) by mail.openembedded.org (Postfix) with ESMTP id 2DE557F54F; Sun, 13 Oct 2019 00:51:27 +0000 (UTC) X-Original-To: openembedded-core@lists.openembedded.org Delivered-To: openembedded-core@lists.openembedded.org Received: from mail-pf1-f193.google.com (mail-pf1-f193.google.com [209.85.210.193]) by mail.openembedded.org (Postfix) with ESMTP id C75A57D534 for ; Sun, 13 Oct 2019 00:51:25 +0000 (UTC) Received: by mail-pf1-f193.google.com with SMTP id q21so8267576pfn.11 for ; Sat, 12 Oct 2019 17:51:27 -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:mime-version :content-transfer-encoding; bh=YuwNuLkodPP7b0SWTFc2BYN3VxTFbzHVC7hzH2klhw0=; b=I6xoSXbXRAngnznzDgVPR2a03cZa0dPYwdh9FfaxhpCMmh15fA6s+8wH1XkEXHdMCj 0siVAk6OE9qtt+p80ngnuUoHfBs7pgY6qVdjNxWmatgw08J63igmZN/MfVI7ObASG/FM 3yTg/1Fspf0oKlI+4dcNYtKNzTKs9AroaGLTivku0dSI3kwWbl/gJ+XFXpdTSW6WqKwk E3UkTjy12kp9271dOKdjL6WxynqxioDTmQkHaDIcmWwU8wO0Jc8/pbB5Lcp8dAKE7IQF WnUhHUpHlr9+hNpE7Guf7co6AMn/Q1RxHC7Z63Ehxy1+NWE6oeF15DQTG0XnAh4KDXGS uzZQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:mime-version :content-transfer-encoding; bh=YuwNuLkodPP7b0SWTFc2BYN3VxTFbzHVC7hzH2klhw0=; b=c0Lgu8oiLGqo6gxLmmMcPCSnDb7Y50uX++cpNKc+ClhSbQ5MJD+dvZbeBh3FQX38cv PFwoEYh/aPzcc9ydUtJQ/+3Ppkv6w//9Q8i0t5/pkX7Eer3jCs5vZc7zPuAvveFrSV71 E2H2q4Pfu0CIX6R3koU4E4dm0XK6QRaYOmcSf5mEMCf7siT6DwsUW1JAdULaYGk5LRRF 2DZ/ag+5gGc74b0xWt8jqjdBrAstcSEp8VyI7L/U/939rXhueUPsHmtukxx/dnkPIeYT Wn2joKjt5Qz2noaI0cT2RTEZXnYcFGD3JfFvC0II6HTaXYw98jNfwgOrtWAV8/LdMAfD n/Qg== X-Gm-Message-State: APjAAAV3qZ76fy5r4WbwYgPfrReQ3tZUZMsDP5rAgmOIvXXDTC3fxm9z RkEIXxOSLOHWBwkuNMB2DaXqc9iRCp4= X-Received: by 2002:a17:90a:cf8c:: with SMTP id i12mr26871518pju.77.1570927885851; Sat, 12 Oct 2019 17:51:25 -0700 (PDT) Received: from apollo.hsd1.ca.comcast.net ([2601:646:8500:1c20::7275]) by smtp.gmail.com with ESMTPSA id d1sm14629304pfc.98.2019.10.12.17.51.24 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sat, 12 Oct 2019 17:51:25 -0700 (PDT) From: Khem Raj To: openembedded-core@lists.openembedded.org Date: Sat, 12 Oct 2019 17:51:17 -0700 Message-Id: <20191013005117.841034-1-raj.khem@gmail.com> X-Mailer: git-send-email 2.23.0 MIME-Version: 1.0 Subject: [OE-core] [PATCH] glib-2.0: Fix build with clang compiler X-BeenThere: openembedded-core@lists.openembedded.org X-Mailman-Version: 2.1.12 Precedence: list List-Id: Patches and discussions about the oe-core layer List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: openembedded-core-bounces@lists.openembedded.org Errors-To: openembedded-core-bounces@lists.openembedded.org Signed-off-by: Khem Raj --- ...on-Run-atomics-test-on-clang-as-well.patch | 31 +++++++++++++++++++ meta/recipes-core/glib-2.0/glib-2.0_2.62.1.bb | 1 + 2 files changed, 32 insertions(+) create mode 100644 meta/recipes-core/glib-2.0/glib-2.0/0001-meson-Run-atomics-test-on-clang-as-well.patch -- 2.23.0 -- _______________________________________________ Openembedded-core mailing list Openembedded-core@lists.openembedded.org http://lists.openembedded.org/mailman/listinfo/openembedded-core diff --git a/meta/recipes-core/glib-2.0/glib-2.0/0001-meson-Run-atomics-test-on-clang-as-well.patch b/meta/recipes-core/glib-2.0/glib-2.0/0001-meson-Run-atomics-test-on-clang-as-well.patch new file mode 100644 index 0000000000..833ad2540e --- /dev/null +++ b/meta/recipes-core/glib-2.0/glib-2.0/0001-meson-Run-atomics-test-on-clang-as-well.patch @@ -0,0 +1,31 @@ +From cce617bec254e327ed7bcad60f58208024c6dc42 Mon Sep 17 00:00:00 2001 +From: Khem Raj +Date: Sat, 12 Oct 2019 17:46:26 -0700 +Subject: [PATCH] meson: Run atomics test on clang as well + +Fixes +./glib-2.62.1/glib/gatomic.c:675:2: error: G_ATOMIC_LOCK_FREE defined, but incapable of lock-free atomics. +^ + +Upstream-Status: Pending +Signed-off-by: Khem Raj +--- + meson.build | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/meson.build b/meson.build +index 9731de4..c678931 100644 +--- a/meson.build ++++ b/meson.build +@@ -1634,7 +1634,7 @@ atomicdefine = ''' + # We know that we can always use real ("lock free") atomic operations with MSVC + if cc.get_id() == 'msvc' or cc.get_id() == 'clang-cl' or cc.links(atomictest, name : 'atomic ops') + have_atomic_lock_free = true +- if cc.get_id() == 'gcc' and not cc.compiles(atomicdefine, name : 'atomic ops define') ++ if (cc.get_id() == 'gcc' or cc.get_id() == 'clang') and not cc.compiles(atomicdefine, name : 'atomic ops define') + # Old gcc release may provide + # __sync_bool_compare_and_swap but doesn't define + # __GCC_HAVE_SYNC_COMPARE_AND_SWAP_4 +-- +2.23.0 + diff --git a/meta/recipes-core/glib-2.0/glib-2.0_2.62.1.bb b/meta/recipes-core/glib-2.0/glib-2.0_2.62.1.bb index 6d841ec9d9..7897170a7d 100644 --- a/meta/recipes-core/glib-2.0/glib-2.0_2.62.1.bb +++ b/meta/recipes-core/glib-2.0/glib-2.0_2.62.1.bb @@ -14,6 +14,7 @@ SRC_URI = "${GNOME_MIRROR}/glib/${SHRT_VER}/glib-${PV}.tar.xz \ file://0010-Do-not-hardcode-python-path-into-various-tools.patch \ file://0001-Set-host_machine-correctly-when-building-with-mingw3.patch \ file://0001-Do-not-write-bindir-into-pkg-config-files.patch \ + file://0001-meson-Run-atomics-test-on-clang-as-well.patch \ " SRC_URI_append_class-native = " file://relocate-modules.patch"