* g77 0.5.20 Alpha/ELF => compiles, wrong output
@ 1997-05-23 7:35 Christopher J. Grayce
0 siblings, 0 replies; 2+ messages in thread
From: Christopher J. Grayce @ 1997-05-23 7:35 UTC (permalink / raw)
I have reluctantly concluded that gcc 2.7.2.2 and (more importantly
for me) g77 0.5.20 do not work on Alpha/ELF -- is this true??
I can compile both without error by using the hack suggested by
sundiver@hellfire.dusers.drexel.edu in this list on 13 March 1997 (see
details below), but the resulting compilers do not produce correct
object code. This is obvious in the Fortran case: if the source
contains FORMAT statements or a write statement of the form
WRITE(6,FMT='("foo = ",i2)') INTEGER, then the object code gets a
SIGSEGV as soon as it reaches this statement. (Code that produces no
output to stdout may work correctly, however.)
I can compile and run the same code without error using g77 on a DEC
600 AlphaStation running Digital Unix 3.2C (g77 0.5.20 installs
without error on this system using the standard build method that
comes with the package).
Any suggestions would be appreciated.
Christopher Grayce (cgrayce@uci.edu)
<DETAIL>
hardware = PC164 motherboard, SCSI drive (NCR53c875 adapter),
IDE ATAPI CD, 128 Mb RAM, DEC 450 ethernet card, ARC firmware.
software = plain RH 4.1 installation from CD plus
kernel-headers-2.0.30-2.alpha.rpm
kernel-source-2.0.30-2.alpha.rpm
(which were used to build a 2.0.30 kernel with
gcc-2.7.2.1)
build method:
(1) obtained gcc-2.7.2.1-2.src.rpm from a Redhat mirror
(2) rpm -i gcc-2.7.2.1-2.src.rpm
rpm -bp redhat/SPECS/gcc-2.7.2.1.spec
(3) obtained gcc-2.7.2.2.tar.gz and g77-0.5.20.tar.gz from
prep.ai.mit.edu. Followed g77 INSTALL instructions up
to running configure.
(4) Copied config/alpha/elf.h from gcc-2.7.2.1 source tree to
gcc-2.7.2.2 source tree.
(5) Changed line 552 of "configure" in gcc-2.7.2.2 source top
directory from "tm_file=alpha/linux.h" to "tm_file=alpha/elf.h".
(6) Added "HAVE_STRERROR" to alpha/config/xm-linux.h.
(7) Changed line 48 of config/alpha/xm-alpha.h from "#ifndef __alpha__"
to "#ifndef alloca".
(8) ./configure --prefix=/usr
(9) make bootstrap [no errors]
(10) make compare [no errors except for expected f/zzz.o]
(11) make install [no errors]
</DETAIL>
--
To unsubscribe: send e-mail to axp-list-request@redhat.com with
'unsubscribe' as the subject. Do not send it to axp-list@redhat.com
^ permalink raw reply [flat|nested] 2+ messages in thread
* Re: g77 0.5.20 Alpha/ELF => compiles, wrong output
@ 1997-05-23 12:38 Claus Denk
0 siblings, 0 replies; 2+ messages in thread
From: Claus Denk @ 1997-05-23 12:38 UTC (permalink / raw)
Christopher J. Grayce wrote:
>
> I have reluctantly concluded that gcc 2.7.2.2 and (more importantly
> for me) g77 0.5.20 do not work on Alpha/ELF -- is this true??
>
> I can compile both without error by using the hack suggested by
> sundiver@hellfire.dusers.drexel.edu in this list on 13 March 1997 (see
> details below), but the resulting compilers do not produce correct
> object code. This is obvious in the Fortran case: if the source
> contains FORMAT statements or a write statement of the form
> WRITE(6,FMT='("foo = ",i2)') INTEGER, then the object code gets a
> SIGSEGV as soon as it reaches this statement. (Code that produces no
> output to stdout may work correctly, however.)
Hi,
the following works with my g77 0.5.20/gcc 2.7.2.2 combination
on RH4.0. (with and without the OPEN statement):
PROGRAM MYTEST
INTEGER IT
IT=2
OPEN(UNIT=6,FILE="muss.txt")
WRITE(6,FMT='("foo = ",i2)') IT
END
I essentially followed the same steps as you, but I also had to
change /config/alpha/alpha.c
#if !defined(CROSS_COMPILE) && !defined(_WIN32)
#include <stamp.h>
#endif
to:
#if !defined(CROSS_COMPILE) && !defined(_WIN32) && !defined(__linux__)
#include <stamp.h>
#endif
But I don't know if this could make the difference.
I use Kernel 2.0.29. PC164, IDE harddrive 128 MB Ram.
regards,
Claus Denk
--
To unsubscribe: send e-mail to axp-list-request@redhat.com with
'unsubscribe' as the subject. Do not send it to axp-list@redhat.com
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~1997-05-23 12:38 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
1997-05-23 7:35 g77 0.5.20 Alpha/ELF => compiles, wrong output Christopher J. Grayce
-- strict thread matches above, loose matches on Subject: below --
1997-05-23 12:38 Claus Denk
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox