From 8c2881324d2e98bbc876b84eddd58baa98d40121 Mon Sep 17 00:00:00 2001 From: Zhong Wang Date: Wed, 12 Aug 2015 15:06:08 +0000 Subject: Add native support for linux on ARM Cpu (32 bits) -- Change-Id: Ia70ca1b8482e10bc1ac91799aa238f8613e5c824 Reviewed-on: https://bazel-review.googlesource.com/#/c/1801 MOS_MIGRATED_REVID=100476467 --- third_party/BUILD | 6 ++++++ third_party/protobuf/README.md | 11 +++++++++++ 2 files changed, 17 insertions(+) (limited to 'third_party') diff --git a/third_party/BUILD b/third_party/BUILD index fd44a9cc1a..5c5928777f 100644 --- a/third_party/BUILD +++ b/third_party/BUILD @@ -14,6 +14,7 @@ filegroup( ":darwin": ["protobuf/protoc-osx-x86_32.exe"], ":k8": ["protobuf/protoc-linux-x86_64.exe"], ":piii": ["protobuf/protoc-linux-x86_32.exe"], + ":arm": ["protobuf/protoc-linux-arm32.exe"], }), ) @@ -369,3 +370,8 @@ config_setting( name = "piii", values = {"host_cpu": "piii"}, ) + +config_setting( + name = "arm", + values = {"host_cpu": "arm"}, +) diff --git a/third_party/protobuf/README.md b/third_party/protobuf/README.md index c46cf4a548..8e200e7da7 100644 --- a/third_party/protobuf/README.md +++ b/third_party/protobuf/README.md @@ -9,3 +9,14 @@ How to update these files: 7. Update third_party/BUILD to point to the new jar file. 8. Done. + +Because maven.org doesn't have a prebuilt binary for linux on ARM, you need to build the binary +yourself on the target system. Follow the build steps of protocol buffer to create the binary, +copy it to this directory and rename it to "protoc-linux-arm32.exe". + +For example: + +$ cp /usr/bin/protoc $BAZEL/third_party/protobuf/protoc-linux-arm32.exe + +This should be done before you run ./compile.sh. + -- cgit v1.2.3