I'm using 4.1.2, on an intel P4 2.6 and running the latest Debian.

No matter how I describe it at the command line, the linker fails to find
libcairo.a

My library is located at /usr/lib
My include is located at /usr/include/cairo
The library is libcairo.a

My command line looks like this..

gcc -I/usr/include/cairo graphics.c -L/usr/lib -llibcairo.a

I can compile graphics.c to an object.  ld answers with the same result.  It
will always say "ld: cannot find -llibcairo.a"  The file is there.  I can open
it, and it shows up in the directory.  I can exclude the .a extension.  I can
use the longhand switch.  No matter what I do, it always ends with the same
results.

I suspect this is not really a bug, but I'm doing something wrong.  The manual,
while being substantial, includes no examples for even the common switches. 
I'm here to tell you, people (even the ones on #gcc IRC don't wanna touch it)
are not helpful about it.  And I LOVE GNU/Linux for teaching me more about
computers in the last year than my life combined.  I suspected that maybe the
library is built wrong, but I used Synaptic to install it.  It does link the
standard libraries, however.  Why can't it see it?


-- 
           Summary: cannot find library
           Product: gcc
           Version: 4.2.1
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: other
        AssignedTo: unassigned at gcc dot gnu dot org
        ReportedBy: virtualphoton at hotmail dot com


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

Reply via email to