最近给专门为 C++模块化打造的构建工具增加了 gcc16/mingw 支持,欢迎体验 mcpp
mcpp 构建工具增加了更多工具链的支持,目前已经覆盖主流的 Linux/macOS/Windows,支持部分跨 CPU 架构和操作系统的交叉编译构建 C++ 项目,欢迎大家体验反馈。
- **mcpp 项目**: [https://github.com/mcpp-community/mcpp](https://github.com/mcpp-community/mcpp)
---
## 最小验证 + 支持的工具链集合
```bash
mcpp new hello && cd hello
mcpp build --target x86_64-windows-gnu
wine target/../hello.exe
```
---
| Target | Convention toolchain | Status |
|---------------------------|---------------------------------------------------------------------------|--------|
| `x86_64-linux-gnu` | gcc *(Linux default)* or llvm | ✅ |
| `x86_64-linux-musl` | gcc 16, fully static | ✅ |
| `aarch64-linux-musl` | gcc 16, fully static — cross from x86_64 (qemu-verified) or native | ✅ |
| `x86_64-windows-gnu` | gcc 16 MinGW-w64 — native on Windows, cross from Linux (wine-verified)| ✅ |
| `x86_64-windows-msvc` | `msvc@system` (detected VS/BuildTools) or llvm *(Windows default)* | ✅ |
| `aarch64-macos` | llvm *(macOS default)* | ✅ |
| `riscv64-linux-musl` | — | 🔄 |
| `aarch64-linux-gnu` | — | 🔄 |
| `x86_64-macos` | — | 🔄 |
✅ verified — CI builds **and executes** the artifact end-to-end (qemu/wine included) | 🔄 planned
---
原文链接:[点击查看](https://www.v2ex.com/t/1227579)
- **mcpp 项目**: [https://github.com/mcpp-community/mcpp](https://github.com/mcpp-community/mcpp)
---
## 最小验证 + 支持的工具链集合
```bash
mcpp new hello && cd hello
mcpp build --target x86_64-windows-gnu
wine target/../hello.exe
```
---
| Target | Convention toolchain | Status |
|---------------------------|---------------------------------------------------------------------------|--------|
| `x86_64-linux-gnu` | gcc *(Linux default)* or llvm | ✅ |
| `x86_64-linux-musl` | gcc 16, fully static | ✅ |
| `aarch64-linux-musl` | gcc 16, fully static — cross from x86_64 (qemu-verified) or native | ✅ |
| `x86_64-windows-gnu` | gcc 16 MinGW-w64 — native on Windows, cross from Linux (wine-verified)| ✅ |
| `x86_64-windows-msvc` | `msvc@system` (detected VS/BuildTools) or llvm *(Windows default)* | ✅ |
| `aarch64-macos` | llvm *(macOS default)* | ✅ |
| `riscv64-linux-musl` | — | 🔄 |
| `aarch64-linux-gnu` | — | 🔄 |
| `x86_64-macos` | — | 🔄 |
✅ verified — CI builds **and executes** the artifact end-to-end (qemu/wine included) | 🔄 planned
---
原文链接:[点击查看](https://www.v2ex.com/t/1227579)
· 0 个赞