math/scilab:
- Fix build after textproc/fop update PR: 201339 Submitted by: truckman
This commit is contained in:
parent
4656d37f01
commit
5f0485b069
Notes:
svn2git
2021-03-31 03:12:20 +00:00
svn path=/head/; revision=392380
1 changed files with 32 additions and 0 deletions
32
math/scilab/files/patch-fop2
Normal file
32
math/scilab/files/patch-fop2
Normal file
|
@ -0,0 +1,32 @@
|
|||
Fix build with fop 2.0
|
||||
|
||||
--- modules/helptools/src/java/org/scilab/modules/helptools/FopConverter.java.orig 2014-04-11 09:51:59 UTC
|
||||
+++ modules/helptools/src/java/org/scilab/modules/helptools/FopConverter.java
|
||||
@@ -43,10 +43,9 @@ public class FopConverter extends Contai
|
||||
String fileName = outputDirectory + "/" + baseName + "." + format.name().toLowerCase();
|
||||
|
||||
try {
|
||||
- FopFactory fopFactory = FopFactory.newInstance();
|
||||
+ FopFactory fopFactory = FopFactory.newInstance(new File(System.getenv("SCI") + "/modules/helptools/etc/fopconf.xml"));
|
||||
fopFactory.addElementMapping(new JLaTeXMathElementMapping());
|
||||
fopFactory.getXMLHandlerRegistry().addXMLHandler(new JLaTeXMathXMLHandler());
|
||||
- fopFactory.setUserConfig(new File(System.getenv("SCI") + "/modules/helptools/etc/fopconf.xml"));
|
||||
|
||||
// Step 3: Construct fop with desired output format
|
||||
OutputStream out = new BufferedOutputStream(new FileOutputStream(fileName));
|
||||
--- modules/scinotes/src/java/org/scilab/modules/scinotes/utils/CodeExporter.java.orig 2014-04-11 09:52:10 UTC
|
||||
+++ modules/scinotes/src/java/org/scilab/modules/scinotes/utils/CodeExporter.java
|
||||
@@ -114,11 +114,11 @@ public class CodeExporter extends FOCode
|
||||
* @param format the page format
|
||||
*/
|
||||
public void convert(String code, int[] lineNumberArray, String fileName, String type, String title, PageFormat format) {
|
||||
- FopFactory fopFactory = FopFactory.newInstance();
|
||||
+ FopFactory fopFactory;
|
||||
OutputStream out = null;
|
||||
|
||||
try {
|
||||
- fopFactory.setUserConfig(new File(ScilabConstants.SCI + "/modules/helptools/etc/fopconf.xml"));
|
||||
+ fopFactory = FopFactory.newInstance(new File(ScilabConstants.SCI + "/modules/helptools/etc/fopconf.xml"));
|
||||
FOUserAgent userAgent = fopFactory.newFOUserAgent();
|
||||
userAgent.setProducer(CREATOR);
|
||||
userAgent.setTitle(title);
|
Loading…
Reference in a new issue