Use arduino/setup-protoc for installing Protoc (#903)

Co-authored-by: Azeem Shaikh <azeems@google.com>
This commit is contained in:
Azeem Shaikh 2021-08-25 06:31:04 -07:00 committed by GitHub
parent 8cf95c46e4
commit cc30d54db2
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 4 additions and 26 deletions

View File

@ -16,32 +16,11 @@ name: build
on: [push, pull_request]
jobs:
validate:
name: Validate
name: Validate
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@5a4ac9002d0be2fb38bd78e4b4dbde5606d7042f
- name: Cache protobuf library.
id: cache-protobuf
uses: actions/cache@d9747005de0f7240e5d35a68dca96b3f41b8b340
with:
path: protobuf
key: ${{ runner.os }}-protobuf
- name: Build protobuf library.
if: steps.cache-protobuf.outputs.cache-hit != 'true'
run: |
git clone https://github.com/protocolbuffers/protobuf.git
cd protobuf
git submodule update --init --recursive
./autogen.sh
./autogen.sh # see https://github.com/protocolbuffers/protobuf/issues/149
./configure
make
make check
- name: Install protobuf library
run: |
cd protobuf
sudo make install
sudo ldconfig
- name: Install Protoc
uses: arduino/setup-protoc@v1
- name: Clone the code
uses: actions/checkout@5a4ac9002d0be2fb38bd78e4b4dbde5606d7042f # v2.3.4
with:

View File

@ -78,8 +78,7 @@ tree-status: ## Verify tree is clean and all changes are committed
###############################################################################
################################## make build #################################
# TODO(azeems): Re-enable build-proto
build-targets = generate-docs build-scorecard build-pubsub build-bq-transfer \
build-targets = generate-docs build-proto build-scorecard build-pubsub build-bq-transfer \
build-add-script build-validate-script build-update-script dockerbuild
.PHONY: build $(build-targets)
build: ## Build all binaries and images in the reepo.