Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Has someone got "/usr/ccs/bin/ld: Can't find library: "dl""

Status
Not open for further replies.

programmer400

Programmer
Nov 8, 2006
17
IN
Dear friends
While building the server executable for Systinet Server And Im getting
the following error.
$ make all
No suffix list.
Making all in basic
No suffix list.
Making all in arrays
cd ../.. && make am--refresh
No suffix list.
No suffix list.
/bin/sh ../../libtool --mode=link /opt/aCC/bin/aCC -g -o
arrays client.o arrays.lo arraysStructs.lo
/opt/systinet/server_cpp65/lib/libwasp.la
/opt/systinet/server_cpp65/lib/libwasp_stl.la
/opt/aCC/bin/aCC -g -o arrays client.o .libs/arrays.o
.libs/arraysStructs.o /opt/systinet/server_cpp65/lib/libwasp_stl.sl
/opt/systinet/server_cpp65/lib/libwasp.sl -lm -ldl -lpthread -Wl,+b
-Wl,/opt/systinet/server_cpp65/lib -Wl,+s
/usr/ccs/bin/ld: Can't find library: "dl"
*** Error exit code 1
Stop.
*** Error exit code 1
Stop.
*** Error exit code 1
Stop.
when I checked under /sr/ccs/bin/ ld is an executable.
Im sure it has got to do with equivalent library
is called libdld under /usr/lib/

Can someone please throuw light on how to get rid of such eror ?

Thanks


 
This isn't really a Unix Scripting question. If I recall you were compiling this under AIX, so I'd recommend asking the question in the AIX forum, or General Unix if there isn't one.

Annihilannic.
 
-ldl instructs the linkage editor (ld) to process a file called libdl.a

In AIX, see if you have all the filesets bos.adt.lib* installed.

lslpp -l 'bos.adt.lib*'

If not installed, then that is probably your problem.


HTH,

p5wizard
 
Annihilannic and p5wizard
Thanks for your replies . Sorry for putting this post in Scripting forrum. Im using HP-UX system
Can you please tell me which linker file needs to be looked at under HP-UX
Thanks for ur time
 
It is the same on any unix: -ldl ==> libdl.a (or perhaps libdl.so for a shared object library)

Generally the library files are in /usr/lib or in /lib. That's where ld looks for them. You can specify another library dir by using a LIBPATH variable or by using

ld -L /my/lib/dir -ldl ...

this would look for /my/lib/dir/libdl.a (or .so).


HTH,

p5wizard
 
hi
p5wizard, thanks for your comments. I have one more doubt
From the above post I undestood that I have to add a path for -L/usr/lib/pa20_64 in SHBLIB path in my .profile which is something like
setenv SHLIB_PATH /usr/lib/pa20_64

Please corerct me if Im wrong
Thank you

 
Or you can modify the makefile and include your LIB dir somewhere in the parameter part of the makefile (somewhere in the top of the file I would assume).


HTH,

p5wizard
 
I have included
SHLIB_PATH = -L/usr/lib/pa20_64 in my makefile still Im getting the same error.
I dont know how to resolve yet
 
I did run configure script again with the parameters as
/opt/systinet/server_cpp65/share/doc/waspc/demos> ./configure CXX=/opt/aCC/bin/aCC LD=/opt/aCC/bin/aCC

and it was successul and I used aCC compiler as the linker instead of system default (/usr/ccs/bin/ld) now doing make Im getting the following error
$ make all
No suffix list.
Making all in basic
No suffix list.
Making all in arrays
cd ../.. && make am--refresh
No suffix list.
No suffix list.
/bin/sh ../../libtool --mode=link /opt/aCC/bin/aCC -g -o
arrays client.o arrays.lo arraysStructs.lo
/opt/systinet/server_cpp65/lib/libwasp.la
/opt/systinet/server_cpp65/lib/libwasp_stl.la
/opt/aCC/bin/aCC -g -o arrays client.o .libs/arrays.o
.libs/arraysStructs.o /opt/systinet/server_cpp65/lib/libwasp_stl.sl
/opt/systinet/server_cpp65/lib/libwasp.sl -lm -ldl -lpthread -Wl,+b
-Wl,/opt/systinet/server_cpp65/lib -Wl,+s
/usr/ccs/bin/ld: Can't find library: "dl"
*** Error exit code 1
Stop.
*** Error exit code 1
Stop.
*** Error exit code 1
Stop.


/usr/ccs/bin/ld: Can't find library: "dl" => checked dl library is not present on the HP-UX system . also having specified aCC compiler as linker while running ./configure , the error shows still is uses system default linker /usr/ccs/bin/ld. Im not sure why .

All the 64 bit libraries of HP-UX are under /usr/lib/pa20_64 directory .
 
A c complier automatically invokes linkage editor (ld) in the last step of building an executable.

google for keywords hpux and libdl.a - you seem to be not alone in your quest for this library...


HTH,

p5wizard
 
Thanks for the knowldege update

under /usr/lib/pa20_64 I have
libdl.1
libdl.sl
libdld.1
libdld.sl

only , I dont have libdl.a file in my pa20_64

I did google for hpux and libdl.a and found one good article that is
_
So not having libdl.a could be the cause of this problem ?

Thanks for your time
 
I would think that you configure-d incorrectly or there is something wrong with the configure script.

See what happens if you remove the -ldl from the makefile? Just use vi or any other editor you prefer.

Or go through the configure stage again.



HTH,

p5wizard
 
p5wizard

Im reinstalling the systinet server again will let you know soon
Thanks
Amit
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top