View Single Post
Old 06-26-2014, 03:21 PM   #2
baf
Evangelist
baf ought to be getting tired of karma fortunes by now.baf ought to be getting tired of karma fortunes by now.baf ought to be getting tired of karma fortunes by now.baf ought to be getting tired of karma fortunes by now.baf ought to be getting tired of karma fortunes by now.baf ought to be getting tired of karma fortunes by now.baf ought to be getting tired of karma fortunes by now.baf ought to be getting tired of karma fortunes by now.baf ought to be getting tired of karma fortunes by now.baf ought to be getting tired of karma fortunes by now.baf ought to be getting tired of karma fortunes by now.
 
Posts: 404
Karma: 2200000
Join Date: May 2012
Device: kt
I want to report that I moved my project forward.
As I want to understand how mobi format works I focused on recreating html-like markup from mobi file.
I implemented reconstruction of internal references to html targets.
Apart from reading and parsing mobi documents, libmobi should now be able to produce a set of files that may be used as an input to kindlegen.

I am sure there are still bugs and need for improvements. I am short of time and mobi format samples, but I will be working on it.

For those who would like to test it, but don't know how to compile programs, I attach statically built binaries for several architectures. The program – mobitool is very simple. Its main function is turning mobi document into markup files. Precompiled binaries may or may not work for your particular system. The best and recommended way to test the library is to compile it from sources (from github). Mobitool is build together with the library. The process is quite straightforward.

UPDATE: I removed outdated binaries. Please download current releases from project's github page.


Code:
usage: mobitool [-diemrsuvx7] [-o dir] [-p pid] filename
    without arguments prints document metadata and exits
    -d      dump rawml text record
    -e      create EPUB file (with -s will dump EPUB source)
    -i      print detailed metadata
    -m      print records metadata
    -o dir  save output to dir folder
    -p pid  set pid for decryption
    -r      dump raw records
    -s      dump recreated source files
    -u      show rusage
    -v      show version and exit
    -x      extract conversion source and log (if present)
    -7      parse KF7 part of hybrid file (by default KF8 part is parsed)

Last edited by baf; 03-22-2016 at 05:20 PM. Reason: update binaries
baf is offline   Reply With Quote