fix: preserve CGO_CFLAGS in build script (#8) (thanks @ramarivera)

This commit is contained in:
Peter Steinberger 2026-01-23 01:48:09 +00:00
parent 2d38976031
commit 2b4f1ff8eb
2 changed files with 5 additions and 1 deletions

View File

@ -6,6 +6,10 @@
- Start tracking changes for the next release (from 2026-01-23).
### Fixed
- Build: preserve existing `CGO_CFLAGS` when adding GCC 15+ workaround. (#8 — thanks @ramarivera)
## 0.1.0 - 2026-01-01
### Added

View File

@ -4,7 +4,7 @@
"packageManager": "pnpm@10.23.0",
"scripts": {
"wacli": "bash -lc 'pnpm -s build >/dev/null && exec ./dist/wacli \"$@\"' _",
"build": "mkdir -p dist && CGO_CFLAGS='-Wno-error=missing-braces' go build -tags sqlite_fts5 -o dist/wacli ./cmd/wacli",
"build": "mkdir -p dist && CGO_CFLAGS=\"${CGO_CFLAGS:+$CGO_CFLAGS }-Wno-error=missing-braces\" go build -tags sqlite_fts5 -o dist/wacli ./cmd/wacli",
"start": "pnpm -s build && ./dist/wacli",
"test": "pnpm -s test:go && pnpm -s test:fts",
"test:go": "go test ./...",