Thorsten Glaser wrote:
Dixitur illum frank@g-n-u.de scribere...
one of the next releases, and automake support will later be dropped from GPC.
Would it be too difficult to keep --automake support,
Yes!
If one would add a feature that prints out the names of the generated (or not, depending on if they have been rebuilt) .o files, this feature integrated nicely with BSD-style Makefile templates, and I was already planning to code that.
Such a feature could also be added to GP. In fact, I've thought about it, any it may be faster than doing it with GPC/automake (because GP only takes a quick look at source files, whereas GPC/automake parses them fully).
My use for it would be building the RTS and GP itself (which obviously can't use GP in the normal way), though it's not too important for me, since the list of files here changes very rarely, so maintaining an explicit makefile will be possible.
But note that even if you use Makefiles, you can still use GP (unless you absolutely want to avoid installing it :-). Just use a rule such as:
foo: foo.pas force gp <options> foo.pas
Where `foo.pas' is the main source file (GP will find all other source files -- if the necessary paths are given, of course), and `force' makes sure that GP is called each time, so it can check dependencies. (Consider it on the same level as a recursive sub-make, e.g.) If nothing needs to be done, GP will not compile or link anything, so it isn't costly.
If your program depends on generated files, you'll have to list them in the dependencies of the rule, but nothing more is required AFAICS.
Of course, you need not retain automake support if you could make better compiler code otherwise, but as long as it's no real effort, I'd appreciate the feature being left in.
It is much effort, and as I wrote, automake is still buggy and incomplete (e.g., it doesn't work well with cyclic dependencies).
Frank
Hi I have run gp through a number of tests (under Mingw). It is pretty cool! Many congratulations to Frank for a very neat tool.
I have a number of observations/suggestions: 1. I see that the GPC_UNIT_PATH environment variable is not used, even though the compiler proper uses it. It would be very nice if gp would use it too.
2. Any chance of gp using a configuration file (similar to the BP bpc.cfg or Delphi dcc32.cfg files)? You could call it gp.cfg. That way, those who (like me) don't understand make files can still use configuration files. One enhancement of this feature could be for gp to use the base name of the program being compiled (only for programs - not units or modules) to also search for a configuration file specific to that program.
For example, "gp foo.pas" would look for gp.cfg and foo.cfg in that order (the latter to override the former) and load compiler arguments from them/it.
Thanks.
Best regards, The Chief -------- Prof. Abimbola A. Olowofoyeku (The African Chief) web: http://www.bigfoot.com/~african_chief/