Hi,
I'm sure this issue has been brought up a billion times... but I'm
having trouble installing a python module. I have read all the
documentation for all the buzz words I know related to this problem
but to no avail.
Basically I downloaded a python module called pymad. This module is
supposed to be simplified API to libmad (an mp3 decoder) (I want to
play mp3's from python).
I installed libmad. The libraries appear to be in /usr/local/lib. I
did all the distutils stuff for the module. Now when I try to "import
mad" I get an ImportError exception:
ImportError: libmad.so.0: cannot open shared object file: No such file
or directory
I know the file /usr/local/lib/libmad.so.0 exists, but python can't
seem to find it. I tried adding this path to LD_LIBRARY_PATH , but
that didn't help.
I guess that I just really dont' know enought about libraries and
linux (redhat 9). I don't really know where they are supposed to go
after being compiled, and how python "loads" and uses them.
Any help is much appreciated,
Julia 5 6869 ju************@ hotmail.com (Julia Goolia) writes: ImportError: libmad.so.0: cannot open shared object file: No such file or directory
I know the file /usr/local/lib/libmad.so.0 exists, but python can't seem to find it. I tried adding this path to LD_LIBRARY_PATH , but that didn't help.
Can you please be precise on what "this path" is? Adding
"/usr/local/lib/libmad.so.0" would be wrong, whereas adding
"/usr/local/lib" should work.
I guess that I just really dont' know enought about libraries and linux (redhat 9). I don't really know where they are supposed to go after being compiled, and how python "loads" and uses them.
You might also edit /etc/ld.so.conf to add /usr/local/lib, and run
ldconfig afterwards; this would remove the need to set LD_LIBRARY_PATH
HTH,
Martin
> ImportError: libmad.so.0: cannot open shared object file: No such file or directory
I know the file /usr/local/lib/libmad.so.0 exists, but python can't seem to find it. I tried adding this path to LD_LIBRARY_PATH , but that didn't help.
I guess that I just really dont' know enought about libraries and linux (redhat 9). I don't really know where they are supposed to go after being compiled, and how python "loads" and uses them.
Where are your other python libraries? On my system, they are in:
/usr/local/lib/python2.2/
and then modules that get added by distutils go in:
/usr/local/lib/python2.2/site-packages/
I have a bunch of libfoo.so and libbaz.so.1 type files in there, so
I think if you have a directory like that you should try dropping
your libmad.so.0 in there.
Add /usr/local/lib to the list of directories in /etc/ld.so.conf and
then execute /sbin/ldconfig to create some needed symlinks in
/usr/local/lib.
Jeff
jeff,
you are a gentleman and a scholar. that worked like a charm. thank
you so much. just so i know... adding something to /etc/ld/so/conf is
different than setting LD_LIBRARY_PATH ? what do you do if you don't
have root access?
thanks again,
julia
Jeff Epler <je****@unpytho nic.net> wrote in message news:<ma******* *************** ************@py thon.org>... Add /usr/local/lib to the list of directories in /etc/ld.so.conf and then execute /sbin/ldconfig to create some needed symlinks in /usr/local/lib.
Jeff
On 13 Jul 2003 15:34:36 -0700, ju************@ hotmail.com (Julia
Goolia) wrote: you so much. just so i know... adding something to /etc/ld/so/conf is different than setting LD_LIBRARY_PATH ?
The result should actually be the same. Maybe there was a typo when
you set the path in LD_LIBRARY_PATH , this can easily happen (see
above, the config file is actually /etc/ld.so.conf.... ;-)
By the way, if you want to know how loading libraries works, have a
look at this HOWTO (section 3): http://www.ibiblio.org/pub/Linux/doc...ary-HOWTO.html
(this and more documentation can be found at "The Linux Documentation
Project": http://www.tldp.org/)
what do you do if you don't ave root access?
Then you actually do use LD_LIBRARY_PATH .
- Matthias - This thread has been closed and replies have been disabled. Please start a new discussion. Similar topics |
by: Brandon J. Van Every |
last post by:
What's better about Ruby than Python? I'm sure there's something. What is
it?
This is not a troll. I'm language shopping and I want people's answers. I
don't know beans about Ruby or have any preconceived ideas about it. I have
noticed, however, that every programmer I talk to who's aware of Python is
also talking about Ruby. So it seems that Ruby has the potential to compete
with and displace Python. I'm curious on what basis it...
|
by: Jan Danielsson |
last post by:
Hello all,
I recently started using Python, and I must say I like it. Both the
language and libraries available for it.
Background: I have written an application which I use to keep track
of my personal economy. I wrote it in Java because I wanted to learn the
language for a course in programming at my university. Now that I have
acquired an interrest in Python I was thinking about porting my program
to Python.
|
by: jgelfand |
last post by:
I'm installing Python 2.4.4 on a CentOS release 4.6 (Final) 64-bit machine. Running "./configure --prefix="/
usr/local/yosi/ciao-4.0/ots" --enable-shared" appears to be fine, but
I get the following error message when I run "make":
building '_tkinter' extension
gcc -pthread -fPIC -fno-strict-aliasing -DNDEBUG -g -fwrapv -O3 -Wall -
Wstrict-prototypes -DWITH_APPINIT=1 -I/usr/X11R6/include -I. -I/usr/
local/yosi/Python-2.5.2/./Include...
|
by: Hystou |
last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it.
First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
|
by: Oralloy |
last post by:
Hello folks,
I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>".
The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed.
This is as boiled down as I can make it.
Here is my compilation command:
g++-12 -std=c++20 -Wnarrowing bit_field.cpp
Here is the code in...
| |
by: jinu1996 |
last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth.
The Art of Business Website Design
Your website is...
|
by: tracyyun |
last post by:
Dear forum friends,
With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
|
by: agi2029 |
last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own....
Now, this would greatly impact the work of software developers. The idea...
|
by: isladogs |
last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM).
In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules.
He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms.
Adolph will...
|
by: conductexam |
last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one.
At the time of converting from word file to html my equations which are in the word document file was convert into image.
Globals.ThisAddIn.Application.ActiveDocument.Select();...
|
by: 6302768590 |
last post by:
Hai team
i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
| |
by: muto222 |
last post by:
How can i add a mobile payment intergratation into php mysql website.
| |