We currently turn build options into components of a very long variant directory so that re-building with previously used build options is fast, since otherwise we would be stepping on the generated object files at each build and there would be no chance for re-use.
The downside is that it is very hard to know, given particular compiler options, what the name of a given target might be.
However, SCons offers a target caching facility that can intelligently cache object files and avoid re-building while overwriting into the variant dir.
By using the CacheDir facility, we would get the benefit of fast re-builds, but lose the complexity of the long variant directory names.
This should be a developer only option, and not used for production builds, and should be limited to only working with newer versions of SCons where the CacheDir feature us likely to work reasonably well.