Prof. A Olowofoyeku (The African Chief) wrote:
At present, "gpc foo.pas" produces "a.exe" on Windows, and perhaps just "a" or "a.out" on other platforms. If you want "foo.exe" or "foo" or whatever, you have to use "--executable-file-name" or use "-o foo[.extension]". Would it be sensible to have situations where "--executable-file-name" is supplied automatically?
One word: gp. :-)
I am not wishing to create more work - but I have always wondered whether anyone ever actually wants "gpc foo.pas" to produce "a.[whatever]".
The test suite wants this. (Of course, supplying `-o a.{out,exe}' would be possible there.)
This seems to be a relic from the past (and perhaps from gcc),
Yes -- also called compatibility. The plan is to make/leave the `gpc' executable as similar to `gcc' and put the Pascal specific and more convenient stuff in `gp'. (This might also be useful for multi-language projects which can then better control how they want to build.)
Finally, under BP and Delphi, "gpc foo.pas" will always produce "foo[.whatever]". Perhaps "--executable-file-name" should always be implied when in BP or Delphi mode?
alias bpc="gpc --automake --exetuable-file-name --borland-pascal ..." (for now).
Frank