I've just finished trying to build gcc 4.9.1 as a cross compiler
for a VMS Alpha target (using a Linux host) and I thought I would
let anyone interested know the results are no better than my previous
efforts with gcc 4.8.0.
(A reminder: building a cross compiler first as a pre-requisite to
building a VMS hosted gcc is the approach taken by ACT these days.)
The C frontend builds ok and a Hello World program ran ok on Eisner.
I didn't bother trying to use the cross compiler to build binutils
in VMS hosted mode this time.
The Fortran frontend builds ok but any compiled test programs fail
during startup in the same way as they did with gcc 4.8.0.
The C++ frontend fails to build with the same vms/vms-c.c "undefined
reference to `c_default_pointer_mode'" error which was present in
gcc 4.8.0. This one doesn't look like a major problem to solve, but
understanding the Fortran problem first would be my approach in case
the same problem shows up in the C++ and Ada RTLs.
The Ada frontend fails to build with the same basic internal compiler
error as gcc 4.8.0:
+===========================GNAT BUG DETECTED==============================+
| 4.9.1 (alpha-dec-vms) in plus_constant, at explow.c:87 |
| Error detected around a-direct.adb:763:59 |
| Please submit a bug report; see
http://gcc.gnu.org/bugs.html. |
| Use a subject line meaningful to you and us to track the bug. |
| Include the entire contents of this bug box in the report. |
| Include the exact gcc or gnatmake command that you entered. |
| Also include sources listed below in gnatchop format |
| (concatenated together with no headers between files). |
+==========================================================================+
NOTE: before anyone tries to press gang me into spending more time on
this, note this was just a little diversion as I thought about some
design issues on another unrelated hobbyist project.
My time on this is now over and I just wanted to report the results
in the newsgroup in case anyone else was interested.
Some final thoughts:
I've built a good number of cross compilers over the years and apart
from the time I tried to get a bare metal target Ada cross compiler
running, this is easily the most frustrating target I've come across.
Part of the frustration is that it came out last time that ACT use
their own headers (which are not public) in their own commercial
GNAT products and I've had to create a process, including patches,
for using the VMS supplied headers in my own efforts with the FSF
gcc branch.
This has a major feeling of stabbing in the dark about it and given
some of the subtle behaviour changes which can occur as a result,
I'm not sure if this is contributing to the build problems.
It's not made easier with things like the Fortran issues as I don't
know if they are down to me not using some very specific and
undocumented required build options or if ACT have simply not pushed
all the required changes to the FSF gcc tree.
The sheer size of the gcc tree also makes understanding some of the
problems a challenge without a significant time investment.
A decade ago, when VMS was still a primary hobby interest for me,
I would have spent much more time on this, but I have other interests
now so no firing off emails to other people trying to rope me into
spending more time on this. :-)
Simon.
--
Simon Clubley, clubley@remove_me.eisner.decus.org-Earth.UFP
Microsoft: Bringing you 1980s technology to a 21st century world