From 28ccbeb7de18212954310588994058874fb180af Mon Sep 17 00:00:00 2001 From: Aaron Buchwald Date: Tue, 27 Oct 2020 14:04:01 -0400 Subject: Parse config to set enabled APIs --- scripts/build_coreth.sh | 22 ++++++++++++++++++++++ 1 file changed, 22 insertions(+) create mode 100755 scripts/build_coreth.sh (limited to 'scripts') diff --git a/scripts/build_coreth.sh b/scripts/build_coreth.sh new file mode 100755 index 0000000..41fab1b --- /dev/null +++ b/scripts/build_coreth.sh @@ -0,0 +1,22 @@ +#!/usr/bin/env bash + +set -o errexit +set -o nounset +set -o pipefail + +# Set GOPATH +GOPATH="$(go env GOPATH)" + +# Set default binary location +BINARY_PATH="$GOPATH/src/github.com/ava-labs/avalanchego/build/plugins/evm" + +if [[ $# -eq 1 ]]; then + BINARY_PATH=$1 +elif [[ $# -ne 0 ]]; then + echo "Invalid arguments to build coreth. Requires either no arguments (default) or one arguments to specify binary location." + exit 1 +fi + +# Build Coreth, which is run as a subprocess +echo "Building Coreth..." +go build -o "$BINARY_PATH" "plugin/"*.go -- cgit v1.2.3