2016-10-27 2 views
0

Mac에 psycopg2를 설치하는 데 문제가 있습니다.python 3 용 psycopg2 설치

pip3 install psycopg2 
sudo pip3 install psycopg2 
pip install flask-sqlalchemy psycopg2 
sudo easy_install psycopg2 

내가 찾을 수있는 모든 솔루션을 시도, 아직 때마다 나는 같은 오류 얻을 : 이것으로

Collecting psycopg2 
Using cached psycopg2-2.6.2.tar.gz 
Installing collected packages: psycopg2 
    Running setup.py install for psycopg2 ... error 
    Complete output from command /usr/local/bin/python3 -u -c "import setuptools, tokenize;__file__='/private/var/folders/mn/t5nqmwlj5wb99lyzrkq_d0qc0000gn/T/pip-build-darwcjmh/psycopg2/setup.py';exec(compile(getattr(tokenize, 'open', open)(__file__).read().replace('\r\n', '\n'), __file__, 'exec'))" install --record /var/folders/mn/t5nqmwlj5wb99lyzrkq_d0qc0000gn/T/pip-eqwp14v4-record/install-record.txt --single-version-externally-managed --compile: 
    running install 
    running build 
    running build_py 
    creating build 
    creating build/lib.macosx-10.6-intel-3.5 
    creating build/lib.macosx-10.6-intel-3.5/psycopg2 
    copying lib/__init__.py -> build/lib.macosx-10.6-intel-3.5/psycopg2 
    copying lib/_json.py -> build/lib.macosx-10.6-intel-3.5/psycopg2 
    copying lib/_range.py -> build/lib.macosx-10.6-intel-3.5/psycopg2 
    copying lib/errorcodes.py -> build/lib.macosx-10.6-intel-3.5/psycopg2 
    copying lib/extensions.py -> build/lib.macosx-10.6-intel-3.5/psycopg2 
    copying lib/extras.py -> build/lib.macosx-10.6-intel-3.5/psycopg2 
    copying lib/pool.py -> build/lib.macosx-10.6-intel-3.5/psycopg2 
    copying lib/psycopg1.py -> build/lib.macosx-10.6-intel-3.5/psycopg2 
    copying lib/tz.py -> build/lib.macosx-10.6-intel-3.5/psycopg2 
    creating build/lib.macosx-10.6-intel-3.5/psycopg2/tests 
    copying tests/__init__.py -> build/lib.macosx-10.6-intel-3.5/psycopg2/tests 
    copying tests/dbapi20.py -> build/lib.macosx-10.6-intel-3.5/psycopg2/tests 
    copying tests/dbapi20_tpc.py -> build/lib.macosx-10.6-intel-3.5/psycopg2/tests 
    copying tests/test_async.py -> build/lib.macosx-10.6-intel-3.5/psycopg2/tests 
    copying tests/test_bug_gc.py -> build/lib.macosx-10.6-intel-3.5/psycopg2/tests 
    copying tests/test_bugX000.py -> build/lib.macosx-10.6-intel-3.5/psycopg2/tests 
    copying tests/test_cancel.py -> build/lib.macosx-10.6-intel-3.5/psycopg2/tests 
    copying tests/test_connection.py -> build/lib.macosx-10.6-intel-3.5/psycopg2/tests 
    copying tests/test_copy.py -> build/lib.macosx-10.6-intel-3.5/psycopg2/tests 
    copying tests/test_cursor.py -> build/lib.macosx-10.6-intel-3.5/psycopg2/tests 
    copying tests/test_dates.py -> build/lib.macosx-10.6-intel-3.5/psycopg2/tests 
    copying tests/test_errcodes.py -> build/lib.macosx-10.6-intel-3.5/psycopg2/tests 
    copying tests/test_extras_dictcursor.py -> build/lib.macosx-10.6-intel-3.5/psycopg2/tests 
    copying tests/test_green.py -> build/lib.macosx-10.6-intel-3.5/psycopg2/tests 
    copying tests/test_lobject.py -> build/lib.macosx-10.6-intel-3.5/psycopg2/tests 
    copying tests/test_module.py -> build/lib.macosx-10.6-intel-3.5/psycopg2/tests 
    copying tests/test_notify.py -> build/lib.macosx-10.6-intel-3.5/psycopg2/tests 
    copying tests/test_psycopg2_dbapi20.py -> build/lib.macosx-10.6-intel-3.5/psycopg2/tests 
    copying tests/test_quote.py -> build/lib.macosx-10.6-intel-3.5/psycopg2/tests 
    copying tests/test_transaction.py -> build/lib.macosx-10.6-intel-3.5/psycopg2/tests 
    copying tests/test_types_basic.py -> build/lib.macosx-10.6-intel-3.5/psycopg2/tests 
    copying tests/test_types_extras.py -> build/lib.macosx-10.6-intel-3.5/psycopg2/tests 
    copying tests/test_with.py -> build/lib.macosx-10.6-intel-3.5/psycopg2/tests 
    copying tests/testconfig.py -> build/lib.macosx-10.6-intel-3.5/psycopg2/tests 
    copying tests/testutils.py -> build/lib.macosx-10.6-intel-3.5/psycopg2/tests 
    Skipping optional fixer: buffer 
    Skipping optional fixer: idioms 
    Skipping optional fixer: set_literal 
    Skipping optional fixer: ws_comma 
    running build_ext 
    building 'psycopg2._psycopg' extension 
    creating build/temp.macosx-10.6-intel-3.5 
    creating build/temp.macosx-10.6-intel-3.5/psycopg 
    /usr/bin/clang -DNDEBUG -g -fwrapv -O3 -Wall -Wstrict-prototypes -Qunused-arguments -Qunused-arguments -DPSYCOPG_DEFAULT_PYDATETIME=1 -DPSYCOPG_VERSION="2.6.2 (dt dec pq3 ext lo64)" -DPG_VERSION_HEX=0x090504 -DHAVE_LO64=1 -I/Library/Frameworks/Python.framework/Versions/3.5/include/python3.5m -I. -I/usr/local/Cellar/postgresql/9.5.4/include -I/usr/local/Cellar/postgresql/9.5.4/include/server -c psycopg/psycopgmodule.c -o build/temp.macosx-10.6-intel-3.5/psycopg/psycopgmodule.o 
    /usr/bin/clang -DNDEBUG -g -fwrapv -O3 -Wall -Wstrict-prototypes -Qunused-arguments -Qunused-arguments -DPSYCOPG_DEFAULT_PYDATETIME=1 -DPSYCOPG_VERSION="2.6.2 (dt dec pq3 ext lo64)" -DPG_VERSION_HEX=0x090504 -DHAVE_LO64=1 -I/Library/Frameworks/Python.framework/Versions/3.5/include/python3.5m -I. -I/usr/local/Cellar/postgresql/9.5.4/include -I/usr/local/Cellar/postgresql/9.5.4/include/server -c psycopg/green.c -o build/temp.macosx-10.6-intel-3.5/psycopg/green.o 
    /usr/bin/clang -DNDEBUG -g -fwrapv -O3 -Wall -Wstrict-prototypes -Qunused-arguments -Qunused-arguments -DPSYCOPG_DEFAULT_PYDATETIME=1 -DPSYCOPG_VERSION="2.6.2 (dt dec pq3 ext lo64)" -DPG_VERSION_HEX=0x090504 -DHAVE_LO64=1 -I/Library/Frameworks/Python.framework/Versions/3.5/include/python3.5m -I. -I/usr/local/Cellar/postgresql/9.5.4/include -I/usr/local/Cellar/postgresql/9.5.4/include/server -c psycopg/pqpath.c -o build/temp.macosx-10.6-intel-3.5/psycopg/pqpath.o 
    psycopg/pqpath.c:198:17: warning: implicit conversion from enumeration type 'ConnStatusType' to different enumeration type 'ExecStatusType' [-Wenum-conversion] 
        PQstatus(conn->pgconn) : PQresultStatus(*pgres))); 
        ^~~~~~~~~~~~~~~~~~~~~~ 
    psycopg/pqpath.c:1628:17: warning: implicit conversion from enumeration type 'ConnStatusType' to different enumeration type 'ExecStatusType' [-Wenum-conversion] 
        PQstatus(curs->conn->pgconn) : PQresultStatus(curs->pgres))); 
        ^~~~~~~~~~~~~~~~~~~~~~~~~~~~ 
    2 warnings generated. 
    /usr/bin/clang -DNDEBUG -g -fwrapv -O3 -Wall -Wstrict-prototypes -Qunused-arguments -Qunused-arguments -DPSYCOPG_DEFAULT_PYDATETIME=1 -DPSYCOPG_VERSION="2.6.2 (dt dec pq3 ext lo64)" -DPG_VERSION_HEX=0x090504 -DHAVE_LO64=1 -I/Library/Frameworks/Python.framework/Versions/3.5/include/python3.5m -I. -I/usr/local/Cellar/postgresql/9.5.4/include -I/usr/local/Cellar/postgresql/9.5.4/include/server -c psycopg/utils.c -o build/temp.macosx-10.6-intel-3.5/psycopg/utils.o 
    /usr/bin/clang -DNDEBUG -g -fwrapv -O3 -Wall -Wstrict-prototypes -Qunused-arguments -Qunused-arguments -DPSYCOPG_DEFAULT_PYDATETIME=1 -DPSYCOPG_VERSION="2.6.2 (dt dec pq3 ext lo64)" -DPG_VERSION_HEX=0x090504 -DHAVE_LO64=1 -I/Library/Frameworks/Python.framework/Versions/3.5/include/python3.5m -I. -I/usr/local/Cellar/postgresql/9.5.4/include -I/usr/local/Cellar/postgresql/9.5.4/include/server -c psycopg/bytes_format.c -o build/temp.macosx-10.6-intel-3.5/psycopg/bytes_format.o 
    In file included from psycopg/bytes_format.c:81: 
    In file included from ./psycopg/psycopg.h:33: 
    ./psycopg/config.h:71:13: warning: unused function 'Dprintf' [-Wunused-function] 
    static void Dprintf(const char *fmt, ...) {} 
       ^
    1 warning generated. 
    /usr/bin/clang -DNDEBUG -g -fwrapv -O3 -Wall -Wstrict-prototypes -Qunused-arguments -Qunused-arguments -DPSYCOPG_DEFAULT_PYDATETIME=1 -DPSYCOPG_VERSION="2.6.2 (dt dec pq3 ext lo64)" -DPG_VERSION_HEX=0x090504 -DHAVE_LO64=1 -I/Library/Frameworks/Python.framework/Versions/3.5/include/python3.5m -I. -I/usr/local/Cellar/postgresql/9.5.4/include -I/usr/local/Cellar/postgresql/9.5.4/include/server -c psycopg/connection_int.c -o build/temp.macosx-10.6-intel-3.5/psycopg/connection_int.o 
    /usr/bin/clang -DNDEBUG -g -fwrapv -O3 -Wall -Wstrict-prototypes -Qunused-arguments -Qunused-arguments -DPSYCOPG_DEFAULT_PYDATETIME=1 -DPSYCOPG_VERSION="2.6.2 (dt dec pq3 ext lo64)" -DPG_VERSION_HEX=0x090504 -DHAVE_LO64=1 -I/Library/Frameworks/Python.framework/Versions/3.5/include/python3.5m -I. -I/usr/local/Cellar/postgresql/9.5.4/include -I/usr/local/Cellar/postgresql/9.5.4/include/server -c psycopg/connection_type.c -o build/temp.macosx-10.6-intel-3.5/psycopg/connection_type.o 
    /usr/bin/clang -DNDEBUG -g -fwrapv -O3 -Wall -Wstrict-prototypes -Qunused-arguments -Qunused-arguments -DPSYCOPG_DEFAULT_PYDATETIME=1 -DPSYCOPG_VERSION="2.6.2 (dt dec pq3 ext lo64)" -DPG_VERSION_HEX=0x090504 -DHAVE_LO64=1 -I/Library/Frameworks/Python.framework/Versions/3.5/include/python3.5m -I. -I/usr/local/Cellar/postgresql/9.5.4/include -I/usr/local/Cellar/postgresql/9.5.4/include/server -c psycopg/cursor_int.c -o build/temp.macosx-10.6-intel-3.5/psycopg/cursor_int.o 
    /usr/bin/clang -DNDEBUG -g -fwrapv -O3 -Wall -Wstrict-prototypes -Qunused-arguments -Qunused-arguments -DPSYCOPG_DEFAULT_PYDATETIME=1 -DPSYCOPG_VERSION="2.6.2 (dt dec pq3 ext lo64)" -DPG_VERSION_HEX=0x090504 -DHAVE_LO64=1 -I/Library/Frameworks/Python.framework/Versions/3.5/include/python3.5m -I. -I/usr/local/Cellar/postgresql/9.5.4/include -I/usr/local/Cellar/postgresql/9.5.4/include/server -c psycopg/cursor_type.c -o build/temp.macosx-10.6-intel-3.5/psycopg/cursor_type.o 
    /usr/bin/clang -DNDEBUG -g -fwrapv -O3 -Wall -Wstrict-prototypes -Qunused-arguments -Qunused-arguments -DPSYCOPG_DEFAULT_PYDATETIME=1 -DPSYCOPG_VERSION="2.6.2 (dt dec pq3 ext lo64)" -DPG_VERSION_HEX=0x090504 -DHAVE_LO64=1 -I/Library/Frameworks/Python.framework/Versions/3.5/include/python3.5m -I. -I/usr/local/Cellar/postgresql/9.5.4/include -I/usr/local/Cellar/postgresql/9.5.4/include/server -c psycopg/diagnostics_type.c -o build/temp.macosx-10.6-intel-3.5/psycopg/diagnostics_type.o 
    In file included from psycopg/diagnostics_type.c:27: 
    In file included from ./psycopg/psycopg.h:33: 
    ./psycopg/config.h:71:13: warning: unused function 'Dprintf' [-Wunused-function] 
    static void Dprintf(const char *fmt, ...) {} 
       ^
    1 warning generated. 
    /usr/bin/clang -DNDEBUG -g -fwrapv -O3 -Wall -Wstrict-prototypes -Qunused-arguments -Qunused-arguments -DPSYCOPG_DEFAULT_PYDATETIME=1 -DPSYCOPG_VERSION="2.6.2 (dt dec pq3 ext lo64)" -DPG_VERSION_HEX=0x090504 -DHAVE_LO64=1 -I/Library/Frameworks/Python.framework/Versions/3.5/include/python3.5m -I. -I/usr/local/Cellar/postgresql/9.5.4/include -I/usr/local/Cellar/postgresql/9.5.4/include/server -c psycopg/error_type.c -o build/temp.macosx-10.6-intel-3.5/psycopg/error_type.o 
    In file included from psycopg/error_type.c:27: 
    In file included from ./psycopg/psycopg.h:33: 
    ./psycopg/config.h:71:13: warning: unused function 'Dprintf' [-Wunused-function] 
    static void Dprintf(const char *fmt, ...) {} 
       ^
    1 warning generated. 
    /usr/bin/clang -DNDEBUG -g -fwrapv -O3 -Wall -Wstrict-prototypes -Qunused-arguments -Qunused-arguments -DPSYCOPG_DEFAULT_PYDATETIME=1 -DPSYCOPG_VERSION="2.6.2 (dt dec pq3 ext lo64)" -DPG_VERSION_HEX=0x090504 -DHAVE_LO64=1 -I/Library/Frameworks/Python.framework/Versions/3.5/include/python3.5m -I. -I/usr/local/Cellar/postgresql/9.5.4/include -I/usr/local/Cellar/postgresql/9.5.4/include/server -c psycopg/lobject_int.c -o build/temp.macosx-10.6-intel-3.5/psycopg/lobject_int.o 
    /usr/bin/clang -DNDEBUG -g -fwrapv -O3 -Wall -Wstrict-prototypes -Qunused-arguments -Qunused-arguments -DPSYCOPG_DEFAULT_PYDATETIME=1 -DPSYCOPG_VERSION="2.6.2 (dt dec pq3 ext lo64)" -DPG_VERSION_HEX=0x090504 -DHAVE_LO64=1 -I/Library/Frameworks/Python.framework/Versions/3.5/include/python3.5m -I. -I/usr/local/Cellar/postgresql/9.5.4/include -I/usr/local/Cellar/postgresql/9.5.4/include/server -c psycopg/lobject_type.c -o build/temp.macosx-10.6-intel-3.5/psycopg/lobject_type.o 
    /usr/bin/clang -DNDEBUG -g -fwrapv -O3 -Wall -Wstrict-prototypes -Qunused-arguments -Qunused-arguments -DPSYCOPG_DEFAULT_PYDATETIME=1 -DPSYCOPG_VERSION="2.6.2 (dt dec pq3 ext lo64)" -DPG_VERSION_HEX=0x090504 -DHAVE_LO64=1 -I/Library/Frameworks/Python.framework/Versions/3.5/include/python3.5m -I. -I/usr/local/Cellar/postgresql/9.5.4/include -I/usr/local/Cellar/postgresql/9.5.4/include/server -c psycopg/notify_type.c -o build/temp.macosx-10.6-intel-3.5/psycopg/notify_type.o 
    In file included from psycopg/notify_type.c:27: 
    In file included from ./psycopg/psycopg.h:33: 
    ./psycopg/config.h:71:13: warning: unused function 'Dprintf' [-Wunused-function] 
    static void Dprintf(const char *fmt, ...) {} 
       ^
    1 warning generated. 
    /usr/bin/clang -DNDEBUG -g -fwrapv -O3 -Wall -Wstrict-prototypes -Qunused-arguments -Qunused-arguments -DPSYCOPG_DEFAULT_PYDATETIME=1 -DPSYCOPG_VERSION="2.6.2 (dt dec pq3 ext lo64)" -DPG_VERSION_HEX=0x090504 -DHAVE_LO64=1 -I/Library/Frameworks/Python.framework/Versions/3.5/include/python3.5m -I. -I/usr/local/Cellar/postgresql/9.5.4/include -I/usr/local/Cellar/postgresql/9.5.4/include/server -c psycopg/xid_type.c -o build/temp.macosx-10.6-intel-3.5/psycopg/xid_type.o 
    /usr/bin/clang -DNDEBUG -g -fwrapv -O3 -Wall -Wstrict-prototypes -Qunused-arguments -Qunused-arguments -DPSYCOPG_DEFAULT_PYDATETIME=1 -DPSYCOPG_VERSION="2.6.2 (dt dec pq3 ext lo64)" -DPG_VERSION_HEX=0x090504 -DHAVE_LO64=1 -I/Library/Frameworks/Python.framework/Versions/3.5/include/python3.5m -I. -I/usr/local/Cellar/postgresql/9.5.4/include -I/usr/local/Cellar/postgresql/9.5.4/include/server -c psycopg/adapter_asis.c -o build/temp.macosx-10.6-intel-3.5/psycopg/adapter_asis.o 
    /usr/bin/clang -DNDEBUG -g -fwrapv -O3 -Wall -Wstrict-prototypes -Qunused-arguments -Qunused-arguments -DPSYCOPG_DEFAULT_PYDATETIME=1 -DPSYCOPG_VERSION="2.6.2 (dt dec pq3 ext lo64)" -DPG_VERSION_HEX=0x090504 -DHAVE_LO64=1 -I/Library/Frameworks/Python.framework/Versions/3.5/include/python3.5m -I. -I/usr/local/Cellar/postgresql/9.5.4/include -I/usr/local/Cellar/postgresql/9.5.4/include/server -c psycopg/adapter_binary.c -o build/temp.macosx-10.6-intel-3.5/psycopg/adapter_binary.o 
    /usr/bin/clang -DNDEBUG -g -fwrapv -O3 -Wall -Wstrict-prototypes -Qunused-arguments -Qunused-arguments -DPSYCOPG_DEFAULT_PYDATETIME=1 -DPSYCOPG_VERSION="2.6.2 (dt dec pq3 ext lo64)" -DPG_VERSION_HEX=0x090504 -DHAVE_LO64=1 -I/Library/Frameworks/Python.framework/Versions/3.5/include/python3.5m -I. -I/usr/local/Cellar/postgresql/9.5.4/include -I/usr/local/Cellar/postgresql/9.5.4/include/server -c psycopg/adapter_datetime.c -o build/temp.macosx-10.6-intel-3.5/psycopg/adapter_datetime.o 
    /usr/bin/clang -DNDEBUG -g -fwrapv -O3 -Wall -Wstrict-prototypes -Qunused-arguments -Qunused-arguments -DPSYCOPG_DEFAULT_PYDATETIME=1 -DPSYCOPG_VERSION="2.6.2 (dt dec pq3 ext lo64)" -DPG_VERSION_HEX=0x090504 -DHAVE_LO64=1 -I/Library/Frameworks/Python.framework/Versions/3.5/include/python3.5m -I. -I/usr/local/Cellar/postgresql/9.5.4/include -I/usr/local/Cellar/postgresql/9.5.4/include/server -c psycopg/adapter_list.c -o build/temp.macosx-10.6-intel-3.5/psycopg/adapter_list.o 
    /usr/bin/clang -DNDEBUG -g -fwrapv -O3 -Wall -Wstrict-prototypes -Qunused-arguments -Qunused-arguments -DPSYCOPG_DEFAULT_PYDATETIME=1 -DPSYCOPG_VERSION="2.6.2 (dt dec pq3 ext lo64)" -DPG_VERSION_HEX=0x090504 -DHAVE_LO64=1 -I/Library/Frameworks/Python.framework/Versions/3.5/include/python3.5m -I. -I/usr/local/Cellar/postgresql/9.5.4/include -I/usr/local/Cellar/postgresql/9.5.4/include/server -c psycopg/adapter_pboolean.c -o build/temp.macosx-10.6-intel-3.5/psycopg/adapter_pboolean.o 
    /usr/bin/clang -DNDEBUG -g -fwrapv -O3 -Wall -Wstrict-prototypes -Qunused-arguments -Qunused-arguments -DPSYCOPG_DEFAULT_PYDATETIME=1 -DPSYCOPG_VERSION="2.6.2 (dt dec pq3 ext lo64)" -DPG_VERSION_HEX=0x090504 -DHAVE_LO64=1 -I/Library/Frameworks/Python.framework/Versions/3.5/include/python3.5m -I. -I/usr/local/Cellar/postgresql/9.5.4/include -I/usr/local/Cellar/postgresql/9.5.4/include/server -c psycopg/adapter_pdecimal.c -o build/temp.macosx-10.6-intel-3.5/psycopg/adapter_pdecimal.o 
    /usr/bin/clang -DNDEBUG -g -fwrapv -O3 -Wall -Wstrict-prototypes -Qunused-arguments -Qunused-arguments -DPSYCOPG_DEFAULT_PYDATETIME=1 -DPSYCOPG_VERSION="2.6.2 (dt dec pq3 ext lo64)" -DPG_VERSION_HEX=0x090504 -DHAVE_LO64=1 -I/Library/Frameworks/Python.framework/Versions/3.5/include/python3.5m -I. -I/usr/local/Cellar/postgresql/9.5.4/include -I/usr/local/Cellar/postgresql/9.5.4/include/server -c psycopg/adapter_pint.c -o build/temp.macosx-10.6-intel-3.5/psycopg/adapter_pint.o 
    /usr/bin/clang -DNDEBUG -g -fwrapv -O3 -Wall -Wstrict-prototypes -Qunused-arguments -Qunused-arguments -DPSYCOPG_DEFAULT_PYDATETIME=1 -DPSYCOPG_VERSION="2.6.2 (dt dec pq3 ext lo64)" -DPG_VERSION_HEX=0x090504 -DHAVE_LO64=1 -I/Library/Frameworks/Python.framework/Versions/3.5/include/python3.5m -I. -I/usr/local/Cellar/postgresql/9.5.4/include -I/usr/local/Cellar/postgresql/9.5.4/include/server -c psycopg/adapter_pfloat.c -o build/temp.macosx-10.6-intel-3.5/psycopg/adapter_pfloat.o 
    /usr/bin/clang -DNDEBUG -g -fwrapv -O3 -Wall -Wstrict-prototypes -Qunused-arguments -Qunused-arguments -DPSYCOPG_DEFAULT_PYDATETIME=1 -DPSYCOPG_VERSION="2.6.2 (dt dec pq3 ext lo64)" -DPG_VERSION_HEX=0x090504 -DHAVE_LO64=1 -I/Library/Frameworks/Python.framework/Versions/3.5/include/python3.5m -I. -I/usr/local/Cellar/postgresql/9.5.4/include -I/usr/local/Cellar/postgresql/9.5.4/include/server -c psycopg/adapter_qstring.c -o build/temp.macosx-10.6-intel-3.5/psycopg/adapter_qstring.o 
    /usr/bin/clang -DNDEBUG -g -fwrapv -O3 -Wall -Wstrict-prototypes -Qunused-arguments -Qunused-arguments -DPSYCOPG_DEFAULT_PYDATETIME=1 -DPSYCOPG_VERSION="2.6.2 (dt dec pq3 ext lo64)" -DPG_VERSION_HEX=0x090504 -DHAVE_LO64=1 -I/Library/Frameworks/Python.framework/Versions/3.5/include/python3.5m -I. -I/usr/local/Cellar/postgresql/9.5.4/include -I/usr/local/Cellar/postgresql/9.5.4/include/server -c psycopg/microprotocols.c -o build/temp.macosx-10.6-intel-3.5/psycopg/microprotocols.o 
    /usr/bin/clang -DNDEBUG -g -fwrapv -O3 -Wall -Wstrict-prototypes -Qunused-arguments -Qunused-arguments -DPSYCOPG_DEFAULT_PYDATETIME=1 -DPSYCOPG_VERSION="2.6.2 (dt dec pq3 ext lo64)" -DPG_VERSION_HEX=0x090504 -DHAVE_LO64=1 -I/Library/Frameworks/Python.framework/Versions/3.5/include/python3.5m -I. -I/usr/local/Cellar/postgresql/9.5.4/include -I/usr/local/Cellar/postgresql/9.5.4/include/server -c psycopg/microprotocols_proto.c -o build/temp.macosx-10.6-intel-3.5/psycopg/microprotocols_proto.o 
    In file included from psycopg/microprotocols_proto.c:27: 
    In file included from ./psycopg/psycopg.h:33: 
    ./psycopg/config.h:71:13: warning: unused function 'Dprintf' [-Wunused-function] 
    static void Dprintf(const char *fmt, ...) {} 
       ^
    1 warning generated. 
    /usr/bin/clang -DNDEBUG -g -fwrapv -O3 -Wall -Wstrict-prototypes -Qunused-arguments -Qunused-arguments -DPSYCOPG_DEFAULT_PYDATETIME=1 -DPSYCOPG_VERSION="2.6.2 (dt dec pq3 ext lo64)" -DPG_VERSION_HEX=0x090504 -DHAVE_LO64=1 -I/Library/Frameworks/Python.framework/Versions/3.5/include/python3.5m -I. -I/usr/local/Cellar/postgresql/9.5.4/include -I/usr/local/Cellar/postgresql/9.5.4/include/server -c psycopg/typecast.c -o build/temp.macosx-10.6-intel-3.5/psycopg/typecast.o 
    psycopg/typecast.c:494:5: warning: incompatible pointer types initializing 'PyAsyncMethods *' with an expression of type 'int (PyObject *, PyObject *)' (aka 'int (struct _object *, struct _object *)') [-Wincompatible-pointer-types] 
     typecast_cmp, /*tp_compare*/ 
     ^~~~~~~~~~~~ 
    1 warning generated. 
    /usr/bin/clang -bundle -undefined dynamic_lookup -arch i386 -arch x86_64 -g -Qunused-arguments -Qunused-arguments build/temp.macosx-10.6-intel-3.5/psycopg/psycopgmodule.o build/temp.macosx-10.6-intel-3.5/psycopg/green.o build/temp.macosx-10.6-intel-3.5/psycopg/pqpath.o build/temp.macosx-10.6-intel-3.5/psycopg/utils.o build/temp.macosx-10.6-intel-3.5/psycopg/bytes_format.o build/temp.macosx-10.6-intel-3.5/psycopg/connection_int.o build/temp.macosx-10.6-intel-3.5/psycopg/connection_type.o build/temp.macosx-10.6-intel-3.5/psycopg/cursor_int.o build/temp.macosx-10.6-intel-3.5/psycopg/cursor_type.o build/temp.macosx-10.6-intel-3.5/psycopg/diagnostics_type.o build/temp.macosx-10.6-intel-3.5/psycopg/error_type.o build/temp.macosx-10.6-intel-3.5/psycopg/lobject_int.o build/temp.macosx-10.6-intel-3.5/psycopg/lobject_type.o build/temp.macosx-10.6-intel-3.5/psycopg/notify_type.o build/temp.macosx-10.6-intel-3.5/psycopg/xid_type.o build/temp.macosx-10.6-intel-3.5/psycopg/adapter_asis.o build/temp.macosx-10.6-intel-3.5/psycopg/adapter_binary.o build/temp.macosx-10.6-intel-3.5/psycopg/adapter_datetime.o build/temp.macosx-10.6-intel-3.5/psycopg/adapter_list.o build/temp.macosx-10.6-intel-3.5/psycopg/adapter_pboolean.o build/temp.macosx-10.6-intel-3.5/psycopg/adapter_pdecimal.o build/temp.macosx-10.6-intel-3.5/psycopg/adapter_pint.o build/temp.macosx-10.6-intel-3.5/psycopg/adapter_pfloat.o build/temp.macosx-10.6-intel-3.5/psycopg/adapter_qstring.o build/temp.macosx-10.6-intel-3.5/psycopg/microprotocols.o build/temp.macosx-10.6-intel-3.5/psycopg/microprotocols_proto.o build/temp.macosx-10.6-intel-3.5/psycopg/typecast.o -L/usr/local/lib -lpq -lssl -lcrypto -o build/lib.macosx-10.6-intel-3.5/psycopg2/_psycopg.cpython-35m-darwin.so 
    ld: library not found for -lssl 
    clang: error: linker command failed with exit code 1 (use -v to see invocation) 
    error: command '/usr/bin/clang' failed with exit status 1 

    ---------------------------------------- 
