Files
zeekay 2ad572214c capi: //go:embed include/lux/accel/c_api.h so vendor tools carry it
go mod vendor strips non-Go files unless something references them
through //go:embed. Downstream consumers (luxfi/kms, luxfi/node) use
go mod vendor and were getting a header-less vendor tree, breaking
the same fresh-clone build that v1.1.7's CFLAGS fix was supposed to
solve. Embed makes vendor preserve the header.

The embedded value is unused at runtime — pure side-effect to keep
the file on disk.
2026-06-01 21:58:55 -07:00

19 lines
628 B
Go

//go:build cgo
// Package capi — embed the public C header so `go mod vendor` carries it
// into downstream consumers' vendor trees. Without an embed reference, the
// vendor tool strips non-Go files from internal/capi/include/, breaking
// fresh-clone builds of vendored consumers (luxfi/kms, luxfi/node).
//
// The embedded file is the same physical header that capi.go's CFLAGS
// `-I${SRCDIR}/include` exposes to cgo; we just need the embed directive
// so the build system keeps it on disk after vendoring.
package capi
import _ "embed"
//go:embed include/lux/accel/c_api.h
var _cApiHeader string
var _ = _cApiHeader