DIGIT-ARC read-only archive · snapshot: July 23, 2026

Linux-CHM2PDF convertor now available!

10 posts · originally from https://geek.digit.in/community/threads/linux-chm2pdf-convertor-now-available.77165/

praka123
praka123 Original post #1
Jan 2, 2008 at 4:37 AM
A simple Python script that converts CHM files into PDF files.
Requires:
  • chmlib
  • pychm
  • htmldoc
(Old versions require pdftk too)
All of these should be in your favourite distro repository. Currently it works on Linux (and probably most Unixen).
If you have bugs/problems/issues/questions, as a general advice use the Google group link at your right to post them, not my blog or personal emails (I answer the latter, but I want bug reports etc. to be public). If after the discussion we're sure we're dealing with a true bug, post it to the Issues.
Again: Bugs, problems etc. should be sent to the Google group. NOT as comments to the wiki pages, blog comments or anything else. Thanks!

*code.google.com/p/chm2pdf/

HowToInstall Installation instructions

Dependencies

You need those packages installed and working:
Gentoo:
  • chmlib
  • pychm
  • htmldoc
Ubuntu/Kubuntu/Debian:
  • libchm
  • libchm-bin
  • libchm-dev
  • python-chm
  • html-doc
  • htmldoc-common
Analogous packages should exist on most other Linux/BSD distributions. Users have reported success on Mac OS X, however currently this is unsupported.
On Fedora, it has been reported that the chmlib package is missing some essential files. You need to look for chmlib-bin or to compile chmlib by hand.
If you install chmlib from source, do not forget to use the --enable-examples on chmLib, otherwise this script will throw a bunch of exceptions, and will fail.
If you use Mac OS X, and you use darwin ports (port on the cmdline), be aware that the chmlib will NOT be built with this option. You can, however, separately download chmlib and build it yourself with this option, install it, and then re-run the script.
Install
  • Download the archive
  • Unzip it (tar -xzvf chm2pdf-x.x.x.tar.gz)
  • Enter the directory
  • Become root
  • Type "python setup.py install"
  • Enjoy
*code.google.com/p/chm2pdf/wiki/HowToInstall




Hope it helps!
thanks to original source:
*www.karakas-online.de/forum/viewtopic.php?t=10275
F
FilledVoid #2
Jan 2, 2008 at 11:38 AM
I think that QwertyManiac has something similar on his blog posted.
QwertyManiac
Jan 2, 2008 at 4:36 PM
Yeah it was the same one. Doesn't work out always though, some CHM with special contents fail to translate :)
ray|raven
Jan 2, 2008 at 5:34 PM
There is xchm or smthin to read chm files right?
Why convert them into pdf's?

Regards,
ray
praka123
Jan 2, 2008 at 5:41 PM
reading programs are available like GnoChm or Xchm,but..editing ones were *not* there!
ray|raven
Jan 2, 2008 at 5:43 PM
Even if u convert it into pdf, editing pdf's also isnt very good in linux, AFAIK.

Regards,
ray
praka123
Jan 2, 2008 at 5:44 PM
pdf editing is OK for my use in Linux!also there is some qt based pdf editor also available!
QwertyManiac
Jan 2, 2008 at 5:47 PM
Even if u convert it into pdf, editing pdf's also isnt very good in linux, AFAIK.

Regards,
ray
PDFs are more widely supported across several devices (My phone, for example) and I also prefer a common format for all my documents so I convert them out. :)
praka123
Jan 3, 2008 at 1:07 AM
CHM files are used by...u know..by knowledge hungry..who cannot afford or access those books..mostly...OK stops here ;)
phreak0ut
phreak0ut #10
Jan 8, 2008 at 9:39 AM
Thanks for the post. Time to install ;)