Need help deciphering posix.mak

Mike Parker via Digitalmars-d digitalmars-d at puremagic.com
Thu Nov 27 17:50:32 PST 2014


On 11/28/2014 6:39 AM, H. S. Teoh via Digitalmars-d wrote:
>
> One idea I had, which is easily done in SCons, is to auto-generate
> makefiles for each platform. On the dev box, run scons with a particular
> virtual target, say `scons genmake` or something like that, and it will
> iterate over each supported platform and spit out a makefile using the
> dependency tree it already knows. The generated makefile will be a list
> of hard-coded rules for building stuff, with no macros and what-not, so
> it will Just Work, but not do much more than that. These generated
> makefiles can then be shipped as part of the source distribution, but
> they need not (and probably should not!) be in the git tree.
>

I would think that premake or CMake would be better for that sort of 
thing. In addition to the pregenerated Makefiles, you could also keep 
premake.lua (or the CMake stuff) in the source tree and then anyone who 
wanted could generate Visual Studio project files, customized makefiles 
or whatever else they needed.



More information about the Digitalmars-d mailing list