Created
April 22, 2017 07:50
-
-
Save judeaugustinej/2779eff1ffbde681ccf5f4b6a0f56458 to your computer and use it in GitHub Desktop.
Error message while installing python packages
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
* Error msg one | |
``` | |
-error-command-x86-64-linux-gnu-gcc-failed-with-exit-status 1 | |
``` | |
* Fix | |
``` | |
sudo apt install libpq-dev python-dev libxml2-dev libxslt1-dev libldap2-dev libsasl2-dev | |
``` | |
* Error msg two | |
``` | |
I am working on Django project with virtualenv and connect it to local postgres database. when i run the project is says, | |
ImportError: No module named psycopg2.extensions | |
then i used this command to install | |
pip install psycopg2 | |
then during the installation it gives following error. | |
Downloading/unpacking psycopg2==2.4.4 | |
Downloading psycopg2-2.4.4.tar.gz (648kB): 648kB downloaded | |
Running setup.py (path:/home/muhammadtaqi/Projects/MyProjects/OnlineElectionCampaign/venv/build/psycopg2/setup.py) egg_info for package psycopg2 | |
Error: You need to install postgresql-server-dev-X.Y for building a server-side extension or libpq-dev for building a client-side application. | |
Complete output from command python setup.py egg_info: | |
running egg_info | |
creating pip-egg-info/psycopg2.egg-info | |
writing pip-egg-info/psycopg2.egg-info/PKG-INFO | |
writing top-level names to pip-egg-info/psycopg2.egg-info/top_level.txt | |
writing dependency_links to pip-egg-info/psycopg2.egg-info/dependency_links.txt | |
writing manifest file 'pip-egg-info/psycopg2.egg-info/SOURCES.txt' | |
warning: manifest_maker: standard file '-c' not found | |
Error: You need to install postgresql-server-dev-X.Y for building a server-side extension or libpq-dev for building a client-side application. | |
---------------------------------------- | |
Cleaning up... | |
Command python setup.py egg_info failed with error code 1 in /home/muhammadtaqi/Projects/MyProjects/OnlineElectionCampaign/venv/build/psycopg2 | |
Storing debug log for failure in /home/muhammadtaqi/.pip/pip.log | |
``` | |
* solution | |
``` | |
sudo apt-get install postgresql | |
sudo apt-get install python-psycopg2 | |
sudo apt-get install libpq-dev | |
``` |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment