jalan / pdftotext

Simple PDF text extraction
MIT License
870 stars 99 forks source link

Can't install this on macOS Big Sur 11.6 #90

Closed anshul-klaarhq closed 3 years ago

anshul-klaarhq commented 3 years ago

on running this pip install pdftotext getting error

creating build/temp.macosx-11-universal2-3.8
    gcc -Wno-unused-result -Wsign-compare -Wunreachable-code -fno-common -dynamic -DNDEBUG -g -fwrapv -O3 -Wall -arch arm64 -arch x86_64 -g -DPOPPLER_CPP_AT_LEAST_0_30_0=1 -DPOPPLER_CPP_AT_LEAST_0_58_0=1 -DPOPPLER_CPP_AT_LEAST_0_88_0=1 -I/usr/local/include -I/Users/anshulgupta/WorkSpace/Klaarhq/klaar-api/venv/include -I/Library/Frameworks/Python.framework/Versions/3.8/include/python3.8 -c pdftotext.cpp -o build/temp.macosx-11-universal2-3.8/pdftotext.o -Wall -mmacosx-version-min=10.9 -std=c++11
    pdftotext.cpp:3:10: fatal error: 'poppler/cpp/poppler-document.h' file not found
    #include <poppler/cpp/poppler-document.h>
             ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    1 error generated.
    error: command 'gcc' failed with exit status 1
    ----------------------------------------

I have also ran this command

brew install pkg-config poppler
Warning: pkg-config 0.29.2_3 is already installed and up-to-date.
To reinstall 0.29.2_3, run:
  brew reinstall pkg-config
Warning: poppler 21.09.0 is already installed and up-to-date.
To reinstall 21.09.0, run:
  brew reinstall poppler

but still its not working.

jalan commented 3 years ago

This was probably fixed by #86, but unfortunately I haven't published a release including that fix yet.

My dev machine is currently in pieces on my office floor 😄 As soon as I get it put back together, I'll do a release, hopefully tomorrow.

jalan commented 3 years ago

I just published a release including the fix. Please try out version 2.2.1.

anshul-klaarhq commented 3 years ago

Hi Jalan, this worked. Thanks for quick response and package upgrade.