tinygo-org / tinygo

Go compiler for small places. Microcontrollers, WebAssembly (WASM/WASI), and command-line tools. Based on LLVM.
https://tinygo.org
Other
14.73k stars 859 forks source link

Error to find build id on OpenBSD #4238

Open lcheylus opened 2 months ago

lcheylus commented 2 months ago

I'm trying to build and port tinygo on OpenBSD (current version on amd64).

$ export CC=clang $ export CXX=clang++ $ gmake (...) $ ./build/tinygo version tinygo version 0.32.0-dev-90b0bf64 openbsd/amd64 (using go version go1.22.2 and LLVM version 17.0.1)


When I try to build/run a Go binary from sources (here with a simple `hello_world` code), I have an error to find build id:
```bash
$ ./build/tinygo build -o ~/tmp/hello ~/tmp/hello_world.go
error: could not find build id in /home/<user>/dev/tinygo.git/./build/tinygo

After some debug, the case for OpenBSD is not handled in builder/buildid.go, function ReadBuildID.