-
Notifications
You must be signed in to change notification settings - Fork 19
Files are compiled twice when compiled #74
Comments
This also causes incorrect rebuilds: git clone https://github.com/leanprover-community/mathlib4 5c951924850fb1fb3d8a656129d9637c401cc6b4
cd 5c951924850fb1fb3d8a656129d9637c401cc6b4
lake build runLinter
git checkout ea3eef0a270babfe47af87657981c2439325de14
lake build
lake build runLinter The last command fails with a linking error:
|
This is the intended behavior. I am confused why you would expect differently? As no |
Ah, yeah, this a bug. Lake currently only produces a single trace for the module. The module is thus up to date because of the |
I went ahead and split the bug into a separate issue. |
Didn't we talk about this in a prior meeting 😄 ? https://leanprover.zulipchat.com/#narrow/stream/147302-lean4-dev/topic/4.2E0.2E0-m3.20ETA.3F/near/270014591 |
@Kha Yeah, I do think we've talked about this before. 😆 I am still not a fan of producing C code when there is no intention to build any native code (e.g., for basic theorem proving). However, I did do the rename of the |
Given all that, I am considering closing this as |
I would have expected the Longer-term we might want to decouple the |
When compiling Lean files, we are not always generating C files. So if you have two targets, one which only requires oleans and the other compiles an executable, then the second will unexpectedly cause recompilation.
To reproduce:
git clone https://github.com/leanprover-community/mathlib4 5c951924850fb1fb3d8a656129d9637c401cc6b4 cd 5c951924850fb1fb3d8a656129d9637c401cc6b4 lake build lake build runLinter
The text was updated successfully, but these errors were encountered: