1 diff -Naur misc/build/JLanguageTool-1.7.0/build.properties misc/build/JLanguageTool-1.7.0_patched/build.properties
2 --- misc/build/JLanguageTool-1.7.0/build.properties 2012-06-25 08:22:35.000000000 +0200
3 +++ misc/build/JLanguageTool-1.7.0_patched/build.properties 2012-06-25 09:24:21.253494500 +0200
5 ext.log4j.lib = ${ext.dir}/build/cobertura/log4j-1.2.9.jar
6 ext.jakarta-oro.lib = ${ext.dir}/build/cobertura/jakarta-oro-2.0.8.jar
8 -ext.ooo.juh.lib = ${ext.ooo.dir}/juh.jar
9 -ext.ooo.unoil.lib = ${ext.ooo.dir}/unoil.jar
10 -ext.ooo.ridl.lib = ${ext.ooo.dir}/ridl.jar
11 -ext.ooo.jurt.lib = ${ext.ooo.dir}/jurt.jar
12 +ext.ooo.juh.lib = ${solver.ooo.dir}/juh.jar
13 +ext.ooo.unoil.lib = ${solver.ooo.dir}/unoil.jar
14 +ext.ooo.ridl.lib = ${solver.ooo.dir}/ridl.jar
15 +ext.ooo.jurt.lib = ${solver.ooo.dir}/jurt.jar
17 converter.name = RuleConverter
18 build.meta-inf = ${build.dir}/META-INF
19 diff -Naur misc/build/JLanguageTool-1.7.0/build.xml misc/build/JLanguageTool-1.7.0_patched/build.xml
20 --- misc/build/JLanguageTool-1.7.0/build.xml 2012-06-25 08:22:35.000000000 +0200
21 +++ misc/build/JLanguageTool-1.7.0_patched/build.xml 2012-06-25 09:27:39.077442000 +0200
23 <pathelement location="${ext.CJFtransform.lib}" />
24 <pathelement location="${ext.commons-validator.lib}" />
26 - <pathelement location="${ext.ooo.juh.lib}" />
27 + <pathelement location="${ext.junit.lib}"/>
29 + <pathelement location="${ext.ooo.juh.lib}" />
30 <pathelement location="${ext.ooo.unoil.lib}" />
31 <pathelement location="${ext.ooo.ridl.lib}" />
32 <pathelement location="${ext.ooo.jurt.lib}" />
34 <!-- ================================================================== -->
36 <target name="dist" depends="ooo-internal" description="Builds one ZIP for both OpenOffice.org and stand-alone use">
37 -<zip compress="yes" destfile="${dist.dir}/LanguageTool-${version}.oxt" basedir="${dist.dir}" includes="**" excludes="deploy.sh,undeploy.sh,turn.sh,printlocales.jar" />
38 +<zip compress="yes" destfile="${dist.dir}/LanguageTool.oxt" basedir="${dist.dir}" includes="**" excludes="deploy.sh,undeploy.sh,turn.sh,printlocales.jar" />
41 <target name="fast" depends="ooo-internal" description="like dist, but without ZIP compression (for development only)">
42 -<zip compress="no" destfile="${dist.dir}/LanguageTool-${version}.oxt" basedir="${dist.dir}" includes="**" excludes="deploy.sh,undeploy.sh,turn.sh,printlocales.jar" />
43 +<zip compress="no" destfile="${dist.dir}/LanguageTool.oxt" basedir="${dist.dir}" includes="**" excludes="deploy.sh,undeploy.sh,turn.sh,printlocales.jar" />
46 <target name="common" depends="clean,init,build,ooo-build">
48 <copy file="${resource.dir}/ast/asturian.dict" todir="${dist.dir}/resource/ast" />
49 <copy file="${resource.dir}/ast/asturian.info" todir="${dist.dir}/resource/ast" />
51 - <copy file="${resource.dir}/xx/dummy.dict" tofile="${dist.dir}/resource/cs/czech.dict" />
52 <copy todir="${dist.dir}/rules">
53 <fileset dir="src/rules" excludes="CVS" />
57 <filter filtersFile="ooolocales.properties" />
58 <copy filtering="true" encoding="${encoding}" todir="${dist.dir}/">
59 - <fileset dir="openoffice/" includes="description.xml,*.xcu,Options.xdl,META-INF/**" />
60 + <fileset dir="openoffice/" includes="components.rdb,description.xml,*.xcu,Options.xdl,META-INF/**" />
62 <copy todir="${dist.dir}/">
63 <fileset dir="openoffice/" includes="images/**,help/**" />
64 diff -Naur misc/build/JLanguageTool-1.7.0/openoffice/components.rdb misc/build/JLanguageTool-1.7.0_patched/openoffice/components.rdb
65 --- misc/build/JLanguageTool-1.7.0/openoffice/components.rdb 1970-01-01 01:00:00.000000000 +0100
66 +++ misc/build/JLanguageTool-1.7.0_patched/openoffice/components.rdb 2012-06-25 10:26:23.183633100 +0200
68 +<?xml version="1.0"?>
69 +<components xmlns="http://openoffice.org/2010/uno-components">
70 + <component loader="com.sun.star.loader.Java2" uri="./LanguageTool.uno.jar">
71 + <implementation name="org.languagetool.openoffice.Main">
72 + <service name="com.sun.star.linguistic2.Proofreader"/>
73 + <service name="org.languagetool.openoffice.Main"/>
77 diff -Naur misc/build/JLanguageTool-1.7.0/openoffice/META-INF/manifest.xml misc/build/JLanguageTool-1.7.0_patched/openoffice/META-INF/manifest.xml
78 --- misc/build/JLanguageTool-1.7.0/openoffice/META-INF/manifest.xml 2012-06-25 08:22:34.000000000 +0200
79 +++ misc/build/JLanguageTool-1.7.0_patched/openoffice/META-INF/manifest.xml 2012-06-25 09:39:56.751738000 +0200
82 <manifest:file-entry manifest:full-path="Addons.xcu"
83 manifest:media-type="application/vnd.sun.star.configuration-data" />
84 - <manifest:file-entry manifest:full-path="LanguageTool.uno.jar"
85 - manifest:media-type="application/vnd.sun.star.uno-component;type=Java" />
86 + <manifest:file-entry manifest:full-path="components.rdb"
87 + manifest:media-type="application/vnd.sun.star.uno-components" />
89 manifest:media-type="application/vnd.sun.star.configuration-data"
90 manifest:full-path="Linguistic.xcu" />
91 diff -Naur misc/build/JLanguageTool-1.7.0/openoffice/description.xml misc/build/JLanguageTool-1.7.0_patched/openoffice/description.xml
92 --- misc/build/JLanguageTool-1.7.0/openoffice/description.xml 2012-06-25 08:22:35.000000000 +0200
93 +++ misc/build/JLanguageTool-1.7.0_patched/openoffice/description.xml 2012-06-25 10:29:48.520591800 +0200
95 <name lang="zh">LanguageTool. 开源的语言检查工具</name>
96 <name lang="br">LanguageTool. Reizher reizhskrivadurel frank.</name>
98 - <version value="@version@" />
99 + <version value="1.7.1" />
101 <src xlink:href="CHANGES.txt" lang="en" />
103 diff -Naur misc/build/JLanguageTool-1.7.0/src/java/org/languagetool/gui/Configuration.java misc/build/JLanguageTool-1.7.0_patched/src/java/org/languagetool/gui/Configuration.java
104 --- misc/build/JLanguageTool-1.7.0/src/java/org/languagetool/gui/Configuration.java 2012-06-25 08:21:31.000000000 +0200
105 +++ misc/build/JLanguageTool-1.7.0_patched/src/java/org/languagetool/gui/Configuration.java 2012-06-25 09:31:40.737466400 +0200
107 import java.io.FileNotFoundException;
108 import java.io.FileOutputStream;
109 import java.io.IOException;
110 +import java.lang.ClassLoader;
113 import org.languagetool.Language;
116 final String motherTongueStr = (String) props.get(MOTHER_TONGUE_CONFIG_KEY);
117 if (motherTongueStr != null) {
118 - motherTongue = Language.getLanguageForShortName(motherTongueStr);
119 + // FIXME: hack to disable the functionality for JRE 1.5
120 + // javax.xml.bind.JAXBException is part of JRE 1.6
121 + boolean isJRE15 = false;
123 + ClassLoader cl = ClassLoader.getSystemClassLoader();
124 + cl.loadClass("javax.xml.bind.JAXBException");
125 + } catch (ClassNotFoundException e) {
129 + motherTongue = Language.getLanguageForShortName(motherTongueStr);
133 final String autoDetectStr = (String) props.get(AUTO_DETECT_CONFIG_KEY);
134 diff -Naur misc/build/JLanguageTool-1.7.0/src/java/org/languagetool/openoffice/Main.java misc/build/JLanguageTool-1.7.0_patched/src/java/org/languagetool/openoffice/Main.java
135 --- misc/build/JLanguageTool-1.7.0/src/java/org/languagetool/openoffice/Main.java 2012-06-25 08:21:28.000000000 +0200
136 +++ misc/build/JLanguageTool-1.7.0_patched/src/java/org/languagetool/openoffice/Main.java 2012-06-25 09:36:03.778528700 +0200
138 * @author Marcin Miłkowski
141 +import java.lang.ClassLoader;
142 import java.util.ArrayList;
143 import java.util.Arrays;
144 import java.util.Comparator;
148 public final Locale[] getLocales() {
149 + // FIXME: hack to disable the functionality for JRE 1.5
150 + // javax.xml.bind.JAXBException is part of JRE 1.6
152 + ClassLoader cl = ClassLoader.getSystemClassLoader();
153 + cl.loadClass("javax.xml.bind.JAXBException");
154 + } catch (ClassNotFoundException e) {
155 + return new Locale[0];
159 for (final Language element : Language.LANGUAGES) {