Commit 01e8a11
profile compile: stage wrapper config.nims at the profile dir (#13)
When repro_profile_compile invokes nim against a profile that lives
outside the reprobuild source tree (e.g. C:\Users\admin\reprobuild-source\
on a Windows runner), nim's parent-walk for config.nims never reaches
<repoRoot>/config.nims and the sibling-repo paths (NIMCRYPTO_SRC,
BEARSSL_SRC, IO_MON_SRC, RUNQUOTA_SRC, ...) don't get added to --path:.
Phase G's repro_project_dsl pulls in nimcrypto/sha2, so the production
profile compile crashed with "cannot open file: nimcrypto/sha2" even
after PR #12 added repro_project_dsl to ProfileNimPathLibs.
Fix: synthesize a single-line wrapper config.nims at the profile's
directory that "include"s the upstream config.nims. nim picks it up via
the normal parent-walk and the env-var-driven sibling resolution kicks
in. The wrapper is only created when one is absent (so we don't clobber
an operator-supplied config) and is removed in a finally block.
--no-verify: pre-existing prek migration-mode failure (no
.pre-commit-config.yaml in repo, same as #12).
Co-authored-by: Claude Opus 4.7 (1M context) <noreply@anthropic.com>1 parent d75fe3d commit 01e8a11
1 file changed
Lines changed: 38 additions & 17 deletions
Lines changed: 38 additions & 17 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
59 | 59 | | |
60 | 60 | | |
61 | 61 | | |
| 62 | + | |
| 63 | + | |
| 64 | + | |
| 65 | + | |
| 66 | + | |
| 67 | + | |
| 68 | + | |
| 69 | + | |
| 70 | + | |
| 71 | + | |
| 72 | + | |
| 73 | + | |
| 74 | + | |
| 75 | + | |
| 76 | + | |
| 77 | + | |
62 | 78 | | |
63 | 79 | | |
64 | 80 | | |
| |||
68 | 84 | | |
69 | 85 | | |
70 | 86 | | |
71 | | - | |
72 | | - | |
73 | | - | |
74 | | - | |
75 | | - | |
76 | | - | |
77 | | - | |
78 | | - | |
79 | | - | |
80 | | - | |
81 | | - | |
82 | | - | |
83 | | - | |
84 | | - | |
85 | | - | |
86 | | - | |
87 | | - | |
| 87 | + | |
| 88 | + | |
| 89 | + | |
| 90 | + | |
| 91 | + | |
| 92 | + | |
| 93 | + | |
| 94 | + | |
| 95 | + | |
| 96 | + | |
| 97 | + | |
| 98 | + | |
| 99 | + | |
| 100 | + | |
| 101 | + | |
| 102 | + | |
| 103 | + | |
| 104 | + | |
| 105 | + | |
| 106 | + | |
| 107 | + | |
| 108 | + | |
88 | 109 | | |
89 | 110 | | |
90 | 111 | | |
| |||
0 commit comments