nodejs / nodejs/node

Vendored LIEF fails to build with Clang 22

未关闭 适合新手
#63,530 5 条评论 1 个 reaction 已指派 0 人 在 GitHub 查看

还没有人认领这个 Issue。

stale
主要语言
JavaScript
星标
122k
派生
37.4k
平均合并
4 天 3 小时
30 天内合并 PR
272

描述

Version

26.2.0

Platform
macOS 14, 15
Subsystem

No response

What steps will reproduce the bug?

./configure && make

How often does it reproduce? Is there a required condition?

Always

What is the expected behavior? Why is that the expected behavior?

Build succeeds

What do you see instead?
../deps/LIEF/third-party/spdlog/include/spdlog/fmt/bundled/format.h:747:28: error: use of undeclared identifier 'malloc'
  747 |     T* p = static_cast<T*>(malloc(n * sizeof(T)));
../deps/LIEF/third-party/spdlog/include/spdlog/fmt/bundled/format.h:752:35: error: call to function 'free' that is neither visible in the template definition nor found by argument-dependent lookup
  752 |   void deallocate(T* p, size_t) { free(p); }
Additional information

This has already been fixed in spdlog to have the correct includes.

贡献指南

打开贡献指南

从这里开始

  1. 先读完整个 Issue,再读项目的贡献指南。
  2. 在 Issue 下留言说明你要接手 —— 这能避免两个人做同样的事。
  3. Fork 仓库,在一个分支上完成修改。
  4. 提交 Pull Request,并在描述里引用这个 Issue 编号。

调研方向

从 deps/LIEF/third-party/spdlog/include/spdlog/fmt/bundled/format.h 开始,在使用 Clang 22 的 macOS 上通过 ./configure && make 重现失败。将 vendored 代码与链接中的 spdlog 修复进行比较,确认其是否解决了缺失的 allocation-function includes,然后验证构建是否成功。

由索引模型根据 Issue 内容生成。

评估

技术栈
cpp
领域
build-system
Issue 类型
缺陷
难度
2/5
预计耗时
1-3 小时
活跃度
活跃
描述清晰度
基本清楚
新手友好度
68/100

把新 issue 发到你的邮箱

精选适合新手参与的 GitHub issue 摘要。