Command "/usr/local/bin/python3 -u -c "import setuptools, tokenize;__file__='/private/var/folders/mn/t5nqmwlj5wb99lyzrkq_d0qc0000gn/T/pip-build-darwcjmh/psycopg2/setup.py';exec(compile(getattr(tokenize, 'open', open)(__file__).read().replace('\r\n', '\n'), __file__, 'exec'))" install --record /var/folders/mn/t5nqmw 

다른 사람이 실행했습니다 또는이 문제에 대한 해결책이 있습니까?

+0

1. 해당 텍스트에는 실제 오류 메시지가 없습니다. 실제 오류를 찾으십시오. 2. Mac 용 소스 버전 인 [version] (https://pypi.python.org/pypi/psycopg2) pip가 다운로드됩니다. Mac 용 기본 패키지입니까? – jpmc26

+1

자세한 내용 (jpmc26에서 제안한대로)을 편집하면 "ld : -lssl에 대해 라이브러리를 찾을 수 없습니다."라는 오류 메시지가 표시되면서 명확합니다. libssl을 설치하십시오. ('/ usr/local/bin/python3'은 Homebrew를 사용하고 있음을 나타내며'brew install openssl'을 시도하십시오). – Evert

+0

시도해 본 후에 같은 오류가 발생했습니다 –

답변

2

아마도 업그레이드 한 후 xcode를 다시 설치하지 않았습니까?

xcode-select --install 
+0

생명의 보호자가 되셨습니다! 이 문제가 발생하는 이유를 알고 있습니까? 이 명령은 각 OSX 업그레이드 후에 실행하는 것이 좋은가요? –

+0

새로운 버전의 OS와 xcode가 동시에 릴리스되었습니다. Mac OS X 시에라는 xcode의 새로운 버전을 요구할 수 있습니다. –