Comments (8)
Could this be an OS related issue? I have found the windows native zip function to be hit and miss, but this is only anecdotal, I can't provide any hard evidence.
I can try and give this a go on Debian this weekend, if I have time.
On October 31, 2014 11:11:01 AM PDT, Eliot Kimber [email protected] wrote:
Getting this failure:
The mimetype file has an extension of length 20. No filename extensions
are permitted for the mimetype file.From epubcheck for the EPUB Zip file generated by the Ant task. Have
asked Radu and Jean Kaplansky for guidance. Using Oxygen's archive
browser to open and save the EPUB file resolves the issue, so it must
be something with how Ant's Zip implementation works.Would like to avoid having custom Java code just to make the Zip file.
Reply to this email directly or view it on GitHub:
#21
from org.dita4publishers.epub.
I was getting a different error message: Mimetype entry must not have an extra field in its ZIP header
And I fixed that by adding this to the zip task for the mimetype:
zip64Mode="never"
Not sure if that will solve your problem or not, Eliot; I don't run into your problem when executing the ant code against my ePub source files (whether 2 or 3). The above error happens with Ant 1.9.3 on OS X and epubcheck 3.0.1.
from org.dita4publishers.epub.
Some time ago one of my coleagues added an issue which explains why zip64Mode should be added to the ANT task on the old SourceForge DITA For Publishers List:
https://sourceforge.net/p/dita4publishers/bugs/106/
So you must add this flag if you are using ANT 1.9 or newer to publish.
from org.dita4publishers.epub.
I'm using Ant 1.8.5, so zip64Mode="never" isn't supported.
Comparing the Zip produced by Ant and by Oxygen at the byte level, the difference is an extended field in the local file header for the mimetype file, consisting of 20 null bytes. So Ant is adding that extended field. Without having researched it, I'm assuming that Ant 1.9 fixes this issue with the zip64Mode option.
from org.dita4publishers.epub.
I upgraded to Ant 1.9.4 and confirmed that with @zip64Mode="never" specified that the EPUB file passes epubcheck.
from org.dita4publishers.epub.
ANT 1.9.0 was released in March 7, 2013, so probably it's safe to assume most users use ANT 1.9.0 or newer, so setting @zip64Mode="never" should work for most users.
from org.dita4publishers.epub.
Unfortunately, it appears that the OT 1.8.5 comes with Ant 1.8.4 out of the box, so I can't assume it's installed.
I can make a check in the Ant script for the Ant version and issue a message when the version is not 1.9.1 or greater.
from org.dita4publishers.epub.
Fixed by #26
from org.dita4publishers.epub.
Related Issues (20)
- Provide runtime options for generating fixed-layout pages
- When html2.generate.index index generated but not reflect in nav or toc
- Generate CSS @font-face declarations from the font manifest HOT 1
- topic/publisher not handled properly for OPF output HOT 1
- [BUG] coverimage for Apple iBooks compliance duplicated in manifest HOT 6
- [BUG] incorrect timestamps applied to metadata in content.opf HOT 4
- graphics not copied (OT 2.3.1) HOT 3
- Provide runtime option for specifying a single JavaScript file HOT 1
- Generalize font manifest facility to handle files of any time, JavaScript
- HTML files for for topicheads have .html extension, should have .xhtml HOT 1
- Invalid attribute values in EPUB HOT 2
- No need to include generated TOC file
- Doctypes in generated files.
- Figure description results in invalid HTML5 markup
- Unwanted @xml:base attribute in MathML elements in generated XHTML HOT 1
- SVG documents must not have DOCTYPE declarations HOT 1
- Font embedding with iBooks
- Errors reported with latest Epub Checker HOT 1
- Update for OT 3.6+ HOT 2
- Errors publishing a DITA Map to EPUB with latest 1.0.0RC28 release HOT 3
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from org.dita4publishers.epub.