Corrupt Binary Executable?
:/usr/local/bin# file wkhtmltopdf
wkhtmltopdf: Mach-O executable i386
This file wil开发者_高级运维l not run. I have tried removing and reinstalling with no success. I have looked at the permissions (below) and they seem ok too:
-rwxr-xr-x 1 root root 13817060 Aug 9 13:07 wkhtmltopdf
When I run wkhtmltopdf I get the error below:
wkhtmltopdf
-bash: /usr/local/bin/wkhtmltopdf: cannot execute binary file
That is the executable format for Mac OS X, you need a binary compiled for linux to be able to run it.
Alexander is correct in why the binary you have won't run. It's an OS X binary and you can't run those on Linux systems. You need a Linux binary.
If you are running testing or unstable, just run apt-get install wkhtmltopdf
to install it using the packaging system.
You can also try these prepackaged versions from their website:
- http://code.google.com/p/wkhtmltopdf/downloads/detail?name=wkhtmltoimage-0.10.0_beta4-static-amd64.tar.bz2
- http://code.google.com/p/wkhtmltopdf/downloads/detail?name=wkhtmltoimage-0.10.0_beta4-static-i386.tar.bz2
精彩评论