Problem with libg2c
Tim Prince
timothyprince@sbcglobal.net
Thu Jul 13 01:24:00 GMT 2006
Athichart Tangpong wrote:
> Dear Sir,
>
> I have a problem with libg2c on a newly-installed Fedora Core 5 system.
> When I compile programs that require libg2c, I have got this error.
>
> /usr/bin/ld: cannot find -lg2c
> collect2: ld returned 1 exit status
> error: command 'c++' failed with exit status 1
>
> However, when I check, I have found that it exists on the file system.
>
> /usr/lib/gcc-lib/i386-redhat-linux/3.2.3/libg2c.so
> /usr/lib/gcc-lib/i386-redhat-linux/3.2.3/libg2c.a
> /usr/lib/libg2c.so.0.0.0
> /usr/lib/libg2c.so.0
>
> Does anyone know how to fix this problem? Thank you in advance for your
> help.
>
I'm sure someone has attempted to post a reply, as I've done myself. I
guess you didn't try obvious possibilities, like replacing -lg2c with
the entire path of the library you desire, as you didn't say what errors
came about. If you cared, evidently g++ -print-search-dirs would show
you which directories are searched for libraries.
More information about the Gcc-help
mailing list