* [Xenomai-help] Compile and run problem
@ 2008-09-01 13:08 Dehann Fourie
2008-09-01 13:23 ` Gilles Chanteperdrix
0 siblings, 1 reply; 3+ messages in thread
From: Dehann Fourie @ 2008-09-01 13:08 UTC (permalink / raw)
To: xenomai
[-- Attachment #1: Type: text/plain, Size: 565 bytes --]
Hi,
I'm having trouble compiling a code fragment. After running the makefile, I
try to run the program wich then gives the the following error?
dehann:/home/dehann/workspace/rtPP_AD# make
gcc -I/usr/xenomai/include -D_GNU_SOURCE -D_REENTRANT -D__XENO__
-L/usr/xenomai/lib -lpthread -lnative main.o -o main -lm
dehann:/home/dehann/workspace/rtPP_AD# ./main
./main: error while loading shared libraries: libnative.so.1: cannot open
shared object file: No such file or directory
the libnative.so.1 file is in the /usr/xenomai/ directory. Thanks in
advance!
Dehann
[-- Attachment #2: Type: text/html, Size: 633 bytes --]
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [Xenomai-help] Compile and run problem
2008-09-01 13:08 [Xenomai-help] Compile and run problem Dehann Fourie
@ 2008-09-01 13:23 ` Gilles Chanteperdrix
2008-09-01 14:32 ` Gilles Chanteperdrix
0 siblings, 1 reply; 3+ messages in thread
From: Gilles Chanteperdrix @ 2008-09-01 13:23 UTC (permalink / raw)
To: Dehann Fourie; +Cc: xenomai
Dehann Fourie wrote:
> Hi,
>
> I'm having trouble compiling a code fragment. After running the makefile, I
> try to run the program wich then gives the the following error?
>
> dehann:/home/dehann/workspace/rtPP_AD# make
> gcc -I/usr/xenomai/include -D_GNU_SOURCE -D_REENTRANT -D__XENO__
> -L/usr/xenomai/lib -lpthread -lnative main.o -o main -lm
> dehann:/home/dehann/workspace/rtPP_AD# ./main
> ./main: error while loading shared libraries: libnative.so.1: cannot open
> shared object file: No such file or directory
>
> the libnative.so.1 file is in the /usr/xenomai/ directory. Thanks in
> advance!
There are several ways out:
- use ld -rpath option (see ld manual);
- use the LD_LIBRARY_PATH environment variable;
- add /usr/xenomai to /etc/ld.so.conf and re-run ldconfig.
--
Gilles.
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [Xenomai-help] Compile and run problem
2008-09-01 13:23 ` Gilles Chanteperdrix
@ 2008-09-01 14:32 ` Gilles Chanteperdrix
0 siblings, 0 replies; 3+ messages in thread
From: Gilles Chanteperdrix @ 2008-09-01 14:32 UTC (permalink / raw)
To: Dehann Fourie; +Cc: xenomai
Gilles Chanteperdrix wrote:
> Dehann Fourie wrote:
>> Hi,
>>
>> I'm having trouble compiling a code fragment. After running the makefile, I
>> try to run the program wich then gives the the following error?
>>
>> dehann:/home/dehann/workspace/rtPP_AD# make
>> gcc -I/usr/xenomai/include -D_GNU_SOURCE -D_REENTRANT -D__XENO__
>> -L/usr/xenomai/lib -lpthread -lnative main.o -o main -lm
>> dehann:/home/dehann/workspace/rtPP_AD# ./main
>> ./main: error while loading shared libraries: libnative.so.1: cannot open
>> shared object file: No such file or directory
>>
>> the libnative.so.1 file is in the /usr/xenomai/ directory. Thanks in
>> advance!
>
> There are several ways out:
> - use ld -rpath option (see ld manual);
> - use the LD_LIBRARY_PATH environment variable;
> - add /usr/xenomai to /etc/ld.so.conf and re-run ldconfig.
According to internet, -rpath is the cleanest solution. And if you look
at xenomai examples makefiles, they use -rpath.
--
Gilles.
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2008-09-01 14:32 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2008-09-01 13:08 [Xenomai-help] Compile and run problem Dehann Fourie
2008-09-01 13:23 ` Gilles Chanteperdrix
2008-09-01 14:32 ` Gilles Chanteperdrix
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.