gpt4 book ai didi

qt - 由于 poppler,无法在 Windows 上安装 pdftotext

转载 作者:行者123 更新时间:2023-12-05 07:30:25 25 4
gpt4 key购买 nike

我正在尝试在 Windows 上安装 pdftotext:

pip install pdftotext

它最初失败是因为缺少 MS visual studio(现已安装),现在由于 poppler 问题而失败。我已经下载了 poppler,它安装在

C:\Program Files (x86)\poppler

我的路径包括这个目录。

安装失败并出现错误 screen image of error

我在 Program Files (x86) 中找不到文件 poppler-cpp.lib

我知道安装 poppler 是有问题的,网络上有很多与之相关的问题和 one seems to be my problem exactly (标记于 2018 年 7 月 19 日),但似乎没有提供任何解决方案。我把它安装在 linux 上,它像梦一样工作。但是,我也需要在 Windows 上工作。

有人可以帮我解决这个问题吗?

[编辑 2018.09.17 我找到了对它的引用 here :

... The problem was that this binaries files were dynamic and, from the files with .lib extension (poppler.lib, poppler-cpp.lib, poppler-qt4.lib), only poppler.lib was a static library. Due to this, and using the cMake files content in the download of the source code of poppler I tried to generate static versions from all the dependencies of poppler, which was an easy thing to do ...

这会帮助别人来帮助我吗?

最佳答案

我遇到了完全相同的问题,但无法编译解决方案。

我正在使用的解决方法是运行与 miktex 2.9 一起安装的 pdftotext.exe(我已经将其用于 latex )。

安装miktex后确定pdftotext.exe的路径。然后您可以使用子流程模块运行它。

Import subprocess
Subprocess.call([path/pdftotext.exe,
options, file.pdf])

用你需要的选项切换选项。

关于qt - 由于 poppler,无法在 Windows 上安装 pdftotext,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/52336495/

25 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com