Open devurandom opened 11 years ago
Thanks for nagging me about this, because I also get irritated whenever it happens. The particularly annoying thing is that it cannot do a clean in this state, because it cannot find all the dependencies! Let me think of a solution which is not just 'kill all .d files in source directory' but of course sometimes brute force is the way to go.
I think there is no easy way other than deleting all .d files whenever the lakefile changes.
The only other option I can think of right now would be to cache the targets and dependencies, so you can later access it after the lakefile change, and delete only those .d files which contain references to files that were removed/changed in the target-cache. I did not have a deeper look, but it feels like this will get very complex very soon, with a lot of corner cases.
Latest version should handle this better. When doing a default clean
target, Lake no longer uses the dependency information stashed in the .d files, and thereafter always cleans them up.
There's also the nuclear option lake -C
which is intended to go on a output file eating rampage in the project tree.
I assume this is because the util.d file still said that it needs util.c, which was moved.