Unix Technical Forum

installing from source - program can't find library...

This is a discussion on installing from source - program can't find library... within the Slackware Linux Support forums, part of the Unix Operating Systems category; --> Evening all, I'm sure this is a common issue, but googling doesn't seem to come up with anything usefull: ...


Go Back   Unix Technical Forum > Unix Operating Systems > Slackware Linux Support

FAQ Members List Calendar Search Today's Posts Mark Forums Read
  #1 (permalink)  
Old 02-19-2008, 03:01 PM
standardblue
 
Posts: n/a
Default installing from source - program can't find library...

Evening all,

I'm sure this is a common issue, but googling doesn't seem to come up with
anything usefull:

I've downloaded and installed from source a pair of programs from
sourceforge (mpio.sf.net - drivers for my mp3 player). The command line
program 'mpiosh' installs and works fine, but the GUI frontend 'kmpio'
throws out the error:

[mark@ark-royal:lib] $ kmpio
kmpio: error while loading shared libraries: libmpio.so.1: cannot open
shared object file: No such file or directory

I RTFM and installed both programs exactly as instructed - ./configure,
make, make check, make install and no errors were generated.

Both programs were by default installed to /user/local/bin (as TFM said
they would be). The library in question exists in /usr/local/lib

Here's the relevant contents of that directory (everything with 'mpio' in
it):

-rw-r--r-- 1 root root 480950 Aug 25 21:32 libmpio.a
-rwxr-xr-x 1 root root 705 Aug 25 21:32 libmpio.la*
lrwxrwxrwx 1 root root 16 Aug 25 21:32 libmpio.so ->
libmpio.so.1.0.0* lrwxrwxrwx 1 root root 16 Aug 25 21:32
libmpio.so.1 -> libmpio.so.1.0.0* -rwxr-xr-x 1 root root
303433 Aug 25 21:32 libmpio.so.1.0.0*

So it's there, and the permission's are correct. I'm guessing that for
some reason, kmpio can't find it?

I get the feeling I've missed something obvious, or done something daft...

Can someone point me in the right direction to sort it?

Thanks,

sb

--
Remove spamtrap to reply by email.
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #2 (permalink)  
Old 02-19-2008, 03:01 PM
standardblue
 
Posts: n/a
Default Re: installing from source - program can't find library...

On Wed, 25 Aug 2004 22:38:17 +0100, standardblue wrote:

> Evening all,

<snip>

Doh! Forget to say:

Running Slack 9.1 with the default 2.4.22 kernel, on an Athlon.

The mp3 player is USB, and the command line tool runs fine with it.

sb
--
Remove spamtrap to reply by email.
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #3 (permalink)  
Old 02-19-2008, 03:01 PM
Joost Kremers
 
Posts: n/a
Default Re: installing from source - program can't find library...

standardblue wrote:
> Evening all,
>
> I'm sure this is a common issue, but googling doesn't seem to come up with
> anything usefull:
>
> I've downloaded and installed from source a pair of programs from
> sourceforge (mpio.sf.net - drivers for my mp3 player). The command line
> program 'mpiosh' installs and works fine, but the GUI frontend 'kmpio'
> throws out the error:
>
> [mark@ark-royal:lib] $ kmpio
> kmpio: error while loading shared libraries: libmpio.so.1: cannot open
> shared object file: No such file or directory


do 'ldd mpiosh' and 'ldd kmpio' and post the output here. ldd tells you
which libraries a program uses. off the top of my hat, the only reason i
can think of why a library in /usr/local/lib wouldn't be found is that the
directory may not be in /etc/ld.so.conf. but if that were the case, one
wouldn't expect mpiosh to be able to find it either.

--
Joost Kremers joostkremers@yahoo.com
Selbst in die Unterwelt dringt durch Spalten Licht
EN:SiS(9)
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #4 (permalink)  
Old 02-19-2008, 03:01 PM
Chiefy
 
Posts: n/a
Default Re: installing from source - program can't find library...

25 Aug 2004 22:10 UTC, Joost Kremers typed:
>> kmpio: error while loading shared libraries: libmpio.so.1: cannot open
>> shared object file: No such file or directory

