From patchwork Sat Sep 15 08:11:54 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Khem Raj X-Patchwork-Id: 146767 Delivered-To: patch@linaro.org Received: by 2002:a2e:1648:0:0:0:0:0 with SMTP id 8-v6csp1564690ljw; Sat, 15 Sep 2018 01:12:11 -0700 (PDT) X-Google-Smtp-Source: ANB0VdZMphPly//mu5BTS/F7CEC3a/ax+eVZYESJKVuflcTEJRo9fjv0ltxOkaS/1eVjPNZLqlbd X-Received: by 2002:a62:435c:: with SMTP id q89-v6mr16428040pfa.135.1536999131030; Sat, 15 Sep 2018 01:12:11 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1536999131; cv=none; d=google.com; s=arc-20160816; b=hRCRrwAgMk52iOa4gCXl0PxRaZgxbCsDxMnbEEt97B9rYBK/PncPT57lBsFkJypi6h Wi4ZhNZOttRmjD+YvP0/cmGivMLQrrRgVbN4PGNsiGBnSUNZlqomJ0pywVPPuvW9z6Q3 nUsV7mFvate4RNUzlEqK1qk7VlyOj4JKbct3ut07nzrgPssbMflpTONYbtTzEyViR0ez pkMLhO6thx9pVs3/pHlIG2pmdkyuRoU0NfUildFd5BK+9VlX1LsnlJSCHGeBABJ01iHq wRWZtS71GzGcZ8MsMGGFlQYwaFqjdv/ecbjMKlRzXlMvMFvXRLcAgj7kMPYuOASOjNe/ m/VQ== 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=8NN+FglXQejxFxqwHR4/regU0j9nis2YvLr3+zoDXkM=; b=cPE1A0YfyQ4dKmDjiEwZ1+mTwcPmrJ3ykiecyPzW04ZU/GO7dcC6sTgR7h+c0SigRJ HItRgcLs6N9a6beIoiGk9zti1oduK+jAeO+waT839LBOG6K5FS/ZPZJIp8Ec3uMPSWoR pmdZUTdyzNtTvqsHnqAjoUtYxJmD7V9lCXvhcNARCtZo+hYKJLE5MuVvTYsZkcHV6H9K A+OovA3C+MdcywNWj1/BiDbaiL/zCmzAKr+PfcsKcVrsg6iaSB2EXX13BnGxd6ReP972 CvTBOew/YWPShjwvnbSsCGs1YRElAKpiBEN8+TYtt29PKe6PjIEqst0LBKFLWnBr4vHk 3AIg== ARC-Authentication-Results: i=1; mx.google.com; dkim=neutral (body hash did not verify) header.i=@gmail.com header.s=20161025 header.b=G5R+jv7Y; 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 184-v6si8837249pgb.587.2018.09.15.01.12.10; Sat, 15 Sep 2018 01:12:11 -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=G5R+jv7Y; 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 layers.openembedded.org (localhost [127.0.0.1]) by mail.openembedded.org (Postfix) with ESMTP id A58F27992E; Sat, 15 Sep 2018 08:12:05 +0000 (UTC) X-Original-To: openembedded-core@lists.openembedded.org Delivered-To: openembedded-core@lists.openembedded.org Received: from mail-pl1-f194.google.com (mail-pl1-f194.google.com [209.85.214.194]) by mail.openembedded.org (Postfix) with ESMTP id 81BE2794F5 for ; Sat, 15 Sep 2018 08:12:03 +0000 (UTC) Received: by mail-pl1-f194.google.com with SMTP id s17-v6so5196915plp.7 for ; Sat, 15 Sep 2018 01:12:04 -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=lE7zo6QGoCcYuC63T7S7LHCh5Rg2ff/CPjPCbZA1ztM=; b=G5R+jv7YiUKQoVvE8MBrOSNmAJQjw8e9R418vLeg1HgmzyKmSYNGNiUoaD5vWo/qRD CGyue5rJpCIu4fTkkFgl9cz/tUcIwhEJqTZCfryctuDXN5aGLOASs+bQ68R/Kvt8BdKJ JgIm5yrafwePUEXjsHd+Bp7XJ57KJOj4PrBv1ZGv2iElYW/AY5d0DRNlUsZetdGFmXFb Wq/44KIedKABPWOad4/mJBNfVAfKf7dBVYa+8xHdTY109VcmyHE9cIq9anylZ6rchYrG o4yBj5Xv5C1UGpy79hzZG0MByQrXgKUS0ys1YkUwVtecTZ2mAcxG8ZhP/DiLT8obY3kE J6FA== 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=lE7zo6QGoCcYuC63T7S7LHCh5Rg2ff/CPjPCbZA1ztM=; b=bJX5aR7NFJijYY6xcEd7nRBX09bG1sRRK57mNykB5lN39c/QTaYHgtittASsd5UDy5 Dzoh0soR8OAFFCECYZYW8eoFzCt0G1/8ZpmmLAsFXiwNW6t9WJ3KCyPmoV2m33ux03PW HyyGaJy2BLbg+s6KLfb2ZFjGaB3esZlRgZHcrsNLQeS7iquhB/tbZ3WXok9Y93suQpIZ InpZV5zwuJKet6q0qYRVeuyVERa2VYXn/Yqu4bg3wJ5lYpytV+jYHepDOxCq1W3rsBcv KW+jdtPOL5wH9tNdaHUlfU0taHJTWjGXIQ2h3QKtPRxRU9k36n4z6mtqrfPcPs7ZTU9k lugA== X-Gm-Message-State: APzg51DHhNMoFOGRBgDnP+WCs+GrfcKRWkSp3yJ7INY/tmhMngio6gY0 zG7QIum5Py6bxAuFtInJeQ4n8lF3 X-Received: by 2002:a17:902:b60b:: with SMTP id b11-v6mr15166690pls.301.1536999124018; Sat, 15 Sep 2018 01:12:04 -0700 (PDT) Received: from localhost.localdomain ([2601:646:877f:9499::b1b1]) by smtp.gmail.com with ESMTPSA id p4-v6sm12198424pfb.180.2018.09.15.01.12.03 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Sat, 15 Sep 2018 01:12:03 -0700 (PDT) From: Khem Raj To: openembedded-core@lists.openembedded.org Date: Sat, 15 Sep 2018 01:11:54 -0700 Message-Id: <20180915081154.28018-1-raj.khem@gmail.com> X-Mailer: git-send-email 2.19.0 MIME-Version: 1.0 Subject: [OE-core] [PATCH] mtools: Fix build with clang 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 Identify with __clang__ to undefine UNUSED Signed-off-by: Khem Raj --- .../mtools/mtools/clang_UNUSED.patch | 17 +++++++++++++++++ meta/recipes-devtools/mtools/mtools_4.0.18.bb | 1 + 2 files changed, 18 insertions(+) create mode 100644 meta/recipes-devtools/mtools/mtools/clang_UNUSED.patch -- 2.19.0 -- _______________________________________________ Openembedded-core mailing list Openembedded-core@lists.openembedded.org http://lists.openembedded.org/mailman/listinfo/openembedded-core diff --git a/meta/recipes-devtools/mtools/mtools/clang_UNUSED.patch b/meta/recipes-devtools/mtools/mtools/clang_UNUSED.patch new file mode 100644 index 0000000000..6bb9d6a3da --- /dev/null +++ b/meta/recipes-devtools/mtools/mtools/clang_UNUSED.patch @@ -0,0 +1,17 @@ +Undefine UNUSED macros with clang + +Upstream-Status: Pending +Signed-off-by: Khem Raj +Index: mtools-4.0.18/sysincludes.h +=================================================================== +--- mtools-4.0.18.orig/sysincludes.h ++++ mtools-4.0.18/sysincludes.h +@@ -101,7 +101,7 @@ typedef void *caddr_t; + #if defined __GNUC__ && defined __STDC__ + /* gcc -traditional doesn't have PACKED, UNUSED and NORETURN */ + # define PACKED __attribute__ ((packed)) +-# if __GNUC__ == 2 && __GNUC_MINOR__ > 6 || __GNUC__ >= 3 ++# if (__GNUC__ == 2 && __GNUC_MINOR__ > 6 || __GNUC__ >= 3) && !defined(__clang__) + /* gcc 2.6.3 doesn't have "unused" */ /* mool */ + # define UNUSED(x) x __attribute__ ((unused));x + # define UNUSEDP __attribute__ ((unused)) diff --git a/meta/recipes-devtools/mtools/mtools_4.0.18.bb b/meta/recipes-devtools/mtools/mtools_4.0.18.bb index 91f7b7c610..3c31aca3ad 100644 --- a/meta/recipes-devtools/mtools/mtools_4.0.18.bb +++ b/meta/recipes-devtools/mtools/mtools_4.0.18.bb @@ -32,6 +32,7 @@ SRC_URI = "${GNU_MIRROR}/mtools/mtools-${PV}.tar.bz2 \ file://no-x11.gplv3.patch \ file://0001-Continue-even-if-fs-size-is-not-divisible-by-sectors.patch \ file://0001-remove-LOCK_NB-to-use-blocking-request.patch \ + file://clang_UNUSED.patch \ " SRC_URI_append_class-native = " file://disable-hardcoded-configs.patch"