akoumjian / datefinder

Find dates inside text using Python and get back datetime objects
http://datefinder.readthedocs.org/en/latest/
MIT License
635 stars 167 forks source link

can't install datefinder #60

Closed tahirahmad2030 closed 6 years ago

tahirahmad2030 commented 7 years ago

Failed building wheel for regex Running setup.py clean for regex Failed to build regex Installing collected packages: regex, datefinder Running setup.py install for regex ... error Complete output from command /usr/bin/python -u -c "import setuptools, tokenize;file='/tmp/pip-build-QCCGKo/regex/setup.py';f=getattr(tokenize, 'open', open)(file);code=f.read().replace('\r\n', '\n');f.close();exec(compile(code, file, 'exec'))" install --record /tmp/pip-I_ImpH-record/install-record.txt --single-version-externally-managed --compile: /usr/local/lib/python2.7/dist-packages/setuptools/dist.py:351: UserWarning: Normalizing '2016.01.10' to '2016.1.10' normalized_version, running install running build running build_py creating build creating build/lib.linux-x86_64-2.7 copying Python2/regex.py -> build/lib.linux-x86_64-2.7 copying Python2/_regex_core.py -> build/lib.linux-x86_64-2.7 copying Python2/test_regex.py -> build/lib.linux-x86_64-2.7 running build_ext building '_regex' extension creating build/temp.linux-x86_64-2.7 creating build/temp.linux-x86_64-2.7/Python2 x86_64-linux-gnu-gcc -pthread -DNDEBUG -g -fwrapv -O2 -Wall -Wstrict-prototypes -fno-strict-aliasing -D_FORTIFY_SOURCE=2 -g -fstack-protector --param=ssp-buffer-size=4 -Wformat -Werror=format-security -fPIC -I/usr/include/python2.7 -c Python2/_regex.c -o build/temp.linux-x86_64-2.7/Python2/_regex.o Python2/_regex.c:46:20: fatal error: Python.h: No such file or directory

include "Python.h"

                    ^
compilation terminated.
error: command 'x86_64-linux-gnu-gcc' failed with exit status 1

----------------------------------------

Command "/usr/bin/python -u -c "import setuptools, tokenize;file='/tmp/pip-build-QCCGKo/regex/setup.py';f=getattr(tokenize, 'open', open)(file);code=f.read().replace('\r\n', '\n');f.close();exec(compile(code, file, 'exec'))" install --record /tmp/pip-I_ImpH-record/install-record.txt --single-version-externally-managed --compile" failed with error code 1 in /tmp/pip-build-QCCGKo/regex/

twakawl commented 7 years ago

Have the same problem while trying to install on windows 10, fails building wheel for regex.

This while " pip install regex" gives no problems.

Would be great is someone could help :)

ldbiz commented 6 years ago

@twakawl I had problems on Windows 7. The log indicated installing Visual Studio C++ 14 build tools, which resolved it for me. See here, where upgrading setuptools is also suggested and should be tried first.

If the Windows compiler is also the issue for you, then more context and version information here:

https://wiki.python.org/moin/WindowsCompilers

tahirahmad2030 commented 6 years ago

I had installed python-dev that soleved my issue