openvenues / pypostal

Python bindings to libpostal for fast international address parsing/normalization
MIT License
762 stars 86 forks source link

Unable to run setup.py build_ext --inplace #72

Open rgprasad84 opened 3 years ago

rgprasad84 commented 3 years ago

I'm facing the below error while running the setup.py and below are the detail.s Please let me know if anyone has encountered the same issue and have a fix for this.

/opt/anaconda3/bin/python setup.py build_ext --inplace running build_ext building 'postal._expand' extension gcc -pthread -Wsign-compare -DNDEBUG -g -fwrapv -O3 -Wall -Wstrict-prototypes -fPIC -I/usr/local/include -I/opt/anaconda3/include/python3.6m -c postal/pyexpand.c -o build/temp.linux-x86_64-3.6/postal/pyexpand.o -std=c99 -Wno-unused-function postal/pyexpand.c: In function ‘py_expand’: postal/pyexpand.c:204: warning: comparison between signed and unsigned integer expressions postal/pyexpand.c:219: warning: comparison between signed and unsigned integer expressions postal/pyexpand.c:236: warning: label ‘exit_decref_unistr’ defined but not used gcc -pthread -shared -L/opt/anaconda3.6/lib -Wl,-rpath=/opt/anaconda3.6/lib,--no-as-needed build/temp.linux-x86_64-3.6/postal/pyexpand.o -L/usr/local/lib -L/opt/anaconda3.6/lib -lpostal -lpython3.6m -o build/lib.linux-x86_64-3.6/postal/_expand.cpython-36m-x86_64-linux-gnu.so /usr/bin/ld: /usr/local/lib/libpython3.6m.a(abstract.o): relocation R_X86_64_32S against `_PyObject_NextNotImplemented' can not be used when making a shared object; recompile with -fPIC /usr/local/lib/libpython3.6m.a: could not read symbols: Bad value collect2: ld returned 1 exit status error: command 'gcc' failed with exit status 1

OS Version - CentOS release 6.6 (Final)

Python Version : Python 3.6.0 |Anaconda 4.3.0 (64-bit)| (default, Dec 23 2016, 12:22:00) [GCC 4.4.7 20120313 (Red Hat 4.4.7-1)] on linux