Skip to content

llvm全平台适配 - linux/macos/windows #48

Description

@Sunrisepeak
No description provided.

Activity

  1. Sunrisepeak commented on May 16, 2026

    @Sunrisepeak
    MemberAuthor

    macos-todo

        f.ld = std::format("{}{}{}{}{}", full_static, static_stdlib, sysroot_flag, b_flag,
                           runtime_dirs);
    #if defined(__APPLE__)
        // macOS: explicitly link libc++ — xlings LLVM's cfg uses -nostdinc++
        // which may suppress the implicit -lc++ that clang++ normally adds.
        std::string stdlib_link = isClang ? " -lc++" : "";
    #else
        std::string stdlib_link;
    #endif
        f.ld = std::format("{}{}{}{}{}{}", full_static, static_stdlib, sysroot_flag, b_flag,
                           runtime_dirs, stdlib_link);
    
  2. speak-agent commented on Jul 30, 2026

    @speak-agent
    Member

    已完成,关闭。

    LLVM 三平台适配早已闭环:

    • 构建/测试面 — ci-linux.yml / ci-macos.yml / ci-windows.yml 各带 e2e 分支(ci-*-e2e.yml),Windows 侧另有 LLVM/Clang + MSVC STL 全链(PR feat: Windows support — LLVM/Clang + MSVC STL + full CI pipeline #52),macOS 侧 bootstrap-macos.yml。
    • 工具链面 — mcpp toolchain install llvm <ver> 在三平台可用;msvc@system 作为 Windows 的 detection-first 系统工具链(0.0.88),MinGW 族与 Linux→Windows 交叉链(0.0.92)也已进生态。
    • 本 issue 评论里记的 macos-todo(clang 在 -nostdinc++ cfg 下需显式 -lc++)已实现:src/build/flags.cppm:538-539 的 ldStdlibDefault / ldStdlibTest;链接期的 -lSystem 问题另见 NULL (保留) #43。

    后续单独的 LLVM 相关缺陷各自有独立 issue(如 #259 裸机 runner 上 llvm payload 的 glibc 运行期依赖、#256 clang 20/22 的模块 BMI 前端崩溃),不再由本 issue 汇总。

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions