From patchwork Mon May 21 17:53:07 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Charles Hardin X-Patchwork-Id: 917776 Return-Path: X-Original-To: incoming-buildroot@patchwork.ozlabs.org Delivered-To: patchwork-incoming-buildroot@bilbo.ozlabs.org Authentication-Results: ozlabs.org; spf=pass (mailfrom) smtp.mailfrom=busybox.net (client-ip=140.211.166.137; helo=fraxinus.osuosl.org; envelope-from=buildroot-bounces@busybox.net; receiver=) Authentication-Results: ozlabs.org; dmarc=none (p=none dis=none) header.from=storagecraft.com Received: from fraxinus.osuosl.org (smtp4.osuosl.org [140.211.166.137]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id 40qRGS38YMz9s19 for ; Tue, 22 May 2018 03:53:36 +1000 (AEST) Received: from localhost (localhost [127.0.0.1]) by fraxinus.osuosl.org (Postfix) with ESMTP id D80CF86946; Mon, 21 May 2018 17:53:32 +0000 (UTC) X-Virus-Scanned: amavisd-new at osuosl.org Received: from fraxinus.osuosl.org ([127.0.0.1]) by localhost (.osuosl.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id b1r8BRxglTcX; Mon, 21 May 2018 17:53:31 +0000 (UTC) Received: from ash.osuosl.org (ash.osuosl.org [140.211.166.34]) by fraxinus.osuosl.org (Postfix) with ESMTP id 11D2D85FA1; Mon, 21 May 2018 17:53:31 +0000 (UTC) X-Original-To: buildroot@lists.busybox.net Delivered-To: buildroot@osuosl.org Received: from hemlock.osuosl.org (smtp2.osuosl.org [140.211.166.133]) by ash.osuosl.org (Postfix) with ESMTP id 49E691C2040 for ; Mon, 21 May 2018 17:53:28 +0000 (UTC) Received: from localhost (localhost [127.0.0.1]) by hemlock.osuosl.org (Postfix) with ESMTP id 4724A88C4B for ; Mon, 21 May 2018 17:53:28 +0000 (UTC) X-Virus-Scanned: amavisd-new at osuosl.org Received: from hemlock.osuosl.org ([127.0.0.1]) by localhost (.osuosl.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id zEraEp6AZ0XX for ; Mon, 21 May 2018 17:53:27 +0000 (UTC) X-Greylist: from auto-whitelisted by SQLgrey-1.7.6 Received: from us-smtp-delivery-103.mimecast.com (us-smtp-delivery-103.mimecast.com [216.205.24.103]) by hemlock.osuosl.org (Postfix) with ESMTPS id 766B488DE1 for ; Mon, 21 May 2018 17:53:27 +0000 (UTC) Received: from STC-EXCH.stc.local (autodiscover.storagecraft.co.jp [198.135.233.15]) (Using TLS) by us-smtp-1.mimecast.com with ESMTP id us-mta-187-iJfZGZ_kNauHVcuHRvrprw-1; Mon, 21 May 2018 13:53:25 -0400 Received: from localhost.localdomain (50.1.97.2) by webmail.storagecraft.com (10.1.0.30) with Microsoft SMTP Server id 14.3.382.0; Mon, 21 May 2018 11:53:23 -0600 From: To: Date: Mon, 21 May 2018 10:53:07 -0700 Message-ID: <20180521175310.18563-3-charles.hardin@storagecraft.com> X-Mailer: git-send-email 2.15.1 (Apple Git-101) In-Reply-To: <20180521175310.18563-1-charles.hardin@storagecraft.com> References: <20180521175310.18563-1-charles.hardin@storagecraft.com> MIME-Version: 1.0 X-MC-Unique: iJfZGZ_kNauHVcuHRvrprw-1 Subject: [Buildroot] [PATCH v2 2/5] package/protobuf: add a patch for mips big endian X-BeenThere: buildroot@busybox.net X-Mailman-Version: 2.1.24 Precedence: list List-Id: Discussion and development of buildroot List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Charles Hardin Errors-To: buildroot-bounces@busybox.net Sender: "buildroot" From: Charles Hardin This patch got submitted as a pull upstream, but hasn't been approved or yanked in yet. So, adding it here for now until an upstream solution is determined. Signed-off-by: Charles Hardin --- ...w-a-compilation-under-mips-big-endian-wit.patch | 38 ++++++++++++++++++++++ 1 file changed, 38 insertions(+) create mode 100644 package/protobuf/0001-Fix-to-allow-a-compilation-under-mips-big-endian-wit.patch diff --git a/package/protobuf/0001-Fix-to-allow-a-compilation-under-mips-big-endian-wit.patch b/package/protobuf/0001-Fix-to-allow-a-compilation-under-mips-big-endian-wit.patch new file mode 100644 index 0000000000..b98a459be8 --- /dev/null +++ b/package/protobuf/0001-Fix-to-allow-a-compilation-under-mips-big-endian-wit.patch @@ -0,0 +1,38 @@ +From d105213bccfa4392eda889a95f808dd9cdf84494 Mon Sep 17 00:00:00 2001 +From: Charles Hardin +Date: Mon, 21 May 2018 09:19:30 -0700 +Subject: [PATCH 1/1] Fix to allow a compilation under mips big endian with gcc + +The __MIPSEL__ is mips little endian, specific and we needed +to compile for a big endian mips target that also happened +to be a mips64, so replaced the __MIPSEL__ with a __mip__ +which should preserve the build on little endian and allow a +build for a big endian setup. + + $ echo | mips64-linux-gcc -E -dM - + ... snip snip ... + #define __mips__ 1 + #define __MIPSEB__ 1 + +Signed-off-by: Charles Hardin +Signed-off-by: Charles Hardin +--- + src/google/protobuf/stubs/platform_macros.h | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/src/google/protobuf/stubs/platform_macros.h b/src/google/protobuf/stubs/platform_macros.h +index c3a64dd2..f9e2bff6 100644 +--- a/src/google/protobuf/stubs/platform_macros.h ++++ b/src/google/protobuf/stubs/platform_macros.h +@@ -56,7 +56,7 @@ + #elif defined(__aarch64__) + #define GOOGLE_PROTOBUF_ARCH_AARCH64 1 + #define GOOGLE_PROTOBUF_ARCH_64_BIT 1 +-#elif defined(__MIPSEL__) ++#elif defined(__mips__) + #if defined(__LP64__) + #define GOOGLE_PROTOBUF_ARCH_MIPS64 1 + #define GOOGLE_PROTOBUF_ARCH_64_BIT 1 +-- +2.15.1 (Apple Git-101) +