Fix unreliable GOOS detection

pull/3763/head
cyqsimon 2 weeks ago
parent 260a65b0fb
commit e0acc15214
No known key found for this signature in database
GPG Key ID: 1D8CE2F297390D65

@ -1,6 +1,6 @@
SHELL := bash
GO ?= go
GOOS ?= $(word 1, $(subst /, " ", $(word 4, $(shell go version))))
GOOS ?= $(shell $(GO) version | sed -E 's|^(.* )?([a-zA-Z0-9\-_]+)/[a-zA-Z0-9\-_]+( .*)?$$|\2|')
MAKEFILE := $(realpath $(lastword $(MAKEFILE_LIST)))
ROOT_DIR := $(shell dirname $(MAKEFILE))

Loading…
Cancel
Save