Skip to content

Commit 1abd053

Browse files
Fix make build_release
Signed-off-by: Julien Barbot <[email protected]>
1 parent 479b64e commit 1abd053

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

Makefile

+4-4
Original file line numberDiff line numberDiff line change
@@ -4,9 +4,9 @@
44
# Build settings
55
TYK_VERSION ?= v5.8.0
66
# Options: linux, darwin
7-
TARGET_OS ?= darwin
7+
TARGET_OS ?= $(shell go env GOOS)
88
# Options: amd64, arm64
9-
TARGET_ARCH ?= arm64
9+
TARGET_ARCH ?= $(shell go env GOARCH)
1010

1111
# Version for https://github.com/kelindar/search.git
1212
SEARCH_VERSION := v0.4.0
@@ -16,7 +16,7 @@ SEARCH_LIB ?= libllama_go.dylib
1616
PLUGIN_NAME := agent-bridge-plugin
1717
FULL_PLUGIN_NAME := $(PLUGIN_NAME)_$(TYK_VERSION)_$(TARGET_OS)_$(TARGET_ARCH)
1818
TYK_COMPILER_IMAGE_PLATFORM := linux/amd64
19-
TYK_COMPILER_IMAGE := tykio/tyk-plugin-compiler:v$(TYK_VERSION)
19+
TYK_COMPILER_IMAGE := tykio/tyk-plugin-compiler:$(TYK_VERSION)
2020

2121
PROJECT_ROOT := $(dir $(abspath $(lastword $(MAKEFILE_LIST))))
2222
REQUIRED_BINS := docker go git curl jq cmake
@@ -41,7 +41,7 @@ build_release:
4141
docker run --rm \
4242
--platform=$(TYK_COMPILER_IMAGE_PLATFORM) \
4343
--mount type=bind,src=./plugins,dst=/plugin-source \
44-
$(TYK_COMPILER_IMAGE) $(PLUGIN_NAME) _$$(date +%s) $(TARGET_OS) $(TARGET_ARCH)
44+
$(TYK_COMPILER_IMAGE) $(PLUGIN_NAME) _$$(date +%s)
4545

4646
test: search-release-$(SEARCH_VERSION)/build/lib/$(SEARCH_LIB)
4747
$(LIB_ENV_VAR)=$(PROJECT_ROOT)/search-release-$(SEARCH_VERSION)/build/lib go test -v ./plugins

0 commit comments

Comments
 (0)