Skip to content

Commit f2b1a80

Browse files
committed
add macos codesigning of opm binary for apple silicon
Signed-off-by: Jordan Keister <[email protected]>
1 parent dc23843 commit f2b1a80

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

Makefile

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -55,6 +55,10 @@ $(CMDS):
5555
$(OPM): opm_version_flags=-ldflags "-X '$(PKG)/cmd/opm/version.gitCommit=$(GIT_COMMIT)' -X '$(PKG)/cmd/opm/version.opmVersion=$(OPM_VERSION)' -X '$(PKG)/cmd/opm/version.buildDate=$(BUILD_DATE)'"
5656
$(OPM):
5757
$(extra_env) $(GO) build $(opm_version_flags) $(extra_flags) $(TAGS) -o $@ ./cmd/$(notdir $@)
58+
ifeq ($(shell go env GOARCH),arm64)
59+
codesign --sign - --force --preserve-metadata=entitlements,requirements,flags,runtime $(OPM)
60+
endif
61+
5862

5963
.PHONY: build
6064
build: clean $(CMDS) $(OPM)

0 commit comments

Comments
 (0)