This is the mail archive of the gcc-help@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: Can not link to shared libraries with LD_LIBRARY_PATH (SOLVED).



? ?Hi, Andrew, Ian and everybody else.

? ?Problem solved, after the two steps related below:

? ?step 1: set LD_LIBRARY_PATH to point to /usr/lib and /usr/local/lib directories.

? ?comments on: LD_LIBRARY_PATH not be set by default on my system is at least weird.

? ?step 2: create symbolic links at /usr/lib ('ln -s libncx.so.2.2 libncx.so' and 'ln -s libagt.so.2.2 libagt.so')

? ?comments on: those symbolic links would be created by third-part software which I use.?

? ?So, when I've typed 'gcc -Wall test2.c -lncx -lagt', it did it work! The executable was generated.
?
? ?Best regards.

---------------------------------------------
HELCIO WAGNER DA SILVA


----- Mensagem original -----
De: Andrew Haley <aph@redhat.com>
Para: gcc-help@gcc.gnu.org
Cc: 
Enviadas: Sexta-feira, 22 de Junho de 2012 11:27
Assunto: Re: Can not link to shared libraries with LD_LIBRARY_PATH.

On 06/22/2012 03:03 PM, Helcio Wagner wrote:
>? ? Hi, Ian. Thanks a lot for your help.
> 
>? ? Actually, I don't have neither 'libncx.so' nor 'libagt.so', just 'libncx.so.2.2' and 'libagt.so.2.2'.
>? 
>? ? The only way to generate the executable was to include the absolute path to those files on gcc command line:

Normal practice is to have a symbolic link.

? libncx.so -> libncx.so.2.2

Andrew.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]