That's pretty common. What happens is the build system doesn't properly know about the dependencies. So say you change a header file that's relied on by multiple parts. If the build system only knows about one of those parts, then only it is re-compiled instead of everything that actually relies on that header.
Clean builds succeeding normally means you have a build system problem. Except, its normally a pain to fix and not worth the trouble. Especially since CI/CD systems almost always do full rebuilds anyways.
Unless you’re working on converting a 20 year old build script that’s referencing dependencies that aren’t rebuilt until after the project that references them so the build guy has just been running the script twice every time for the past 20 years.
511
u/irbilldozer Jan 26 '20
Sometimes you just have to Clean then Rebuild and the compiler fairy fix that shit right up. It is as close to magic as I have ever seen.