riddler: pass -trimpath to build

To fix most of the TMPDIR references, we pass -trimpath to the build
via a new variagle GOBUILDFLAGS.

There are still some debug references to TMDIR, that will be fixed
at a later time.

Signed-off-by: Bruce Ashfield <bruce.ashfield@gmail.com>
This commit is contained in:
Bruce Ashfield 2022-09-13 15:04:51 -04:00
parent e167860a87
commit e465ef7dcd
2 changed files with 3 additions and 2 deletions

View File

@ -17,12 +17,12 @@ index c6976af..f3c8d17 100644
build:
@echo "+ $@"
- @go build -tags "$(BUILDTAGS) cgo" .
+ @${GO} build -tags "$(BUILDTAGS) cgo" .
+ @${GO} build ${GOBUILDFLAGS} -tags "$(BUILDTAGS) cgo" .
static:
@echo "+ $@"
- CGO_ENABLED=1 go build -tags "$(BUILDTAGS) cgo static_build" -ldflags "-w -extldflags -static" -o riddler .
+ CGO_ENABLED=1 ${GO} build -tags "$(BUILDTAGS) cgo static_build" -ldflags "-w -extldflags -static" -o riddler .
+ CGO_ENABLED=1 ${GO} build ${GOBUILDFLAGS} -tags "$(BUILDTAGS) cgo static_build" -ldflags "-w -extldflags -static" -o riddler .
fmt:
@echo "+ $@"

View File

@ -47,6 +47,7 @@ do_compile() {
export CGO_CFLAGS="${TARGET_CFLAGS}"
export CGO_LDFLAGS="${TARGET_LDFLAGS}"
export GO111MODULE=off
export GOBUILDFLAGS="-trimpath"
cd ${S}/src/import