Yes, you just upgrade your build system to have a preprocess step, obfuscate the step, and then the compilation step to the object. By default, most build systems simply combine all of this into one step (and skip the obfuscation step). There should be nothing to do with any “real” build system such as Scons, waf, or even Make.
If you are using Visual Studio, then this is a bit more. Microsoft wants you to write your build operations in MSBuild, and this is pretty much work, IMHO. This is not easy because MSVS is basically an IDE for iterative development and is NOT intended to create a build tool. It will not and never will be a build tool (even if it happens to “build things”, but only standard and very simple “build things”). But you can still use the IDE with another build tool. For example, we use Scons for our assembly and generate MSVS *.sln and *.vcproj , and these files are simply built using Scons (but all files are edited in the MSVS environment).
The simple answer is: your question is just a build problem. This should be very straightforward with any “toy” assembly system.
The distcc (distributed collector) function effectively preprocesses all the files locally, then sends *.i to remote compilers (which do not even require the installation of headers), and then sends *.obj back. So what you say is pretty straight forward.
source share