Sorry if "Task" isn't the right category for this.

I'm posting to help others who may be stumped by the newer version of wkhtmltopdf library.
Nothing wrong with the library or the print module - but the newer beta of the library is compressed with the slightly exotic lzma algorithm. Some folks might find it puzzling to unpack this, so here goes.

(Instrux are for *nix):

First, download the wkhtmltopdf library from
http://code.google.com/p/wkhtmltopdf/downloads/detail?name=wkhtmltopdf-0... or whatever the current version is.
Now, the lzma format used to be well served by lzma Utils, but that's not being supported anymore (http://tukaani.org/lzma/).
lzma Utils has been overtaken by a newer compression project called xz utils (http://tukaani.org/xz/).
There are of course other projects addressing this compression algorithm, but this is the one I'm familiar with.

If you don't have xz on your system, but can build it, go get it: http://tukaani.org/xz/xz-4.999.9beta.tar.gz (or one of the other archive formats available at http://tukaani.org/xz/).
Unpack, cd into the directory, ./configure, make, make install. Worked fine for me.

Once you've done that, or if you had xz in the first place, run
xz -xv wkhtmltopdf-0.10.0_beta5-static-i386.tar.lzma (the -v flag is optional; I like verbose mode for some reason)
which will result in a .tar file wkhtmltopdf-0.10.0_beta5-static-i386.tar

Then just unpack the tarball (tar -x wkhtmltopdf-0.10.0_beta5-static-i386.tar) and you'll have the wkhtmltopdf binary ready to go.

If you're on Windows, use 7-Zip (http://7-zip.org/); Sorry, I'm not skilled in that but good luck.

There's also p7zip for *nix machines here: http://sourceforge.net/projects/p7zip/files/ - some p7zip binaries for various *nix flavors are listed here: http://7-zip.org/download.html
I have no direct experience with p7zip, but 7-zip says it can open lzma.

Hope this helps someone.

Comments

sam moore’s picture

Title: Installing the wkhtmltopdf library - dealing with ) compression » Installing the wkhtmltopdf library - dealing with lzma compression
2ndmile’s picture

Stumped me at first as well. For mac, this one is helpful... http://leifertin.info/app/eZ7z/

jcnventura’s picture

I've used p7zip in my Linux machine, and indeed it can handle lzma.

The joys of multiple compression formats. I was missing this since the 80s..

Anyway: this page has all the details (including supporting software) that you may desire: http://en.wikipedia.org/wiki/Lempel%E2%80%93Ziv%E2%80%93Markov_chain_alg...

João

jcnventura’s picture

Status: Active » Closed (fixed)

No longer applicable, as wkhtmltopdf is distributed as bz2 or zip.