Hi Jeff, FOP is an FO processor, as such it takes FO as input, not XML (even though FO is XML, XML isn't FO). You need to make sure your input is valid FO, then either use the -fo parameter or no parameter since it's the FOPs primary input.
If you were curious the -xml input is used in conjunction with an XSLT (thus the -xsl parameter) to transform said XML file to FO. There is no "default" PDF stylesheet, this mechanism is merely a helper since a lot of users create FO using a transform. So assuming your book.xml is valid FO, the command would look like: $oreilly-handbook$ fop book.xml -pdf book.pdf Hope that helps Mehdi On 25 October 2011 08:37, Jeffrey Walton <[email protected]> wrote: > Hi All, > > I'm working on Ubuntu 10.04 (x64). I installed the FOP package, and > now trying to create a PDF from O'Reilly's DocBook sample at > https://prod.oreilly.com/external/tools/docbook/docs/authoring/docbook_source/. > > $oreilly-handbook$ fop -xml book.xml -pdf book.pdf > > results in an exception: > > Oct 25, 2011 3:34:41 AM org.apache.fop.cli.Main startFOP > SEVERE: Exception > org.apache.fop.apps.FOPException: XSLT file must be specified for the > transform mode > > I believe i need to add `-xsl <stylesheet>`. But I don't know what the > default stylesheet is. > > Would anyone be able to point out the default PDF stylesheet? > > Thanks in advance, > Jeff > > --------------------------------------------------------------------- > To unsubscribe, e-mail: [email protected] > For additional commands, e-mail: [email protected] > > --------------------------------------------------------------------- To unsubscribe, e-mail: [email protected] For additional commands, e-mail: [email protected]
