Replies: 8 comments 1 reply
-
PyMuPDF 我安装的是1.20.2 这个版本。 |
Beta Was this translation helpful? Give feedback.
-
你需要把devenv.com的路径添加到path环境变量里 |
Beta Was this translation helpful? Give feedback.
-
python版本太高了,在anaconda里新建个环境,下3.9的就行 |
Beta Was this translation helpful? Give feedback.
-
我是python 3.9,mac M2 晶片! xcrun ranlib build/release/libmupdf-pkcs7.a
mkdir -p build/release/source/helpers/mu-threads/ ; xcrun cc -ffunction-sections -fdata-sections -pipe -O2 -DNDEBUG -fomit-frame-pointer -Iinclude -MMD -MP -o build/release/source/helpers/mu-threads/mu-threads.o -c source/helpers/mu-threads/mu-threads.c -Wall -Wsign-compare
mkdir -p build/release/ ; xcrun ar cr build/release/libmupdf-threads.a build/release/source/helpers/mu-threads/mu-threads.o
xcrun ranlib build/release/libmupdf-threads.a
mkdir -p build/release/ ; xcrun cc -Wl,-dead_strip -Wl,-s -o build/release/mutool build/release/source/tools/mutool.o build/release/source/tools/muconvert.o build/release/source/tools/mudraw.o build/release/source/tools/murun.o build/release/source/tools/mutrace.o build/release/source/tools/cmapdump.o build/release/source/tools/pdfclean.o build/release/source/tools/pdfcreate.o build/release/source/tools/pdfextract.o build/release/source/tools/pdfinfo.o build/release/source/tools/pdfmerge.o build/release/source/tools/pdfpages.o build/release/source/tools/pdfposter.o build/release/source/tools/pdfshow.o build/release/source/tools/pdfsign.o build/release/libmupdf.a build/release/libmupdf-third.a build/release/libmupdf-pkcs7.a build/release/libmupdf-threads.a -lm -lpthread -lstdc++ -L/opt/homebrew/Cellar/openssl@3/3.1.4/lib -lcrypto
ld: warning: option -s is obsolete and being ignored
mkdir -p build/release/source/tools/ ; xcrun cc -ffunction-sections -fdata-sections -pipe -O2 -DNDEBUG -fomit-frame-pointer -Iinclude -MMD -MP -o build/release/source/tools/muraster.o -c source/tools/muraster.c -Wall -Wsign-compare -Ithirdparty/freetype/include -Iscripts/freetype -Ithirdparty/gumbo-parser/src -Ithirdparty/harfbuzz/src -Ithirdparty/libjpeg -Iscripts/libjpeg -Ithirdparty/lcms2/include -DHAVE_LCMS2MT -Ithirdparty/mujs -Ithirdparty/zlib -Ithirdparty/jbig2dec -Ithirdparty/openjpeg/src/lib/openjp2 -DOPJ_STATIC -DOPJ_HAVE_INTTYPES_H -DOPJ_HAVE_STDINT_H -DHAVE_LEPTONICA -Ithirdparty/leptonica/src -DHAVE_TESSERACT -Ithirdparty/tesseract/include -Iscripts/tesseract -Ithirdparty/extract/include
mkdir -p build/release/ ; xcrun cc -Wl,-dead_strip -Wl,-s -o build/release/muraster build/release/source/tools/muraster.o build/release/libmupdf.a build/release/libmupdf-third.a build/release/libmupdf-pkcs7.a build/release/libmupdf-threads.a -lm -lpthread -lstdc++ -L/opt/homebrew/Cellar/openssl@3/3.1.4/lib -lcrypto
ld: warning: option -s is obsolete and being ignored
build/release:
total 161304
drwxr-xr-x@ 3 user staff 96 Nov 9 21:28 generated
-rw-r--r--@ 1 user staff 17200 Nov 9 21:30 libmupdf-pkcs7.a
-rw-r--r--@ 1 user staff 12913480 Nov 9 21:30 libmupdf-third.a
-rw-r--r--@ 1 user staff 2080 Nov 9 21:30 libmupdf-threads.a
-rw-r--r--@ 1 user staff 48714864 Nov 9 21:28 libmupdf.a
-rwxr-xr-x@ 1 user staff 9039461 Nov 9 21:30 muraster
-rwxr-xr-x@ 1 user staff 11888515 Nov 9 21:30 mutool
drwxr-xr-x@ 11 user staff 352 Nov 9 21:30 source
drwxr-xr-x@ 14 user staff 448 Nov 9 21:30 thirdparty
PyMuPDF/setup.py: Finished building mupdf.
PyMuPDF/setup.py: sys.platform='darwin'
PyMuPDF/setup.py: library_dirs=['mupdf-1.20.3-source/build/release', 'mupdf-1.20.3-source/build/release']
PyMuPDF/setup.py: libraries=['mupdf', 'mupdf-third']
PyMuPDF/setup.py: include_dirs=['mupdf-1.20.3-source/include', 'mupdf-1.20.3-source/include/mupdf', 'mupdf-1.20.3-source/thirdparty/freetype/include']
PyMuPDF/setup.py: extra_link_args=[]
running bdist_wheel
running build
running build_py
running build_ext
building 'fitz._fitz' extension
swigging fitz/fitz.i to fitz/fitz_wrap.c
swig -python -o fitz/fitz_wrap.c fitz/fitz.i
error: command 'swig' failed: Not a directory
[end of output]
note: This error originates from a subprocess, and is likely not a problem with pip.
ERROR: Failed building wheel for PyMuPDF
Building wheel for lmdb (pyproject.toml) ... done
Created wheel for lmdb: filename=lmdb-1.4.1-cp39-cp39-macosx_10_9_universal2.whl size=169635 sha256=e2e759409c93de37cacc8c11b711fc1ecc5b581beb39cb62833a00279dbd70cf
Stored in directory: /Users/user/Library/Caches/pip/wheels/84/55/b3/bf057744f7438df5fdd827e608375a671404240663202e5ff0
Building wheel for lxml (pyproject.toml) ... done
Created wheel for lxml: filename=lxml-4.9.3-cp39-cp39-macosx_10_9_universal2.whl size=3108214 sha256=d1a604e2ef512ff8de78c39d80e2a436d55655d6a5ef9362abb25a8a29b019a4
Stored in directory: /Users/user/Library/Caches/pip/wheels/5c/05/aa/530f84480d476c5bb9ea09877eea78fb144ec047fbb00ee2ca
Successfully built fire lmdb lxml
Failed to build PyMuPDF
ERROR: Could not build wheels for PyMuPDF, which is required to install pyproject.toml-based projects 不知道該怎麼辦 |
Beta Was this translation helpful? Give feedback.
-
Same problem here |
Beta Was this translation helpful? Give feedback.
-
遇到相同的问题,通过brew install swig 解决 @arguskao @EricLiuAno |
Beta Was this translation helpful? Give feedback.
-
this issue persists on 3.11 windows. |
Beta Was this translation helpful? Give feedback.
-
如果我没有处理PDF的需求,有什么办法可以避免安装这些PDF相关的玩意 |
Beta Was this translation helpful? Give feedback.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
安装paddleOCR时,安装到PyMuPDF提示安装错误,错误信息如下,请问如何解决?
安装环境是conda,python=3.11,paddle是CPU版
Beta Was this translation helpful? Give feedback.
All reactions