rad@MITRE-BEDFORD.ARPA (07/13/84)
I thought those considering the problem of a "makefile maker" might be interested to know that the Cambridge University Modula2 system for BSD4.1 includes the "mm2m" command, which automatically generates makefiles for Modula2 programs. Of course, the problem is much simpler for Modula2 than for C, where IMPORT statements in the code make it clear where routines are located. The Cambridge Modula-2 package has very nice utilities; too bad the code generated by the compiler is, as they put it, "far from optimal". Dick Dramstad rad@mitre-bedford
DBrown@HI-MULTICS.ARPA (07/13/84)
The article actually discuses the problems of making correct makefiles in the presence of .h files including other .h files, .y files including .h files and so forth. It points out that there are several classical errors made by humans writing makefiles, such as claiming that foo.c depends on bar.h, when it is really foo.o which depends on both foo.c and bar.h. The extraction of #includes is the "easy" part (albeit very language and system dependant), and the program referred to is the one which uses the include lists to build dependancy graphs. --dave