>
> do 'ldd mpiosh' and 'ldd kmpio' and post the output here. ldd tells you
> which libraries a program uses. off the top of my hat, the only reason i
> can think of why a library in /usr/local/lib wouldn't be found is that the
> directory may not be in /etc/ld.so.conf. but if that were the case, one
> wouldn't expect mpiosh to be able to find it either.


Maybe running ldconfig manually might work.

It looks like the shared library was found at compile time, unless a
pre-compiled binary was distributed with the source.

--
An authority is a person who can tell you more about something than you
really care to know.
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #5 (permalink)  
Old 02-19-2008, 03:02 PM
standardblue
 
Posts: n/a
Default Re: installing from source - program can't find library...

On Wed, 25 Aug 2004 22:10:19 +0000, Joost Kremers wrote:
> standardblue wrote:
>> [mark@ark-royal:lib] $ kmpio
>> kmpio: error while loading shared libraries: libmpio.so.1: cannot open
>> shared object file: No such file or directory

>
> do 'ldd mpiosh' and 'ldd kmpio' and post the output here. ldd tells you
> which libraries a program uses. off the top of my hat, the only reason i
> can think of why a library in /usr/local/lib wouldn't be found is that the
> directory may not be in /etc/ld.so.conf. but if that were the case, one
> wouldn't expect mpiosh to be able to find it either.


Thanks guys.

Cheify- AFAIUI, it's all compiled locally - there was nothing precompiled,
from what I can ascertain. I'll take a wee look at ldconfig, but I'm new
to compiling beyond following the instructions with a package, the man
page seems to be a bit beyond me!

Joost - Here's the outputs from ld mpiosh and ld kmpio. libmpio.so.1
appears in both outputs, but the hex humber in the brackets afterwards is
different for each.

Cheers,

sb

[root@ark-royal:mark] # ldd /usr/local/bin/mpiosh
libmpio.so.1 => /usr/local/lib/libmpio.so.1 (0x40016000)
libreadline.so.4 => /usr/lib/libreadline.so.4 (0x40044000)
libncurses.so.5 => /lib/libncurses.so.5 (0x40070000)
libc.so.6 => /lib/libc.so.6 (0x400ac000)
/lib/ld-linux.so.2 => /lib/ld-linux.so.2 (0x40000000)
[root@ark-royal:mark] # ldd /usr/local/bin/kmpio
libqt-mt.so.3 => /usr/lib/qt/lib/libqt-mt.so.3 (0x40028000)
libmpio.so.1 => /usr/local/lib/libmpio.so.1 (0x406e1000)
libpthread.so.0 => /lib/libpthread.so.0 (0x406fc000)
libstdc++.so.5 => /usr/lib/libstdc++.so.5 (0x4074d000)
libm.so.6 => /lib/libm.so.6 (0x407fe000)
libgcc_s.so.1 => /usr/lib/libgcc_s.so.1 (0x40821000)
libc.so.6 => /lib/libc.so.6 (0x40829000)
libpng.so.3 => /usr/lib/libpng.so.3 (0x40960000)
libz.so.1 => /usr/lib/libz.so.1 (0x4098a000)
libGL.so.1 => /usr/lib/libGL.so.1 (0x40997000)
libXmu.so.6 => /usr/X11R6/lib/libXmu.so.6 (0x409f3000)
libXrender.so.1 => /usr/X11R6/lib/libXrender.so.1 (0x40a09000)
libXrandr.so.2 => /usr/X11R6/lib/libXrandr.so.2 (0x40a11000)
libXcursor.so.1 => /usr/X11R6/lib/libXcursor.so.1 (0x40a16000)
libXft.so.2 => /usr/X11R6/lib/libXft.so.2 (0x40a1f000)
libfreetype.so.6 => /usr/lib/libfreetype.so.6 (0x40a31000)
libfontconfig.so.1 => /usr/X11R6/lib/libfontconfig.so.1 (0x40a95000)
libXext.so.6 => /usr/X11R6/lib/libXext.so.6 (0x40abc000)
libX11.so.6 => /usr/X11R6/lib/libX11.so.6 (0x40aca000)
libSM.so.6 => /usr/X11R6/lib/libSM.so.6 (0x40b92000)
libICE.so.6 => /usr/X11R6/lib/libICE.so.6 (0x40b9b000)
libdl.so.2 => /lib/libdl.so.2 (0x40bb2000)
/lib/ld-linux.so.2 => /lib/ld-linux.so.2 (0x40000000)
libGLcore.so.1 => /usr/lib/libGLcore.so.1 (0x40bb5000)
libXt.so.6 => /usr/X11R6/lib/libXt.so.6 (0x41060000)
libexpat.so.0 => /usr/lib/libexpat.so.0 (0x410b3000)


