From 84a0d444532d2aedee9248b2e5e99b26bbb0273a Mon Sep 17 00:00:00 2001 From: James Alseth Date: Tue, 22 Jun 2021 15:15:57 -0700 Subject: [PATCH] Add binaries --- Makefile | 18 ++++++++++++++++++ README.md | 2 ++ main.go | 2 +- 3 files changed, 21 insertions(+), 1 deletion(-) diff --git a/Makefile b/Makefile index 323ccae..a9789d5 100644 --- a/Makefile +++ b/Makefile @@ -1,3 +1,21 @@ +UNAME := $(shell uname) + .PHONY: build build: go build -ldflags "-w -s" -o build/yubihsm-parse-attestation . + +.PHONY: build-xp +build-xp: + GOOS=darwin GOARCH=amd64 go build -ldflags "-w -s" -o build/yubihsm-parse-attestation_darwin_amd64 + GOOS=darwin GOARCH=arm64 go build -ldflags "-w -s" -o build/yubihsm-parse-attestation_darwin_arm64 + GOOS=linux GOARCH=amd64 go build -ldflags "-w -s" -o build/yubihsm-parse-attestation_linux_amd64 + GOOS=linux GOARCH=arm64 go build -ldflags "-w -s" -o build/yubihsm-parse-attestation_linux_arm64 + GOOS=windows GOARCH=amd64 go build -ldflags "-w -s" -o build/yubihsm-parse-attestation_windows_amd64.exe + +.PHONY: release +release: build-xp +ifeq ($(UNAME), Darwin) + cd build && shasum -a 256 yubihsm-parse-attestation_*64* > sha256sums +else + cd build && sha256sum yubihsm-parse-attestation_*64* > sha256sums +endif diff --git a/README.md b/README.md index 6256acd..5dc83d6 100644 --- a/README.md +++ b/README.md @@ -9,6 +9,8 @@ Parses the custom extensions on YubiHSM 2 attestation certificates and displays ## Installation +Binaries are available on the [Releases](https://github.com/YubicoLabs/yubihsm-parse-attestation/releases) page. You can also install from source using the command below. + ``` go install github.com/YubicoLabs/yubihsm-parse-attestation@latest ``` diff --git a/main.go b/main.go index 60b548a..15540dc 100644 --- a/main.go +++ b/main.go @@ -4,7 +4,7 @@ // you may not use this file except in compliance with the License. // You may obtain a copy of the License at -// http://www.apache.org/licenses/LICENSE-2.0 +// http://www.apache.org/licenses/LICENSE-2.0 // Unless required by applicable law or agreed to in writing, software // distributed under the License is distributed on an "AS IS" BASIS,