In
http://stackoverflow.com/questions/20789063/get-fatal-error-when-install-psycopg2
OP mentions that "Just installed python 3.4 and assumed python3-dev would
suffice. Nope. Had to do python3.4-dev. "

Perhaps you need to do the same thing...



On 25 July 2014 10:29, Henrique Oliveira <henriqueollive...@gmail.com>
wrote:

> Hi Mario,
>
> I already installed python-dev
> On Jul 24, 2014 9:11 PM, "Mario Gudelj" <mario.gud...@gmail.com> wrote:
>
>> Install this first:
>>
>> sudo apt-get install python-dev
>>
>> Then try installing that package again.
>>
>>
>> On 25 July 2014 09:55, Henrique Oliveira <henriqueollive...@gmail.com>
>> wrote:
>>
>>>
>>>
>>>
>>>
>>>
>>> *Hi All,I am trying to install psycopg2 but I am getting this error:*I
>>> already installed python3-dev and libpq-dev Any idea?*
>>>
>>> Downloading/unpacking psycopg2
>>>   Downloading psycopg2-2.5.3.tar.gz (690kB): 690kB downloaded
>>>   Running setup.py (path:/opt/d/build/psycopg2/setup.py) egg_info for
>>> package psycopg2
>>>
>>> Installing collected packages: psycopg2
>>>   Running setup.py install for psycopg2
>>>     Skipping implicit fixer: buffer
>>>     Skipping implicit fixer: idioms
>>>     Skipping implicit fixer: set_literal
>>>     Skipping implicit fixer: ws_comma
>>>     building 'psycopg2._psycopg' extension
>>>     gcc -pthread -Wno-unused-result -DNDEBUG -g -fwrapv -O2 -Wall
>>> -Wstrict-prototypes -g -O2 -fstack-protector --param=ssp-buffer-size=4
>>> -Wformat -Werror=format-security -fPIC -DPSYCOPG_DEFAULT_PYDATETIME=1
>>> -DPSYCOPG_VERSION="2.5.3 (dt dec pq3 ext)" -DPSYCOPG_EXTENSIONS=1
>>> -DPSYCOPG_NEW_BOOLEAN=1 -DHAVE_PQFREEMEM=1 -DPG_VERSION_HEX=0x090304
>>> -DPSYCOPG_EXTENSIONS=1 -DPSYCOPG_NEW_BOOLEAN=1 -DHAVE_PQFREEMEM=1
>>> -I/usr/include/python3.3m -I. -I/usr/include/postgresql
>>> -I/usr/include/postgresql/9.3/server -c psycopg/psycopgmodule.c -o
>>> build/temp.linux-x86_64-3.3/psycopg/psycopgmodule.o
>>> -Wdeclaration-after-statement
>>>     In file included from psycopg/psycopgmodule.c:27:0:
>>>     ./psycopg/psycopg.h:30:20: fatal error: Python.h: No such file or
>>> directory
>>>      #include <Python.h>
>>>                         ^
>>>     compilation terminated.
>>>     error: command 'gcc' failed with exit status 1
>>>     Complete output from command /opt/d/bin/python3.3 -c "import
>>> setuptools,
>>> tokenize;__file__='/opt/d/build/psycopg2/setup.py';exec(compile(getattr(tokenize,
>>> 'open', open)(__file__).read().replace('\r\n', '\n'), __file__, 'exec'))"
>>> install --record /tmp/pip-on_knf-record/install-record.txt
>>> --single-version-externally-managed --compile --install-headers
>>> /opt/d/include/site/python3.3:
>>>     running install
>>>
>>> running build
>>>
>>> running build_py
>>>
>>> creating build
>>>
>>> creating build/lib.linux-x86_64-3.3
>>>
>>> creating build/lib.linux-x86_64-3.3/psycopg2
>>>
>>> copying lib/extensions.py -> build/lib.linux-x86_64-3.3/psycopg2
>>>
>>> copying lib/extras.py -> build/lib.linux-x86_64-3.3/psycopg2
>>>
>>> copying lib/__init__.py -> build/lib.linux-x86_64-3.3/psycopg2
>>>
>>> copying lib/_range.py -> build/lib.linux-x86_64-3.3/psycopg2
>>>
>>> copying lib/psycopg1.py -> build/lib.linux-x86_64-3.3/psycopg2
>>>
>>> copying lib/_json.py -> build/lib.linux-x86_64-3.3/psycopg2
>>>
>>> copying lib/errorcodes.py -> build/lib.linux-x86_64-3.3/psycopg2
>>>
>>> copying lib/pool.py -> build/lib.linux-x86_64-3.3/psycopg2
>>>
>>> copying lib/tz.py -> build/lib.linux-x86_64-3.3/psycopg2
>>>
>>> creating build/lib.linux-x86_64-3.3/psycopg2/tests
>>>
>>> copying tests/test_types_extras.py ->
>>> build/lib.linux-x86_64-3.3/psycopg2/tests
>>>
>>> copying tests/test_bugX000.py ->
>>> build/lib.linux-x86_64-3.3/psycopg2/tests
>>>
>>> copying tests/test_async.py -> build/lib.linux-x86_64-3.3/psycopg2/tests
>>>
>>> copying tests/testconfig.py -> build/lib.linux-x86_64-3.3/psycopg2/tests
>>>
>>> copying tests/test_module.py -> build/lib.linux-x86_64-3.3/psycopg2/tests
>>>
>>> copying tests/test_with.py -> build/lib.linux-x86_64-3.3/psycopg2/tests
>>>
>>> copying tests/test_quote.py -> build/lib.linux-x86_64-3.3/psycopg2/tests
>>>
>>> copying tests/test_cursor.py -> build/lib.linux-x86_64-3.3/psycopg2/tests
>>>
>>> copying tests/test_cancel.py -> build/lib.linux-x86_64-3.3/psycopg2/tests
>>>
>>> copying tests/test_transaction.py ->
>>> build/lib.linux-x86_64-3.3/psycopg2/tests
>>>
>>> copying tests/__init__.py -> build/lib.linux-x86_64-3.3/psycopg2/tests
>>>
>>> copying tests/test_connection.py ->
>>> build/lib.linux-x86_64-3.3/psycopg2/tests
>>>
>>> copying tests/test_notify.py -> build/lib.linux-x86_64-3.3/psycopg2/tests
>>>
>>> copying tests/test_copy.py -> build/lib.linux-x86_64-3.3/psycopg2/tests
>>>
>>> copying tests/test_bug_gc.py -> build/lib.linux-x86_64-3.3/psycopg2/tests
>>>
>>> copying tests/test_green.py -> build/lib.linux-x86_64-3.3/psycopg2/tests
>>>
>>> copying tests/dbapi20_tpc.py -> build/lib.linux-x86_64-3.3/psycopg2/tests
>>>
>>> copying tests/test_types_basic.py ->
>>> build/lib.linux-x86_64-3.3/psycopg2/tests
>>>
>>> copying tests/test_extras_dictcursor.py ->
>>> build/lib.linux-x86_64-3.3/psycopg2/tests
>>>
>>> copying tests/test_psycopg2_dbapi20.py ->
>>> build/lib.linux-x86_64-3.3/psycopg2/tests
>>>
>>> copying tests/test_lobject.py ->
>>> build/lib.linux-x86_64-3.3/psycopg2/tests
>>>
>>> copying tests/test_dates.py -> build/lib.linux-x86_64-3.3/psycopg2/tests
>>>
>>> copying tests/dbapi20.py -> build/lib.linux-x86_64-3.3/psycopg2/tests
>>>
>>> copying tests/testutils.py -> build/lib.linux-x86_64-3.3/psycopg2/tests
>>>
>>> Skipping implicit fixer: buffer
>>>
>>> Skipping implicit fixer: idioms
>>>
>>> Skipping implicit fixer: set_literal
>>>
>>> Skipping implicit fixer: ws_comma
>>>
>>> running build_ext
>>>
>>> building 'psycopg2._psycopg' extension
>>>
>>> creating build/temp.linux-x86_64-3.3
>>>
>>> creating build/temp.linux-x86_64-3.3/psycopg
>>>
>>> gcc -pthread -Wno-unused-result -DNDEBUG -g -fwrapv -O2 -Wall
>>> -Wstrict-prototypes -g -O2 -fstack-protector --param=ssp-buffer-size=4
>>> -Wformat -Werror=format-security -fPIC -DPSYCOPG_DEFAULT_PYDATETIME=1
>>> -DPSYCOPG_VERSION="2.5.3 (dt dec pq3 ext)" -DPSYCOPG_EXTENSIONS=1
>>> -DPSYCOPG_NEW_BOOLEAN=1 -DHAVE_PQFREEMEM=1 -DPG_VERSION_HEX=0x090304
>>> -DPSYCOPG_EXTENSIONS=1 -DPSYCOPG_NEW_BOOLEAN=1 -DHAVE_PQFREEMEM=1
>>> -I/usr/include/python3.3m -I. -I/usr/include/postgresql
>>> -I/usr/include/postgresql/9.3/server -c psycopg/psycopgmodule.c -o
>>> build/temp.linux-x86_64-3.3/psycopg/psycopgmodule.o
>>> -Wdeclaration-after-statement
>>>
>>> In file included from psycopg/psycopgmodule.c:27:0:
>>>
>>> ./psycopg/psycopg.h:30:20: fatal error: Python.h: No such file or
>>> directory
>>>
>>>  #include <Python.h>
>>>
>>>                     ^
>>>
>>> compilation terminated.
>>>
>>> error: command 'gcc' failed with exit status 1
>>>
>>> --
>>> You received this message because you are subscribed to the Google
>>> Groups "Django users" group.
>>> To unsubscribe from this group and stop receiving emails from it, send
>>> an email to django-users+unsubscr...@googlegroups.com.
>>> To post to this group, send email to django-users@googlegroups.com.
>>> Visit this group at http://groups.google.com/group/django-users.
>>> To view this discussion on the web visit
>>> https://groups.google.com/d/msgid/django-users/73c6a17e-340a-40fe-a4d9-dc00a461d097%40googlegroups.com
>>> <https://groups.google.com/d/msgid/django-users/73c6a17e-340a-40fe-a4d9-dc00a461d097%40googlegroups.com?utm_medium=email&utm_source=footer>
>>> .
>>> For more options, visit https://groups.google.com/d/optout.
>>>
>>
>>  --
>> You received this message because you are subscribed to a topic in the
>> Google Groups "Django users" group.
>> To unsubscribe from this topic, visit
>> https://groups.google.com/d/topic/django-users/Pl29U0M45hk/unsubscribe.
>> To unsubscribe from this group and all its topics, send an email to
>> django-users+unsubscr...@googlegroups.com.
>> To post to this group, send email to django-users@googlegroups.com.
>> Visit this group at http://groups.google.com/group/django-users.
>> To view this discussion on the web visit
>> https://groups.google.com/d/msgid/django-users/CAHqTbjnHAA-pRytqJCGM_Fjtaf_sD3y9sLGq%3DZjJtEnyuiPUjw%40mail.gmail.com
>> <https://groups.google.com/d/msgid/django-users/CAHqTbjnHAA-pRytqJCGM_Fjtaf_sD3y9sLGq%3DZjJtEnyuiPUjw%40mail.gmail.com?utm_medium=email&utm_source=footer>
>> .
>> For more options, visit https://groups.google.com/d/optout.
>>
>  --
> You received this message because you are subscribed to the Google Groups
> "Django users" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to django-users+unsubscr...@googlegroups.com.
> To post to this group, send email to django-users@googlegroups.com.
> Visit this group at http://groups.google.com/group/django-users.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/django-users/CAO1t7J2hkHruv82K88HEhYdAmbWeQBg0bYWVPtmKqTQG_rwPTA%40mail.gmail.com
> <https://groups.google.com/d/msgid/django-users/CAO1t7J2hkHruv82K88HEhYdAmbWeQBg0bYWVPtmKqTQG_rwPTA%40mail.gmail.com?utm_medium=email&utm_source=footer>
> .
> For more options, visit https://groups.google.com/d/optout.
>

-- 
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-users+unsubscr...@googlegroups.com.
To post to this group, send email to django-users@googlegroups.com.
Visit this group at http://groups.google.com/group/django-users.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/CAHqTbj%3DsZSgjHssWAX4UHuKc8HAe_-ggqYnimh7maSfG%2B13_gA%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to