Skip to content

Commit

Permalink
Build CLI with -tags 'netgo' (#128)
Browse files Browse the repository at this point in the history
By default we are relying on cgo for DNS resolution, which causes
binaries built on ubuntu 22.04 to break on ubuntu 20.04 due to some
changes in glibc. See golang/go#57328

This changes us to not rely on that, which causes builds to succeed.
  • Loading branch information
wkalt authored Sep 27, 2023
1 parent 0d032d9 commit 4b8acea
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions foxglove/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -15,11 +15,11 @@ version:
@echo VERSION=$(VERSION)

build: version
go build -ldflags "-X main.Version=$(VERSION)"
go build -tags 'netgo' -ldflags '-X main.Version=$(VERSION)'

build-release: version
mkdir -p bin
go build -ldflags "-X main.Version=$(VERSION)" -o bin/$(BINARY_NAME)
go build -tags 'netgo' -ldflags '-X main.Version=$(VERSION)' -o bin/$(BINARY_NAME)

install: version
go install -ldflags "-X main.Version=$(VERSION)"
go install -tags 'netgo' -ldflags '-X main.Version=$(VERSION)'

0 comments on commit 4b8acea

Please sign in to comment.