帮助安装了wkhtmltopdf静态二进制 [英] Help installing static binary for wkhtmltopdf
问题描述
我想使用wkhtmltopdf的静态二进制Ubuntu的服务器上10.0.4。其原因是,它显然有一个内置的修改QT,让我在没有X服务器运行wkhtmltopdf。
I am trying to use the static binary of wkhtmltopdf on Ubuntu server 10.0.4. The reason for is that it apparently has a built in modified QT that will allow me to run wkhtmltopdf without an X Server.
结果:
一旦安装(请参阅下面的步骤),当我在终端执行wkhtmltopdf,它不会火起来...只是返回我的提示 - 喜欢它跑了,做什么的,没有错误,但没有输出:
Result: Once installed (see steps below), when I execute wkhtmltopdf in the terminal, it does not fire up... just returns me to the prompt - like it ran and did something, no error but no output:
:在/ usr / bin中$ wkhtmltopdf
:/usr/bin$ wkhtmltopdf
:在/ usr / bin中$
:/usr/bin$
如果我把ARGS相同的行为:
Same behavior if I put args:
:在/ usr / bin中$ wkhtmltopdf http://www.google.com 的test.pdf
:/usr/bin$ wkhtmltopdf http://www.google.com test.pdf
:在/ usr / bin中$
:/usr/bin$
难道我做错了什么---我的理解是静态二进制应该只是火了起来。或许缺少一些依赖?有没有办法得到一些详细的输出?
Am I doing something wrong --- my understanding that the static binary should just fire up. Perhaps missing some dependency? Is there a way to get some verbose output?
这是我所遵循的步骤:
在/ usr / bin中:
In /usr/bin:
1)证实,现有的(非静态)wkhtmltopdf驻留那里,它执行。当我与无参数执行它,我得到的帮助/关于从应用程序的输出。
1) Confirmed that the existing (non-static) wkhtmltopdf resides there and that it executes. When I execute it with no args I get the help/about output from the app.
2)移动现有wkhtmltopdf出目录(重新命名)
2) Moved the existing wkhtmltopdf out of the directory (renamed it)
3)获取静态二进制命令:sudo卷曲-C - -O HTTP:
//wkhtmltopdf.google$c$c.com/files/wkhtmltopdf-0.9.9-static-i386.tar.bz2
3) Get the static binary: sudo curl -C - -O http: //wkhtmltopdf.googlecode.com/files/wkhtmltopdf-0.9.9-static-i386.tar.bz2
4)解压:焦油xvjf wkhtmltopdf-0.9.9-静态i386.tar.bz2
4) Untar: tar xvjf wkhtmltopdf-0.9.9-static-i386.tar.bz2
5)重命名:MV wkhtmltopdf-i386的wkthtmltopdf
5) Rename: mv wkhtmltopdf-i386 wkthtmltopdf
6)获取(显然)需要的软件包:sudo易于得到将OpenSSL安装建立必要的libssl的xorg-dev的
6) Get (apparently) necessary packages: sudo apt-get install openssl build-essential xorg libssl-dev
推荐答案
我有同样的问题。我删除现有的 wkhtmltopdf
,跟着下面的步骤和安装工作。
I was having the same problem. I removed the existing wkhtmltopdf
and followed the steps below and the installation worked.
首先,安装依赖
sudo aptitude install openssl build-essential xorg libssl-dev
对于64位操作系统
for 64-bit OS
wget http://wkhtmltopdf.googlecode.com/files/wkhtmltopdf-0.9.2-static-amd64.tar.bz2
tar xvjf wkhtmltopdf-0.9.2-static-amd64.tar.bz2
chown root:root wkhtmltopdf-amd64
mv wkhtmltopdf-amd64 /usr/bin/wkhtmltopdf
唯一的区别是,我把它放在的/ usr / local / bin目录/ wkhtmltopdf
。
我希望这有助于!
这篇关于帮助安装了wkhtmltopdf静态二进制的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!