答案1
- 如果你想自己编译软件,那么需要其他库是正常的。通常,这些库可用于 Ubuntu
- 如果没有,则从第 1 点重新开始=)
因为pdfpc
您需要libPoppler
和librsvg
。因此,在您的系统中开始搜索:
libPoppler
% apt-cache search --names-only '^libPoppler.*dev$' libpoppler-cpp-dev - PDF rendering library -- development files (CPP interface) libpoppler-dev - PDF rendering library -- development files libpoppler-glib-dev - PDF rendering library -- development files (GLib interface) libpoppler-private-dev - PDF rendering library -- private development files libpoppler-qt4-dev - PDF rendering library -- development files (Qt 4 interface) libpoppler-qt5-dev - PDF rendering library -- development files (Qt 5 interface) libpoppler-cil-dev - PDF rendering library -- CLI development files libpopplerkit-dev - GNUstep framework for rendering PDF content (development files)
我会说,
libpoppler-dev
没问题,因此sudo apt-get install libpoppler-dev
librsvg
% apt-cache search --names-only '^librsvg.*dev$' librsvg2-dev - SAX-based renderer library for SVG files (development) librsvg2-2.0-cil-dev - CLI binding for RSVG 2.22
所以
sudo apt-get install librsvg2-dev
现在测试
mkdir -p ~/src
wget https://github.com/downloads/davvil/pdfpc/pdfpc-3.1.1.tgz
tar xf pdfpc-3.1.1.tgz -C ~/src
cd pdfpc-3.1.1
cmake .
我明白了
-- package 'gee-1.0' not found
CMake Error at /usr/share/cmake-3.2/Modules/FindPkgConfig.cmake:344 (message):
A required package was not found
好的,需要另一个包
% apt-cache search --names-only '^libgee.*dev$'
libgee-0.8-dev - GObject based collection and utility library (development files)
libgee-dev - GObject based collection library (development files)
所以
sudo apt-get install libgee-dev
然后再次
cmake .
另一件事
-- checking for module 'poppler-glib'
-- package 'poppler-glib' not found
然后再次
% apt-cache search --names-only '^libpoppler.*glib.*dev$'
libpoppler-glib-dev - PDF rendering library -- development files (GLib interface)
和
sudo apt-get install libpoppler-glib-dev
然后再次哦哦
cmake .
而且......很棒^_^
-- checking for module 'poppler-glib'
-- found poppler-glib, version 0.30.0
-- checking for module 'gtk+-2.0'
-- found gtk+-2.0, version 2.24.27
-- checking for module 'gthread-2.0'
-- found gthread-2.0, version 2.44.1
-- checking for module 'librsvg-2.0'
-- found librsvg-2.0, version 2.40.9
-- Configuring done
-- Generating done
-- Build files have been written to: /home/aboettger/tmp/pdfpc-3.1.1
现在让我们通过以下方式启动编译器Makefile
make
然后通过此安装
sudo make install
或者更好的是checkinstall
sudo apt-get install checkinstall
sudo checkinstall
我们已经pdfpc
安装了
% pdfpc
pdfpc v3.1.1
(C) 2012 David Vilar
(C) 2009-2011 Jakob Westhoff
Error: No pdf file given
它与项目页面上的示例一起工作