------- Comment #1 from pinskia at gcc dot gnu dot org  2006-03-15 16:16 -------
First this is not a bug.

Lets look at your link line:
cc -o main -L. -ldata main.o

What is saying to the linker is look at libdata first for symbols that are
required already and then look at main.o.  Since main.o has a reference to
libdata, this fails as the linker are one pass linkers when looking for
symbols.  Change the order of the link line and it will work.


-- 

pinskia at gcc dot gnu dot org changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|UNCONFIRMED                 |RESOLVED
          Component|c                           |other
         Resolution|                            |INVALID


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=26699

Reply via email to