Working ELF GCC

Peter Naulls peter at chocky.org
Mon Oct 6 05:43:43 PDT 2003


In message <ccae163d4c.peter at chocky.org>
          Peter Naulls <peter at chocky.org> wrote:

> > 'as' doesn't export the __common symbol properly
> 
> 
> Unfortunately, it causes other problems:
> 
>   [peter at bug:/usr/src/temp] /home/riscos/gcc33/cross/bin/gcc -c test.c
>   Error: Redefinition of main at line 38
>   Error: Symbol main cannot be evaluated

Perhaps you want this:

===================================================================
RCS file: /usr/local/cvsroot/gccsdk/riscos-aof/as/symbol.c,v
retrieving revision 1.7
diff -u -r1.7 symbol.c
--- symbol.c    2 Jun 2003 22:22:26 -0000       1.7
+++ symbol.c    6 Oct 2003 12:41:37 -0000
@@ -79,7 +79,7 @@
     {
       if (EqSymLex (*isearch, &l))
        {
-         if ((*isearch)->type & SYMBOL_DEFINED)
+         if (((*isearch)->type & SYMBOL_DEFINED) && !((*isearch)->type & SYMBOL_EXPORT))
            {
              strncpy (er, l.LexId.str, l.LexId.len);
              er[l.LexId.len] = 0;
cvs server: Diffing regression


If you can put your alloca fix in CVS that would be appreicated too.

Thanks, Peter


-- 
Peter Naulls - peter at chocky.org        | http://www.chocky.org/
----------------------------------------------------------------------------
Free RISC OS Hosting                   | http://www.prowl.org/




More information about the gcc mailing list