[Bug other/36579] New: gcc refuses to recognize libraries on the command line

2008-06-19 Thread c94wjpn at gmail dot com
It seems to me that the ordering of the libraries / object files given on the
command line is significant.

This fails:
g++ -lpthread -L. -lext minimal.o  -o go
minimal.o: In function `main':
minimal.cpp:(.text+0x1f): undefined reference to `ext_'
collect2: ld returned 1 exit status

Whereas this succeeds:
g++ -lpthread minimal.o -L. -lmcf_ext -o go

here, libext.a is a c-library.


-- 
   Summary: gcc refuses to recognize libraries on the command line
   Product: gcc
   Version: 4.1.1
Status: UNCONFIRMED
  Severity: normal
  Priority: P3
 Component: other
AssignedTo: unassigned at gcc dot gnu dot org
ReportedBy: c94wjpn at gmail dot com


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



[Bug other/36579] gcc refuses to recognize libraries on the command line

2008-06-20 Thread c94wjpn at gmail dot com


--- Comment #3 from c94wjpn at gmail dot com  2008-06-20 23:13 ---
Subject: Re:  gcc refuses to recognize libraries on the command line

I think you're mad. I won't be reporting any bugs to gcc until I see signs
of intelligence coming from you people.

w.

On Thu, Jun 19, 2008 at 4:02 PM, pinskia at gcc dot gnu dot org
<[EMAIL PROTECTED]> wrote:
>
>
> --- Comment #1 from pinskia at gcc dot gnu dot org  2008-06-19 15:02 
> ---
> Is libext.a an archive?
> If so this is not a bug as archives are only looked at once by the most
> linkers.
> You can use -Wl,--start-group  -Wl,--end-group if you want to group
> libraries/objects to be looked at more than once.
>
>
> --
>
> pinskia at gcc dot gnu dot org changed:
>
>   What|Removed |Added
> 
> Status|UNCONFIRMED |WAITING
>
>
> http://gcc.gnu.org/bugzilla/show_bug.cgi?id=36579
>
> --- You are receiving this mail because: ---
> You reported the bug, or are watching the reporter.
>


-- 


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