Created
June 1, 2019 22:51
-
-
Save fabiand93/4defe0818bd79ca6106fa7524241c3cf to your computer and use it in GitHub Desktop.
Revisions
-
fabiand93 created this gist
Jun 1, 2019 .There are no files selected for viewing
This file contains hidden or 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 charactersOriginal file line number Diff line number Diff line change @@ -0,0 +1,72 @@ sudo xcode-select --switch /Applications/Xcode.app pip uninstall psycopg2 pip list --outdated pip install --upgrade wheel pip install --upgrade setuptools pip install psycopg2 For all having issues like this ones: Use `sudo xcode-select --switch path/to/Xcode.app` to specify the Xcode that you wish to use for command line developer tools, or use `xcode-select --install` to install the standalone command line developer tools. See `man xcode-select` for more details. It appears you are missing some prerequisite to build the package from source. You may install a binary package by installing 'psycopg2-binary' from PyPI. If you want to install psycopg2 from source, please install the packages required for the build and try again. For further information please check the 'doc/src/install.rst' file (also at <http://initd.org/psycopg/docs/install.html>). error: command 'clang' failed with exit status 1 ---------------------------------------- Failed building wheel for psycopg2 Running setup.py clean for psycopg2 Failed to build psycopg2 Installing collected packages: psycopg2 Running setup.py install for psycopg2 ... error Complete output from command /usr/local/opt/python/bin/python3.7 -u -c "import setuptools, tokenize;__file__='/private/var/folders/q_/ycvjgnc54lx5j4k_cbqz6v040000gn/T/pip-install-u1bb0gqz/psycopg2/setup.py';f=getattr(tokenize, 'open', open)(__file__);code=f.read().replace('\r\n', '\n');f.close();exec(compile(code, __file__, 'exec'))" install --record /private/var/folders/q_/ycvjgnc54lx5j4k_cbqz6v040000gn/T/pip-record-l3umytwt/install-record.txt --single-version-externally-managed --compile: running install running build running build_py creating build creating build/lib.macosx-10.14-x86_64-3.7 creating build/lib.macosx-10.14-x86_64-3.7/psycopg2 copying lib/_json.py -> build/lib.macosx-10.14-x86_64-3.7/psycopg2 copying lib/extras.py -> build/lib.macosx-10.14-x86_64-3.7/psycopg2 copying lib/compat.py -> build/lib.macosx-10.14-x86_64-3.7/psycopg2 copying lib/errorcodes.py -> build/lib.macosx-10.14-x86_64-3.7/psycopg2 copying lib/tz.py -> build/lib.macosx-10.14-x86_64-3.7/psycopg2 copying lib/_range.py -> build/lib.macosx-10.14-x86_64-3.7/psycopg2 copying lib/_ipaddress.py -> build/lib.macosx-10.14-x86_64-3.7/psycopg2 copying lib/_lru_cache.py -> build/lib.macosx-10.14-x86_64-3.7/psycopg2 copying lib/__init__.py -> build/lib.macosx-10.14-x86_64-3.7/psycopg2 copying lib/extensions.py -> build/lib.macosx-10.14-x86_64-3.7/psycopg2 copying lib/errors.py -> build/lib.macosx-10.14-x86_64-3.7/psycopg2 copying lib/sql.py -> build/lib.macosx-10.14-x86_64-3.7/psycopg2 copying lib/pool.py -> build/lib.macosx-10.14-x86_64-3.7/psycopg2 running build_ext building 'psycopg2._psycopg' extension creating build/temp.macosx-10.14-x86_64-3.7 creating build/temp.macosx-10.14-x86_64-3.7/psycopg clang -Wno-unused-result -Wsign-compare -Wunreachable-code -fno-common -dynamic -DNDEBUG -g -fwrapv -O3 -Wall -I/Applications/Xcode-beta.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.14.sdk/usr/include -I/Applications/Xcode-beta.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.14.sdk/System/Library/Frameworks/Tk.framework/Versions/8.5/Headers -DPSYCOPG_VERSION=2.8.2 (dt dec pq3 ext lo64) -DPG_VERSION_NUM=110003 -DHAVE_LO64=1 -I/usr/local/include -I/usr/local/opt/openssl/include -I/usr/local/opt/sqlite/include -I/usr/local/Cellar/python/3.7.2_2/Frameworks/Python.framework/Versions/3.7/include/python3.7m -I. -I/usr/local/Cellar/postgresql/11.3/include -I/usr/local/Cellar/postgresql/11.3/include/server -c psycopg/psycopgmodule.c -o build/temp.macosx-10.14-x86_64-3.7/psycopg/psycopgmodule.o xcrun: error: active developer path ("/Applications/Xcode-beta.app/Contents/Developer") does not exist Use `sudo xcode-select --switch path/to/Xcode.app` to specify the Xcode that you wish to use for command line developer tools, or use `xcode-select --install` to install the standalone command line developer tools. See `man xcode-select` for more details. It appears you are missing some prerequisite to build the package from source. You may install a binary package by installing 'psycopg2-binary' from PyPI. If you want to install psycopg2 from source, please install the packages required for the build and try again. For further information please check the 'doc/src/install.rst' file (also at <http://initd.org/psycopg/docs/install.html>). error: command 'clang' failed with exit status 1 ---------------------------------------- Command "/usr/local/opt/python/bin/python3.7 -u -c "import setuptools, tokenize;__file__='/private/var/folders/q_/ycvjgnc54lx5j4k_cbqz6v040000gn/T/pip-install-u1bb0gqz/psycopg2/setup.py';f=getattr(tokenize, 'open', open)(__file__);code=f.read().replace('\r\n', '\n');f.close();exec(compile(code, __file__, 'exec'))" install --record /private/var/folders/q_/ycvjgnc54lx5j4k_cbqz6v040000gn/T/pip-record-l3umytwt/install-record.txt --single-version-externally-managed --compile" failed with error code 1 in /private/var/folders/q_/ycvjgnc54lx5j4k_cbqz6v040000gn/T/pip-install-u1bb0gqz/psycopg2/