--
Remove spamtrap to reply by email.
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #6 (permalink)  
Old 02-19-2008, 03:03 PM
Joost Kremers
 
Posts: n/a
Default Re: installing from source - program can't find library...

standardblue wrote:
> Joost - Here's the outputs from ld mpiosh and ld kmpio. libmpio.so.1
> appears in both outputs, but the hex humber in the brackets afterwards is
> different for each.


i have no idea what the hex numbers actually mean, but i don't think it
matters that they differ. if i check e.g. two programs that depend on
libgtk, they also show different numbers, although they both work fine.

it's weird that ldd reports it as found, while the lib cannot be found when
the executable is run. and TBH, it's beyond me... which means i have little
help to offer. all i can suggest is to verify that /usr/local/lib is in
/etc/ld.so.conf and then try running 'ldconfig' as root. but i doubt that
will solve anything... (it won't hurt either, though.)

--
Joost Kremers joostkremers@yahoo.com
Selbst in die Unterwelt dringt durch Spalten Licht
EN:SiS(9)
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #7 (permalink)  
Old 02-19-2008, 03:03 PM
Thomas Overgaard
 
Posts: n/a
Default Re: installing from source - program can't find library...


standardblue@nooo-spam-pleeaaassseee.yahoo.com wrote :

> Joost - Here's the outputs from ld mpiosh and ld kmpio. libmpio.so.1
> appears in both outputs,


Looks like all dependencies are there. Do you load the mpio module?
<URL: http://mpio.sourceforge.net/install.html#Installation>
--
Thomas O.

This area is designed to become quite warm during normal operation.
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #8 (permalink)  
Old 02-19-2008, 03:03 PM
standardblue
 
Posts: n/a
Default Re: installing from source - program can't find library...

On Thu, 26 Aug 2004 19:57:00 +0000, Joost Kremers wrote:

> standardblue wrote:
>> Joost - Here's the outputs from ld mpiosh and ld kmpio. libmpio.so.1
>> appears in both outputs, but the hex humber in the brackets afterwards is
>> different for each.

>
> i have no idea what the hex numbers actually mean, but i don't think it
> matters that they differ. if i check e.g. two programs that depend on
> libgtk, they also show different numbers, although they both work fine.
>
> it's weird that ldd reports it as found, while the lib cannot be found when
> the executable is run. and TBH, it's beyond me... which means i have little
> help to offer. all i can suggest is to verify that /usr/local/lib is in
> /etc/ld.so.conf and then try running 'ldconfig' as root. but i doubt that
> will solve anything... (it won't hurt either, though.)


You doubted wrong! :-)

/usr/local/lib was indeed in ld.so.conf, but I ran ldconfig and kmpio
works now!

Thanks very much! I'll bear that one in mind if I have this sort of
trouble again.

Cheers!

sb

--
Remove spamtrap to reply by email.
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #9 (permalink)  
Old 02-19-2008, 03:04 PM
standardblue
 
Posts: n/a
Default Re: installing from source - program can't find library...

On Thu, 26 Aug 2004 22:45:11 +0200, Thomas Overgaard wrote:

>
> standardblue@nooo-spam-pleeaaassseee.yahoo.com wrote :
>
>> Joost - Here's the outputs from ld mpiosh and ld kmpio. libmpio.so.1
>> appears in both outputs,

>
> Looks like all dependencies are there. Do you load the mpio module?
> <URL: http://mpio.sourceforge.net/install.html#Installation>


Yep. All sorted now, anyway. Though, it does seem that sometimes the
module loads itself when you plug the device in, sometimes it doesn't.
Kinda weird, but I don't plug it in often enough to warrant looking into
that in great depth.

Cheers,

sb

--
Remove spamtrap to reply by email.
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
Reply


Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On
Forum Jump


All times are GMT. The time now is 10:41 AM.


Powered by vBulletin® Version 3.6.5
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
Search Engine Optimization by vBSEO 3.2.0
www.UnixAdminTalk.com