Closed kindy closed 1 month ago
Let's limit it to a whitelist first? Currently it seems that supporting pkg-config
and llvm-config
is enough.
cgo also support pkg-config, it use pkg-config ...
as the cmd (instead of sh -c "pkg-config ..."
.
see https://github.com/golang/go/blob/go1.22.5/src/cmd/go/internal/work/exec.go#L1622-L1646
I'll try to fix this.
steps:
1) save _demo/hello/t.go
2) run
llgo run ./_demo/hello
will rm _demo/hello/hello.go.we can even
rm -rf /
impl in #269, related to #180
https://github.com/goplus/llgo/blob/2935ae7bf13f24e4cf3a6c71d7ebc432db02515d/internal/build/build.go#L270-L281
https://github.com/goplus/llgo/blob/2935ae7bf13f24e4cf3a6c71d7ebc432db02515d/xtool/env/env.go#L31-L41