You are not logged in.

#1 2015-09-02 15:33:46

Dornith
Member
Registered: 2013-02-19
Posts: 78

Error compiling wkhtmltopdf

I need to use wkhtmltopdf on a web site for work but we ran into an issue since we couldn't install any software to the root directory on the server. We decided to try and compile the source ourselves and keep everything in the home folder.

I ran the commands and got this error:

$ git clone --recursive https://github.com/wkhtmltopdf/wkhtmltopdf.git
$ cd wkhtmltopdf
$ scripts/build.py posix-local -clean
...
g++ -Wl,-O1 -o ../../bin/wkhtmltoimage outputter.o manoutputter.o htmloutputter.o textoutputter.o arghandler.o commondocparts.o commandlineparserbase.o commonarguments.o progressfeedback.o loadsettings.o multipageloader.o tempfile.o converter.o websettings.o reflect.o utilities.o pdfsettings.o pdfconverter.o outline.o tocstylesheet.o imagesettings.o imageconverter.o pdf_c_bindings.o image_c_bindings.o wkhtmltoimage.o imagearguments.o imagecommandlineparser.o imagedocparts.o moc_progressfeedback.o moc_multipageloader_p.o moc_converter_p.o moc_pdfconverter_p.o moc_imageconverter_p.o moc_pdf_c_bindings_p.o moc_image_c_bindings_p.o moc_converter.o moc_multipageloader.o moc_utilities.o moc_pdfconverter.o moc_imageconverter.o qrc_wkhtmltopdf.o -L/home/tom/tmp/wkhtmltopdf/static-build/posix-local/qt/lib -L/home/tom/tmp/wkhtmltopdf/static-build/posix-local/qt/plugins/codecs -lqcncodecs -L/home/tom/tmp/wkhtmltopdf/static-build/posix-local/qt/lib -lqjpcodecs -lqkrcodecs -lqtwcodecs -lQtWebKit -L/usr/X11R6/lib -lgio-2.0 -lgstapp-0.10 -lgstinterfaces-0.10 -lgstpbutils-0.10 -lgstvideo-0.10 -lgstbase-0.10 -lgstreamer-0.10 -lgobject-2.0 -lgmodule-2.0 -lgthread-2.0 -pthread -lglib-2.0 -lxml2 -lQtSvg -lQtXmlPatterns -lQtGui -ljpeg -lpng -lXrender -lfontconfig -lfreetype -lXext -lX11 -lQtNetwork -lQtCore -lz -lm -ldl -lrt -lpthread 
make[1]: Leaving directory '/home/tom/tmp/wkhtmltopdf/static-build/posix-local/app/src/image'
cp: target ‘../wkhtmltox-0.12.3-dev-b29d23fc/bin’ is not a directory
cp bin/wkhtmlto* ../wkhtmltox-0.12.3-dev-b'29d23fc'/bin
command failed: exit code 256

I looked around on the internet and couldn't find anything.

Last edited by Dornith (2015-09-02 16:20:31)

Offline

#2 2015-09-02 15:36:29

Awebb
Member
Registered: 2010-05-06
Posts: 6,312

Re: Error compiling wkhtmltopdf

What is the output of "uname -a"?

EDIT: By the way... http://tldp.org/LDP/abs/html/exitcodes.html

Last edited by Awebb (2015-09-02 15:37:33)

Offline

#3 2015-09-02 16:19:48

Dornith
Member
Registered: 2013-02-19
Posts: 78

Re: Error compiling wkhtmltopdf

$ uname -a
Linux imperator 4.1.4-1-ARCH #1 SMP PREEMPT Mon Aug 3 21:30:37 UTC 2015 x86_64 GNU/Linux

Also, I got it work on my own.  I remembered from my time with Slackware that they build everything from source.  I found their build script (http://slackbuilds.org/slackbuilds/14.1 … SlackBuild) and got this set of instructions:

$ git clone --recursive [url]https://github.com/wkhtmltopdf/wkhtmltopdf.git[/url] && mkdir ~/tmp
$ cd wkhtmltopdf
$ qmake
$ make
$ make install INSTALL_ROOT=~/tmp

In hindsight I probably should have figured that out myself but hindsight's 20/20.

Offline

Board footer

Powered by FluxBB