diff --git a/java-pentaho-libxml-1.1.3-build.patch b/java-pentaho-libxml-1.1.3-build.patch
new file mode 100644
index 0000000..11a69cf
--- /dev/null
+++ b/java-pentaho-libxml-1.1.3-build.patch
@@ -0,0 +1,17 @@
+--- pentaho-libxml-1.1.3/build.properties 2009-11-17 15:20:48.000000000 +0000
++++ pentaho-libxml-1.1.3/build.properties 2009-11-17 15:20:57.000000000 +0000
+@@ -1,4 +1,4 @@
+-project.revision=TRUNK-SNAPSHOT
++project.revision=1.1.3
+ ivy.artifact.group=pentaho-library
+ ivy.artifact.id=libxml
+ impl.title=LibXml
+@@ -6,4 +6,6 @@
+ src.dir=${basedir}/source
+ dependency.libbase.revision=1.1.3
+ dependency.libloader.revision=1.1.3
+-testsrc.dir=${basedir}/test
+\ No newline at end of file
++testsrc.dir=${basedir}/test
++antcontrib.available=true
++build.cache.dir=lib
diff --git a/java-pentaho-libxml-1.1.3-java11.patch b/java-pentaho-libxml-1.1.3-java11.patch
new file mode 100644
index 0000000..e458923
--- /dev/null
+++ b/java-pentaho-libxml-1.1.3-java11.patch
@@ -0,0 +1,13 @@
+--- pentaho-libxml-1.1.3/common_build.xml 2020-05-05 20:04:44.314203763 +0100
++++ pentaho-libxml-1.1.3/common_build.xml 2020-05-05 20:04:51.959264419 +0100
+@@ -136,8 +136,8 @@
+
+-
+-
++
++
+
+
+
+-
+
+@@ -326,68 +323,6 @@
+
+
+
+-
+-
+-
+-
+-
+-
+-
+-
+-
+-
+-
+-
+-
+-
+-
+-
+-
+-
+-
+-
+-
+-
+-
+-
+-
+-
+-
+-
+-
+-
+-
+-
+-
+-
+-
+-
+-
+-
+-
+-
+-
+-
+-
+-
+-
+-
+-
+
++ depends="svnant.download-check">
+
+
+
+@@ -492,57 +427,12 @@
+
+
+
+-
+-
+-
+-
+-
+-
+-
+-
+-
+-
+-
+-
+-
+-
+-
+-
+-
+-
+-
+-
+-
+-
+-
+-
+-
+-
+-
+-
+-
+-
+-
+-
+-
+-
+-
+
++ depends="ivy.download-check">
+
+
+
+@@ -602,7 +492,7 @@
+ Verifies that there are no SNAPSHOT dependencies defined in the ivy xml.
+ If there are SNAPSHOTS, fail the release build.
+ ====================================================================-->
+-
++
+
+
+
+@@ -769,7 +659,7 @@
+ Publishes the jar file for this project to a Maven2 repository.
+ ====================================================================-->
+
++ depends="create-pom,ivy.deliver">
+
+
+
+@@ -1078,30 +968,12 @@
+
+-
+-
+-
+-
+-
+-
+-
+-
+-
+-
+-
+-
+-
+-
+-
+-
+-
+-
+-
+-
++
++
++
++
+
+
+
+@@ -1151,7 +1023,7 @@
+
+ Creates a jar file from the bin directory
+ ====================================================================-->
+-
++
+
+
+
+@@ -1164,7 +1036,7 @@
+ Creates a new manifest file if one is not specified, or updates
+ an existing manifest file if one is specified.
+ ====================================================================-->
+-
++
+
+
+
+@@ -1648,4 +1520,4 @@
+
+
+
+-
+\ No newline at end of file
++
diff --git a/java-pentaho-libxml-1.1.3-remove-commons-logging.patch b/java-pentaho-libxml-1.1.3-remove-commons-logging.patch
new file mode 100644
index 0000000..ac057a9
--- /dev/null
+++ b/java-pentaho-libxml-1.1.3-remove-commons-logging.patch
@@ -0,0 +1,269 @@
+diff -ru pentaho-libxml-1.1.3.orig/source/org/pentaho/reporting/libraries/xmlns/parser/AbstractXmlReadHandler.java pentaho-libxml-1.1.3/source/org/pentaho/reporting/libraries/xmlns/parser/AbstractXmlReadHandler.java
+--- pentaho-libxml-1.1.3.orig/source/org/pentaho/reporting/libraries/xmlns/parser/AbstractXmlReadHandler.java 2021-04-07 11:34:22.313653786 +0100
++++ pentaho-libxml-1.1.3/source/org/pentaho/reporting/libraries/xmlns/parser/AbstractXmlReadHandler.java 2021-04-07 11:48:16.381234640 +0100
+@@ -20,8 +20,8 @@
+ import java.util.HashMap;
+ import java.util.Map;
+
+-import org.apache.commons.logging.Log;
+-import org.apache.commons.logging.LogFactory;
++import java.util.logging.Level;
++import java.util.logging.Logger;
+ import org.pentaho.reporting.libraries.resourceloader.DependencyCollector;
+ import org.pentaho.reporting.libraries.resourceloader.FactoryParameterKey;
+ import org.pentaho.reporting.libraries.resourceloader.Resource;
+@@ -40,7 +40,7 @@
+ */
+ public abstract class AbstractXmlReadHandler implements XmlReadHandler
+ {
+- private static final Log logger = LogFactory.getLog(AbstractXmlReadHandler.class);
++ private static final Logger logger = Logger.getLogger(AbstractXmlReadHandler.class.getName());
+
+ /**
+ * The root handler.
+@@ -120,8 +120,8 @@
+ final XmlReadHandler childHandler = getHandlerForChild(uri, tagName, attrs);
+ if (childHandler == null)
+ {
+- logger.warn("Unknown tag <" + uri + ':' + tagName + ">: Start to ignore this element and all of its childs. " + getLocatorString());
+- logger.debug(this.getClass());
++ logger.warning("Unknown tag <" + uri + ':' + tagName + ">: Start to ignore this element and all of its childs. " + getLocatorString());
++ logger.config(this.getClass().getName());
+ final IgnoreAnyChildReadHandler ignoreAnyChildReadHandler =
+ new IgnoreAnyChildReadHandler();
+ ignoreAnyChildReadHandler.init(getRootHandler(), uri, tagName);
+diff -ru pentaho-libxml-1.1.3.orig/source/org/pentaho/reporting/libraries/xmlns/parser/AbstractXmlResourceFactory.java pentaho-libxml-1.1.3/source/org/pentaho/reporting/libraries/xmlns/parser/AbstractXmlResourceFactory.java
+--- pentaho-libxml-1.1.3.orig/source/org/pentaho/reporting/libraries/xmlns/parser/AbstractXmlResourceFactory.java 2021-04-07 11:34:22.313653786 +0100
++++ pentaho-libxml-1.1.3/source/org/pentaho/reporting/libraries/xmlns/parser/AbstractXmlResourceFactory.java 2021-04-07 11:44:15.729203631 +0100
+@@ -26,8 +26,7 @@
+ import javax.xml.parsers.SAXParser;
+ import javax.xml.parsers.SAXParserFactory;
+
+-import org.apache.commons.logging.Log;
+-import org.apache.commons.logging.LogFactory;
++import java.util.logging.Logger;
+ import org.pentaho.reporting.libraries.resourceloader.CompoundResource;
+ import org.pentaho.reporting.libraries.resourceloader.FactoryParameterKey;
+ import org.pentaho.reporting.libraries.resourceloader.Resource;
+@@ -56,7 +55,7 @@
+ */
+ public abstract class AbstractXmlResourceFactory implements ResourceFactory
+ {
+- private static final Log logger = LogFactory.getLog(AbstractXmlResourceFactory.class);
++ private static final Logger logger = Logger.getLogger(AbstractXmlResourceFactory.class.getName());
+
+ /**
+ * A key for the content base.
+@@ -115,7 +114,7 @@
+ }
+ catch (SAXException se)
+ {
+- logger.debug("Comments are not supported by this SAX implementation.");
++ logger.config("Comments are not supported by this SAX implementation.");
+ }
+
+ try
+@@ -133,7 +132,7 @@
+ }
+ catch (SAXException e)
+ {
+- logger.warn("No Namespace features will be available. (Yes, this is serious)");
++ logger.warning("No Namespace features will be available. (Yes, this is serious)");
+ }
+ }
+
+diff -ru pentaho-libxml-1.1.3.orig/source/org/pentaho/reporting/libraries/xmlns/parser/DomTreeResourceFactory.java pentaho-libxml-1.1.3/source/org/pentaho/reporting/libraries/xmlns/parser/DomTreeResourceFactory.java
+--- pentaho-libxml-1.1.3.orig/source/org/pentaho/reporting/libraries/xmlns/parser/DomTreeResourceFactory.java 2021-04-07 11:34:22.314653798 +0100
++++ pentaho-libxml-1.1.3/source/org/pentaho/reporting/libraries/xmlns/parser/DomTreeResourceFactory.java 2021-04-07 11:43:15.934442890 +0100
+@@ -22,8 +22,7 @@
+ import javax.xml.parsers.DocumentBuilderFactory;
+ import javax.xml.parsers.ParserConfigurationException;
+
+-import org.apache.commons.logging.Log;
+-import org.apache.commons.logging.LogFactory;
++import java.util.logging.Logger;
+ import org.pentaho.reporting.libraries.resourceloader.Resource;
+ import org.pentaho.reporting.libraries.resourceloader.ResourceCreationException;
+ import org.pentaho.reporting.libraries.resourceloader.ResourceData;
+@@ -61,7 +60,7 @@
+ }
+ }
+
+- private static final Log logger = LogFactory.getLog(DomTreeResourceFactory.class);
++ private static final Logger logger = Logger.getLogger(DomTreeResourceFactory.class.getName());
+
+ /**
+ * Creates a resource by interpreting the data given in the resource-data object. If additional datastreams need to
+diff -ru pentaho-libxml-1.1.3.orig/source/org/pentaho/reporting/libraries/xmlns/parser/LoggingErrorHandler.java pentaho-libxml-1.1.3/source/org/pentaho/reporting/libraries/xmlns/parser/LoggingErrorHandler.java
+--- pentaho-libxml-1.1.3.orig/source/org/pentaho/reporting/libraries/xmlns/parser/LoggingErrorHandler.java 2021-04-07 11:34:22.313653786 +0100
++++ pentaho-libxml-1.1.3/source/org/pentaho/reporting/libraries/xmlns/parser/LoggingErrorHandler.java 2021-04-07 11:49:49.117390246 +0100
+@@ -17,8 +17,8 @@
+
+ package org.pentaho.reporting.libraries.xmlns.parser;
+
+-import org.apache.commons.logging.Log;
+-import org.apache.commons.logging.LogFactory;
++import java.util.logging.Level;
++import java.util.logging.Logger;
+ import org.xml.sax.ErrorHandler;
+ import org.xml.sax.SAXException;
+ import org.xml.sax.SAXParseException;
+@@ -30,9 +30,9 @@
+ */
+ public class LoggingErrorHandler implements ErrorHandler
+ {
+- private static final Log defaultLogContext = LogFactory.getLog(LoggingErrorHandler.class);
++ private static final Logger defaultLogContext = Logger.getLogger(LoggingErrorHandler.class.getName());
+ /** @noinspection NonConstantLogger*/
+- private Log logContext;
++ private Logger logContext;
+
+ /**
+ * Default-Constructor. Logs to a logger configured with this class name as category.
+@@ -47,7 +47,7 @@
+ *
+ * @param logContext the logger that should receive the messages.
+ */
+- public LoggingErrorHandler(final Log logContext)
++ public LoggingErrorHandler(final Logger logContext)
+ {
+ if (logContext == null)
+ {
+@@ -78,7 +78,7 @@
+ */
+ public void warning(final SAXParseException exception) throws SAXException
+ {
+- if (logContext.isDebugEnabled())
++ if (logContext.isLoggable(Level.CONFIG))
+ {
+ if (exception.getMessage().startsWith("URI was not reported to parser for entity"))
+ {
+@@ -86,7 +86,7 @@
+ // the GNU thing complain about it ..
+ return;
+ }
+- logContext.debug("Parser-Warning", exception);
++ logContext.severe("Parser-Warning: " + exception.getMessage());
+ }
+ }
+
+@@ -115,15 +115,15 @@
+ */
+ public void error(final SAXParseException exception) throws SAXException
+ {
+- if (logContext.isWarnEnabled())
++ if (logContext.isLoggable(Level.WARNING))
+ {
+- if (logContext.isDebugEnabled())
++ if (logContext.isLoggable(Level.CONFIG))
+ {
+- logContext.warn("Recoverable Parser-Error", exception);
++ logContext.warning("Recoverable Parser-Error:" + exception.getMessage());
+ }
+ else
+ {
+- logContext.warn("Recoverable Parser-Error:" + exception.getMessage());
++ logContext.warning("Recoverable Parser-Error:" + exception.getMessage());
+ }
+ }
+ }
+@@ -156,15 +156,15 @@
+ */
+ public void fatalError(final SAXParseException exception) throws SAXException
+ {
+- if (logContext.isErrorEnabled())
++ if (logContext.isLoggable(Level.SEVERE))
+ {
+- if (logContext.isDebugEnabled())
++ if (logContext.isLoggable(Level.CONFIG))
+ {
+- logContext.error("Fatal Parser-Error", exception);
++ logContext.severe("Fatal Parser-Error:" + exception.getMessage());
+ }
+ else
+ {
+- logContext.error("Fatal Parser-Error:" + exception.getMessage());
++ logContext.severe("Fatal Parser-Error:" + exception.getMessage());
+ }
+ }
+ }
+diff -ru pentaho-libxml-1.1.3.orig/source/org/pentaho/reporting/libraries/xmlns/parser/ParserEntityResolver.java pentaho-libxml-1.1.3/source/org/pentaho/reporting/libraries/xmlns/parser/ParserEntityResolver.java
+--- pentaho-libxml-1.1.3.orig/source/org/pentaho/reporting/libraries/xmlns/parser/ParserEntityResolver.java 2021-04-07 11:34:22.314653798 +0100
++++ pentaho-libxml-1.1.3/source/org/pentaho/reporting/libraries/xmlns/parser/ParserEntityResolver.java 2021-04-07 11:43:45.602820344 +0100
+@@ -22,8 +22,7 @@
+ import java.net.URL;
+ import java.util.HashMap;
+
+-import org.apache.commons.logging.Log;
+-import org.apache.commons.logging.LogFactory;
++import java.util.logging.Logger;
+ import org.xml.sax.EntityResolver;
+ import org.xml.sax.InputSource;
+
+@@ -34,7 +33,7 @@
+ */
+ public final class ParserEntityResolver implements EntityResolver
+ {
+- private static final Log logger = LogFactory.getLog(ParserEntityResolver.class);
++ private static final Logger logger = Logger.getLogger(ParserEntityResolver.class.getName());
+
+ /**
+ * The hashtable for the known entities (deprecated DTDs).
+@@ -75,7 +74,7 @@
+ }
+ else
+ {
+- logger.warn("Validate location failed for " + publicID + " location: " + location);
++ logger.warning("Validate location failed for " + publicID + " location: " + location);
+ return false;
+ }
+ }
+@@ -101,7 +100,7 @@
+ }
+ else
+ {
+- logger.warn("Validate location failed for " + publicID + " location: " + location);
++ logger.warning("Validate location failed for " + publicID + " location: " + location);
+ return false;
+ }
+ }
+@@ -195,7 +194,7 @@
+ }
+ catch (IOException ioe)
+ {
+- logger.warn("Unable to open specified DTD", ioe);
++ logger.warning("Unable to open specified DTD: " + ioe);
+ }
+ return null;
+ }
+diff -ru pentaho-libxml-1.1.3.orig/source/org/pentaho/reporting/libraries/xmlns/parser/ResourceDataInputSource.java pentaho-libxml-1.1.3/source/org/pentaho/reporting/libraries/xmlns/parser/ResourceDataInputSource.java
+--- pentaho-libxml-1.1.3.orig/source/org/pentaho/reporting/libraries/xmlns/parser/ResourceDataInputSource.java 2021-04-07 11:34:22.312653773 +0100
++++ pentaho-libxml-1.1.3/source/org/pentaho/reporting/libraries/xmlns/parser/ResourceDataInputSource.java 2021-04-07 11:44:05.484073284 +0100
+@@ -20,8 +20,7 @@
+ import java.io.InputStream;
+ import java.net.URL;
+
+-import org.apache.commons.logging.Log;
+-import org.apache.commons.logging.LogFactory;
++import java.util.logging.Logger;
+ import org.pentaho.reporting.libraries.resourceloader.ResourceData;
+ import org.pentaho.reporting.libraries.resourceloader.ResourceLoadingException;
+ import org.pentaho.reporting.libraries.resourceloader.ResourceManager;
+@@ -34,7 +33,7 @@
+ */
+ public class ResourceDataInputSource extends InputSource
+ {
+- private static final Log logger = LogFactory.getLog(ResourceDataInputSource.class);
++ private static final Logger logger = Logger.getLogger(ResourceDataInputSource.class.getName());
+ private ResourceData data;
+ private long version;
+ private ResourceManager caller;
+@@ -103,7 +102,7 @@
+ }
+ catch (ResourceLoadingException e)
+ {
+- logger.error("Unable to create byte-stream: " + data.getKey());
++ logger.severe("Unable to create byte-stream: " + data.getKey());
+ return null;
+ }
+ }
diff --git a/java-pentaho-libxml.spec b/java-pentaho-libxml.spec
index b935530..6cb7ca1 100644
--- a/java-pentaho-libxml.spec
+++ b/java-pentaho-libxml.spec
@@ -1,7 +1,7 @@
%define javahome %{_jvmdir}/jdk
Name: java-pentaho-libxml
Version: 1.1.3
-Release: 2mamba
+Release: 3mamba
Summary: LibXML is a namespace aware SAX-Parser utility library
Group: Development/Libraries/Java
Vendor: openmamba
@@ -9,19 +9,20 @@ Distribution: openmamba
Packager: Silvan Calarco
URL: https://sourceforge.net/projects/jfreereport/
Source0: http://sourceforge.net/projects/jfreereport/files/02.%20Libraries/%{version}-stable/libxml-%{version}.zip
+Patch0: java-pentaho-libxml-1.1.3-build.patch
+Patch1: java-pentaho-libxml-1.1.3-java11.patch
+Patch2: java-pentaho-libxml-1.1.3-remove-antcontrib-support.patch
+Patch3: java-pentaho-libxml-1.1.3-remove-commons-logging.patch
License: LGPL
## AUTOBUILDREQ-BEGIN
## AUTOBUILDREQ-END
BuildRequires: javapackages
+BuildRequires: apache-ant
+BuildRequires: java-jfree-libbase
+BuildRequires: java-jfree-libloader
Requires: javapackages
-Provides: java-jfree-libbase
-Obsoletes: java-jfree-libbase <= 1.1.3-1mamba
-Provides: java-jfree-libloader
-Obsoletes: java-jfree-libloader <= 1.1.3-1mamba
-Provides: java-jfree-libxml
-Obsoletes: java-jfree-libxml <= 1.1.3-1mamba
-Provides: java-jfree-libpixie
-Obsoletes: java-jfree-libpixie <= 1.1.3-1mamba
+Requires: java-jfree-libbase
+Requires: java-jfree-libloader
%description
LibXML is a namespace aware SAX-Parser utility library. It eases the pain of implementing non-trivial SAX input handlers. The original code of these classes had been written by Peter Becker for the JCommon library.
@@ -38,21 +39,26 @@ This package contains documentation for %{name}.
%prep
%setup -q -c
+%patch0 -p1 -b .build
+%patch1 -p1 -b .java11
+%patch2 -p1 -b .remove-antcontrib-support
+%patch3 -p1 -b .remove-commons-logging
+
+find . -name "*.jar" -exec rm -f {} \;
+mkdir -p lib
+build-jar-repository -s -p lib libbase libloader
+cd lib
%build
+ant jar javadoc
%install
[ "%{buildroot}" != / ] && rm -rf "%{buildroot}"
mkdir -p %{buildroot}%{_javadir}
-install -pm 644 libxml-%{version}.jar %{buildroot}%{_javadir}/libxml-%{version}.jar
+install -pm 644 dist/libxml-%{version}.jar %{buildroot}%{_javadir}/libxml-%{version}.jar
ln -sf libxml-%{version}.jar %{buildroot}%{_javadir}/libxml.jar
-for f in libbase libloader libpixie; do
- install -pm 644 lib/${f}-%{version}.jar %{buildroot}%{_javadir}/${f}-%{version}.jar
- ln -sf ${f}-%{version}.jar %{buildroot}%{_javadir}/${f}.jar
-done
-
%clean
[ "%{buildroot}" != / ] && rm -rf "%{buildroot}"
@@ -60,15 +66,12 @@ done
%defattr(-,root,root)
%{_javadir}/libxml-%{version}.jar
%{_javadir}/libxml.jar
-%{_javadir}/libbase-%{version}.jar
-%{_javadir}/libbase.jar
-%{_javadir}/libloader-%{version}.jar
-%{_javadir}/libloader.jar
-%{_javadir}/libpixie-%{version}.jar
-%{_javadir}/libpixie.jar
%doc licence-LGPL.txt
%changelog
+* Fri Dec 10 2021 Silvan Calarco 1.1.3-3mamba
+- rebuilt with ant and java 11
+
* Thu Dec 02 2021 Silvan Calarco 1.1.3-2mamba
- restored