Da mir letztlich eine CHM-Datei untergekommen ist und mir das Handling unter Linux iVm Wine nicht wirklich zugesagt hat, war ich auf der Suche nach einem Tool, das mir CHM-Dateien in PDF-Dateien konvertiert.

Nicht lange gesucht und schon fündig geworden. Das Tool chm2pdf tut genau dies.
Es ist in Python geschrieben, sodass dies eventuell auf eurem System noch nachinstalliert werden muss.

Um das Tool zu installieren, einfache folgende Schritte ausführen:

1. Abhängigkeiten und chm2pdf  in der Konsole installieren:

sudo apt-get install htmldoc libchm-bin python-chm chm2pdf

2. Fertig!

Um das Tool nun zu verwenden einfach in der Konsole

chm2pdf --book dateiname.chm

ausführen, wobei  dateiname.chm natürlich durch eure CHM-Datei ersetzt werden muss.

Weitere Hilfe gibts noch mit

chm2pdf -h

Die erstellte PDF-Datei findet ihr dann im Verzeichnis, in dem auch die CHM-Datei vorliegt.

of a QWERTY Keyboard

Convert CHM files to PDF in Linux

with 26 comments

I’ve tried a lot of ways to do this thing in Linux (Ubuntu) and finally I found the easiest one to use.

Called simply as ‘chm2pdf‘, this is a small script written in Python and it uses a few dependencies you might have to install first.

Now to install it, simply follow this guide:

1. Install dependencies by running in the Terminal:

sudo apt-get install htmldoc libchm-bin python-chm






2. Download chm2pdf by clicking this.

3. Now extract the downloaded file.

4. Open your Terminal and browse to the folder you extracted and run:

sudo python setup.py install






5. You’re done!