Reputation: 1353
installing python modules in GNU/Linux. Are there any good PDFs on installing modules? I would like to install some of these Python: 50 modules for all needs. I tried PIL http://effbot.org/downloads/Imaging-1.1.7.tar.gz but it did not work.
PS: what does community wiki mean?
Upvotes: 3
Views: 12371
Reputation: 43064
Most of those are probably already available as packages in your Linux distribution. You didn't mention which one you used. Typically, "apt-get" or "yum" would cover most current distributions. Read the man pages for those tools, and use the search features to find packages containing the name "python", or the names of the packages in the list.
If the one you want is not there, install "setuptools", then use "easy-install" to fetch them from the Python package index (PyPI).
Only if the above fail you should build from source. That will require a build environment, typically involving installing "dev" or "development" packages, e.g "python-dev" on some distros. You may also need some other library -dev packages.
Once you have the required development packages installed, the distutils (or setuptools) standard method to build from source should be used.
The command
$ python setup.py build
should work. If it doesn't you may need more -dev packages. Check the error messages.
If it does build, then use "sudo python setup.py install" to install it.
Without more info, it's hard to give a more specific answer.
Upvotes: 4
Reputation: 21377
On a Debian or Ubuntu system, the easiest way to install Python packages, if available, is apt-get. The easy_install system contains more Python packages, but the apt-get packages are specifically tuned for your system.
They always start with 'python-'.
For example,
sudo apt-get install python-imaging
Upvotes: 0