Skip to content
New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

Requirment installation error. Error: pg_config executable not found #96

Closed
pikamar opened this issue Jan 26, 2017 · 6 comments
Closed

Comments

@pikamar
Copy link

pikamar commented Jan 26, 2017

  Using cached psycopg2-2.6.1.tar.gz
    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'
    Error: pg_config executable not found.

    Please add the directory containing pg_config to the PATH
    or specify the full executable path with the option:

        python setup.py build_ext --pg-config /path/to/pg_config build ...

    or with the pg_config option in 'setup.cfg'.

    ----------------------------------------
Command "python setup.py egg_info" failed with error code 1 in /tmp/pip-build-U3FPuB/psycopg2/```

Environment:
(flask_base) adop@adop:~/flask-base$ lsb_release -a
No LSB modules are available.
Distributor ID: Ubuntu
Description:    Ubuntu 16.04.1 LTS
Release:        16.04
Codename:       xenial

(flask_base) adop@adop:~/flask-base$ python --version
Python 2.7.12
@pikamar pikamar changed the title Requirment installation eeror. Error: pg_config executable not found Requirment installation error. Error: pg_config executable not found Jan 26, 2017
@pikamar
Copy link
Author

pikamar commented Jan 26, 2017

Issue was solved by installing
sudo apt-get install libpq-dev

@abhisuri97
Copy link
Contributor

Will add to the readme. thanks 👍

@abhisuri97
Copy link
Contributor

done. ref readme. thank you :)

@1akshat
Copy link

1akshat commented May 20, 2017

I am getting this similar error when deploying to aws. I am working in virtual environment. Can anyone help?

@sandlerben
Copy link
Contributor

@1akshat did the solution above help?

@sanjitprd777
Copy link

sanjitprd777 commented Apr 9, 2021

On Mac OS X, I solved it using the homebrew package manager
brew install postgresql

In case u are having permission issue in brew do this,
sudo chown -R $(whoami) $(brew --prefix)/*

# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

5 participants