|
|
ld.so.1: ./ns.run: fatal: libgcc_s.so.1: open failed: No such file or directory
Hi ,
I am facing this problem .
SunOS INHYLB1-SUN4 5.9 Generic_112233-10 sun4u sparc
SUNW,Sun-Fire-V440
After I link an executable , I cannot run it:
ld.so.1: ./ns.run: fatal: libgcc_s.so.1: open failed: No such file or
directory
The binary ns.run is build in gcc version 3.3.2. But in the test
solaris box there is no gcc installed , also there is no
libgcc_s.so.1.
I do not want to add the libgcc_s.so.1 directory to LD_LIBRARY_PATH
(this is not an automated solution), I would prefer that the this path
is somehow saved into the executable.
how can I do it?
Thanks,
Abhijit
|
|
0
|
|
|
|
Reply
|
abhijit
|
12/22/2004 7:07:36 AM |
|
Have a look at 'man ld' or the "Linkers and loaders" guide at sun site.
There is an option in ld to bind library path in binary file. I don't
remember the exact command right now.
Cheers,
Manu
------------------
Manu Garg
http://manugarg.freezope.org
|
|
0
|
|
|
|
Reply
|
manu
|
12/22/2004 8:03:06 AM
|
|
I could not find anything . Can you please let me know the exact option
>
Thanks,
Abhijit
|
|
0
|
|
|
|
Reply
|
Abhijit
|
12/22/2004 8:37:51 AM
|
|
"Abhijit" wrote:
> I could not find anything . Can you please let me know the exact option
-R/the/right/path
If you are linking with gcc and not calling ld yourself, you may have to
protect it with "-Wl,", depending on how good your gcc specs are.
|
|
0
|
|
|
|
Reply
|
Marc
|
12/22/2004 12:22:19 PM
|
|
On Wed, 22 Dec 2004 00:37:51 -0800, Abhijit wrote:
> I could not find anything . Can you please let me know the exact option
In your Makefile
LDFLAGS=-L/path_to_libgcc -R/path_to_libgcc ....
|
|
0
|
|
|
|
Reply
|
Dave
|
12/22/2004 12:27:51 PM
|
|
Dave Uhring wrote:
> On Wed, 22 Dec 2004 00:37:51 -0800, Abhijit wrote:
>
>
>>I could not find anything . Can you please let me know the exact option
>
>
> In your Makefile
>
> LDFLAGS=-L/path_to_libgcc -R/path_to_libgcc ....
>
Or simply use -static-libgcc.
--
Henry Townsend
|
|
0
|
|
|
|
Reply
|
Heny
|
12/22/2004 1:20:46 PM
|
|
|
5 Replies
718 Views
(page loaded in 0.26 seconds)
|
|
|
|
|
|
|
|
|