View Single Post
Old 09-05-2011, 04:01 AM   #134
pdurrant
The Grand Mouse 高貴的老鼠
pdurrant ought to be getting tired of karma fortunes by now.pdurrant ought to be getting tired of karma fortunes by now.pdurrant ought to be getting tired of karma fortunes by now.pdurrant ought to be getting tired of karma fortunes by now.pdurrant ought to be getting tired of karma fortunes by now.pdurrant ought to be getting tired of karma fortunes by now.pdurrant ought to be getting tired of karma fortunes by now.pdurrant ought to be getting tired of karma fortunes by now.pdurrant ought to be getting tired of karma fortunes by now.pdurrant ought to be getting tired of karma fortunes by now.pdurrant ought to be getting tired of karma fortunes by now.
 
pdurrant's Avatar
 
Posts: 71,508
Karma: 306214458
Join Date: Jul 2007
Location: Norfolk, England
Device: Kindle Voyage
Quote:
Originally Posted by avid-e-reader View Post
So mobiunpack actually creates this kindlegensrc.zip file somewhere along the line. I just found a (slightly tweaked) version of my .ncx file in there, in the "misc" directory. The tweaks are a reflection of the directory structure.

So it looks like the changes necessary would be threefold:
1) extract the .ncx file out of the kindlegensrc.zip and place it is a (newly created) misc directory, alongside the Images directory
2) reference the .ncx file in the <manifest> tag of the .opf file.
3) add a toc="toc" attribute to the <spine> tag of the .opf file.

I haven't looked at the source for mobiunpack, to know how hard or easy this would be, nor do I know what sort of source control is being used, or where it is located.
The ncx in the kindlegensrc isn't the information in the Mobipocket file. The source files are just stored at the end of the file by kindlegen for mysterious purposes. They can be stripped from the Kindle ebook without losing the ncx navigation info in the file.

Perhaps MobiUnpack should be tweaked to also export any unknown binary data in the original file. Hmm...
pdurrant is offline   Reply With Quote