This is the mail archive of the
gcc@gcc.gnu.org
mailing list for the GCC project.
Bug: Undefined reference to MAIN__
- To: gcc at gcc dot gnu dot org
- Subject: Bug: Undefined reference to MAIN__
- From: Martin Kahlert <martin dot kahlert at infineon dot com>
- Date: Mon, 1 Oct 2001 10:44:19 +0200
- Reply-To: martin dot kahlert at infineon dot com
This is a new bug (worked on Friday last weak):
$ cat t.c
int main()
{
extern void f_();
f_();
return 0;
}
$ cat f.f
SUBROUTINE f
WRITE(*,*) 'Hello World'
RETURN
END
$ gcc -c t.c
$ g77 -o t t.o f.f
/sw/gcc-3.1/lib/gcc-lib/i686-pc-linux-gnu/3.1/frtbegin.o: In function `main':
/home/kahlert/LOCAL/OBJ-3.1/i686-pc-linux-gnu/libf2c/libF77/../../../../gcc-3.1/libf2c/libF77/main.c:61:
undefined reference to `MAIN__'
collect2: ld returned 1 exit status
$ gcc -v
Reading specs from /sw/gcc-3.1/lib/gcc-lib/i686-pc-linux-gnu/3.1/specs
Configured with: ../gcc-3.1/configure --prefix=/sw/gcc-3.1
--enable-languages=c++,f77,java --enable-threads=posix
Thread model: posix
gcc version 3.1 20010930 (experimental)
Bye,
Martin.
--
The early bird catches the worm. If you want something else for
breakfast, get up later.