Enhance the rebuild logic of the bootstrap
@DrXiao 已经在做这个了。
开始于 2026年10月18日。
评估
这个 Issue 还没有评估数据。
描述
On the latest master branch, running make always triggers a rebuild, even after the bootstrap process has completed:
# The first execution builds the stage 0 ~ stage 2 compilers. (Expected)
$ make
Target machine code switch to arm
CC out/src/main.o
...
Warning: discarding const qualifier in cast
# The second execution triggers a rebuild,
# even though ARCH/DYNLINK/BINDING remain unchanged. (Unexpected)
$ make
Target machine code switch to arm
CC out/src/main.o
...
Warning: discarding const qualifier in cast
Root cause
The current Makefile appears to have the following dependency relationships:
- The
alltarget relies on theconfigandbootstraptargets - The
configtarget is phony, so it runs every timemakeis invoked.- Each invocation of the
configtarget updates theconfigfile because theTRANSLATION_DEFSvariable differs between invocations.
https://github.com/sysprog21/shecc/blob/90c6e6870fd1e62f0234ad7d951d40c17c80f29e/Makefile#L176-L184
- Each invocation of the
- The
bootstraptarget indirectly depends on the auto-generatedconfigfile.
As a result, every invocation of make updates the config file, causing the bootstrap target to run again.
- 主要语言
- C
- 星标
- 1.4k
- 派生
- 168
- 平均合并
- 2 天 22 小时
- 30 天内合并 PR
- 3
环境准备
- 没有 Dockerfile 或 Docker Compose 文件
- 没有 Pull Request 模板
- 阅读贡献指南
从这里开始
- 先读完整个 Issue,再读项目的贡献指南。
- 在 Issue 下留言说明你要接手 —— 这能避免两个人做同样的事。
- Fork 仓库,在一个分支上完成修改。
- 提交 Pull Request,并在描述里引用这个 Issue 编号。
sysprog21/shecc 的其他 Issue
-
难度 4/5 3-5 天 新手友好度 38/100
-
enhancement
难度 5/5 一周以上 新手友好度 30/100
-
Import a GitHub Action for benchmarking purposes可能已有人在做 @DrXiao 于 443 天前认领。 未关闭
相似的 Issue
-
难度 2/5 1-3 小时 新手友好度 76/100
polhenarejos/pico-fido#302 ·
-
难度 2/5 1-3 小时 新手友好度 67/100
espressif/esp-vision#16 · 1 条评论 ·
-
难度 2/5 1-3 小时 新手友好度 74/100
libsdl-org/SDL#16577 ·
维护者通常 1 天内回复
-
难度 2/5 1-3 小时 新手友好度 66/100
维护者通常 1 天内回复
-
halt_error adds a trailing newline for non-string input, contrary to the manual可能已有人在做 @Huang-404-Q 今天认领。 未关闭
难度 1/5 1-3 小时 新手友好度 88/100
维护者通常 2 天内回复