aaif-goose / aaif-goose/goose

Devcontainer build fails: libclang and cmake missing for llama-cpp-sys-2

Aperta
#11,992 0 commenti 0 reazioni 1 assegnatario Rivendicata da @jbg Vedi su GitHub
Lingua principale
Rust
Stelle
54.2k
Fork
6.2k
Merge medio
3g 2h
PR unite (30g)
262

Descrizione

**Describe the bug**

`.devcontainer` does not install `libclang-dev` or `cmake`. The `local-inference` feature builds `llama-cpp-sys-2`, whose build script runs bindgen and cmake, so `cargo build` in a fresh container fails:

```
thread 'main' panicked at bindgen-0.72.1/lib.rs:616:27:
Unable to find libclang: "couldn't find any valid shared libraries matching:
['libclang.so', 'libclang-*.so', 'libclang.so.*', 'libclang-*.so.*'], set the
`LIBCLANG_PATH` environment variable to a path where one of these files can be found"
```

The image ships `libclang-cpp19` (the C++ interface) but not `libclang-19-dev`, which provides the `libclang.so` that bindgen loads. rust-analyzer runs the same build script and crashes in a loop on it:

```
The Rust Analyzer Language Server server crashed 5 times in the last 3 minutes.
```

This also makes the `postCreateCommand: cargo build` fail on first container create.

---

**To Reproduce**
1. Open the repo in the devcontainer (`.devcontainer/Dockerfile`).
2. Run `cargo build`, or just wait for rust-analyzer to start.
3. See the bindgen panic above.

---

**Expected behavior**
A fresh devcontainer builds the workspace without extra manual setup.

---

**Please provide the following information**
- **OS & Arch:** Debian 13 (trixie) aarch64, in `.devcontainer`
- **Interface:** N/A (build)
- **Version:** main @ 9d166ecee
- **Extensions enabled:** N/A
- **Provider & Model:** N/A

---

**Additional context**
Adding `cmake` and `libclang-dev` to the existing `apt-get install` in `.devcontainer/Dockerfile` fixes both the build and the rust-analyzer crash. Verified in a running container. Happy to open the PR once this is Ready.

Guida per i contributori

Apri la guida per i contributori

Valutazione

Questa issue non è ancora stata valutata.

Ricevi le nuove issue nella tua casella

Un breve riepilogo di issue GitHub adatte ai principianti.