commit 742365b3820734da740b32a1bd2beae658fb220a65fbd53cc561f6f5ec3c8606 Author: Adrian Schröter Date: Sat May 4 02:09:29 2024 +0200 Sync from SUSE:SLFO:Main xml-commons-resolver revision d4740fda3bb0acddfe6e14c168bca25b diff --git a/.gitattributes b/.gitattributes new file mode 100644 index 0000000..9b03811 --- /dev/null +++ b/.gitattributes @@ -0,0 +1,23 @@ +## Default LFS +*.7z filter=lfs diff=lfs merge=lfs -text +*.bsp filter=lfs diff=lfs merge=lfs -text +*.bz2 filter=lfs diff=lfs merge=lfs -text +*.gem filter=lfs diff=lfs merge=lfs -text +*.gz filter=lfs diff=lfs merge=lfs -text +*.jar filter=lfs diff=lfs merge=lfs -text +*.lz filter=lfs diff=lfs merge=lfs -text +*.lzma filter=lfs diff=lfs merge=lfs -text +*.obscpio filter=lfs diff=lfs merge=lfs -text +*.oxt filter=lfs diff=lfs merge=lfs -text +*.pdf filter=lfs diff=lfs merge=lfs -text +*.png filter=lfs diff=lfs merge=lfs -text +*.rpm filter=lfs diff=lfs merge=lfs -text +*.tbz filter=lfs diff=lfs merge=lfs -text +*.tbz2 filter=lfs diff=lfs merge=lfs -text +*.tgz filter=lfs diff=lfs merge=lfs -text +*.ttf filter=lfs diff=lfs merge=lfs -text +*.txz filter=lfs diff=lfs merge=lfs -text +*.whl filter=lfs diff=lfs merge=lfs -text +*.xz filter=lfs diff=lfs merge=lfs -text +*.zip filter=lfs diff=lfs merge=lfs -text +*.zst filter=lfs diff=lfs merge=lfs -text diff --git a/xml-commons-resolver-1.2-crosslink.patch b/xml-commons-resolver-1.2-crosslink.patch new file mode 100644 index 0000000..bc0cc36 --- /dev/null +++ b/xml-commons-resolver-1.2-crosslink.patch @@ -0,0 +1,11 @@ +diff -up xml-commons-resolver-1.2/resolver.xml~ xml-commons-resolver-1.2/resolver.xml +--- xml-commons-resolver-1.2/resolver.xml~ 2006-11-20 22:23:07.000000000 +0200 ++++ xml-commons-resolver-1.2/resolver.xml 2011-10-19 00:43:22.186668155 +0300 +@@ -148,6 +148,7 @@ Also, you may need to adjust src/documen + use="true" + windowtitle="${name.resolver} API" + doctitle="${name.resolver}" ++ link="/usr/share/javadoc/java" + bottom="${copyright.message}"> + + diff --git a/xml-commons-resolver-1.2-osgi.patch b/xml-commons-resolver-1.2-osgi.patch new file mode 100644 index 0000000..bd95b31 --- /dev/null +++ b/xml-commons-resolver-1.2-osgi.patch @@ -0,0 +1,19 @@ +diff -up xml-commons-resolver-1.2/src/manifest.resolver~ xml-commons-resolver-1.2/src/manifest.resolver +--- xml-commons-resolver-1.2/src/manifest.resolver~ 2006-11-20 22:23:06.000000000 +0200 ++++ xml-commons-resolver-1.2/src/manifest.resolver 2011-10-19 01:38:13.954802303 +0300 +@@ -1,5 +1,15 @@ + Manifest-Version: 1.0 + Main-Class: org.apache.xml.resolver.apps.resolver ++Bundle-RequiredExecutionEnvironment: J2SE-1.2 ++Bundle-SymbolicName: org.apache.xml.resolver ++Bundle-ManifestVersion: 2 ++Bundle-Name: XML Commons Resolver ++Bundle-Localization: plugin ++Bundle-Version: 1.2.0.v200806030312 ++Bundle-Vendor: Apache Software Foundation ++Export-Package: org.apache.env,org.apache.xml.resolver,org.apache.xml. ++ resolver.apps,org.apache.xml.resolver.etc,org.apache.xml.resolver.hel ++ pers,org.apache.xml.resolver.readers,org.apache.xml.resolver.tools + + Name: org/apache/xml/resolver + Comment: xml-commons Resolver code diff --git a/xml-commons-resolver-1.2.tar.gz b/xml-commons-resolver-1.2.tar.gz new file mode 100644 index 0000000..275df24 --- /dev/null +++ b/xml-commons-resolver-1.2.tar.gz @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:55dbe7bd56452c175320ce9a97b752252c5537427221323c72e9b9c1ac221efe +size 262701 diff --git a/xml-commons-resolver-CatalogManager.properties b/xml-commons-resolver-CatalogManager.properties new file mode 100644 index 0000000..43b33f8 --- /dev/null +++ b/xml-commons-resolver-CatalogManager.properties @@ -0,0 +1,64 @@ +# Central CatalogManager.properties for xml-commons-resolver +# JPackage Project + +######################################################################## +# CatalogManager provides an interface to the catalog properties. +# Properties can come from two places: from system properties or +# from a CatalogManager.properties file. This class provides a +# transparent interface to both, with system properties preferred +# over property file values. + +####################################################################### +# Catalog Files: +# The semicolon-delimited list of catalog files. +# Example: catalogs=./xcatalog;/share/doctypes/catalog + +catalogs=/etc/xml/catalog;/etc/sgml/catalog + +####################################################################### +# Relative Catalogs: +# If false, relative catalog URIs are made absolute with respect to the +# base URI of the CatalogManager.properties file. This setting only +# applies to catalog URIs obtained from the catalogs property in the +# CatalogManager.properties file +# Example: relative-catalogs = [yes|no] + +relative-catalogs=no + +####################################################################### +# Verbosity: +# If non-zero, the Catalog classes will print informative and debugging +# messages. The higher the number, the more messages. +# Example: verbosity = [0..99] + +verbosity=0 + +####################################################################### +# Prefer: +# Which identifier is preferred, "public" or "system"? +# Example: xml.catalog.prefer = [public|system] + +prefer=public + +####################################################################### +# Static-catalog: +# Should a single catalog be constructed for all parsing, or should a +# different catalog be created for each parser? +# Example: static-catalog = [yes|no] + +static-catalog=yes + +####################################################################### +# Allow-oasis-xml-catalog-pi +# If the source document contains "oasis-xml-catalog" processing +# instructions, should they be used? +# Example: allow-oasis-xml-catalog-pi = [yes|no] + +allow-oasis-xml-catalog-pi=yes + +####################################################################### +# catalog-class-name +# If you're using the convenience classes +# org.apache.xml.resolver.tools.*, this setting allows you to specify +# an alternate class name to use for the underlying catalog. +# Example: catalog-class-name=org.apache.xml.resolver.Resolver diff --git a/xml-commons-resolver-pom.xml b/xml-commons-resolver-pom.xml new file mode 100644 index 0000000..16c7f23 --- /dev/null +++ b/xml-commons-resolver-pom.xml @@ -0,0 +1,38 @@ + + + apache + org.apache + 3 + + 4.0.0 + xml-resolver + xml-resolver + XML Commons Resolver Component + 1.2 + xml-commons provides an Apache-hosted set of DOM, SAX, and + JAXP interfaces for use in other xml-based projects. Our hope is that we + can standardize on both a common version and packaging scheme for these + critical XML standards interfaces to make the lives of both our developers + and users easier. + http://xml.apache.org/commons/components/resolver/ + + bugzilla + http://issues.apache.org/bugzilla/ + + + + XML Commons Developer's List + commons-dev-subscribe@xml.apache.org + commons-dev-unsubscribe@xml.apache.org + commons-dev@xml.apache.org + http://mail-archives.apache.org/mod_mbox/xml-commons-dev/ + + + + scm:svn:http://svn.apache.org/repos/asf/xml/commons/tags/xml-commons-resolver-1_2/ + http://svn.apache.org/viewvc/xml/commons/tags/xml-commons-resolver-1_2/ + + + deployed + + \ No newline at end of file diff --git a/xml-commons-resolver-resolver.1 b/xml-commons-resolver-resolver.1 new file mode 100644 index 0000000..ffdc15d --- /dev/null +++ b/xml-commons-resolver-resolver.1 @@ -0,0 +1,66 @@ +.TH XML-RESOLVER 1 "11 April 2013" "xml-commons-resolver" "User commands" + +.SH NAME +xml-resolver - A simple command-line resolver + +.SH SYNOPSIS + +.B xml-resolver +[options] keyword + +.SH DESCRIPTION + +\fBxml-resolver\fP is a simple command-line resolver. It takes some parameters +and passes them through the resolver, printing the result. + +The process ends with error-level 1, if there were errors. + +.SH OPTIONS + +Command-line options are described below. + +.PP +.B -c +catalogfile +.RS 4 +Load a particular catalog file +.RE +.PP +.B -n +name +.RS 4 +Sets the name +.RE +.PP +.B -p +publicId +.RS 4 +Sets the public identifier +.RE +.PP +.B -s +systemId +.RS 4 +Sets the system identifier +.RE +.PP +.B -a +.RS 4 +Absolute system URI +.RE +.PP +.B -u +uri +.RS 4 +Sets the URI +.RE +.PP +.B -d +integer +.RS 4 +Set the debug level +.RE + +And keyword is one of: doctype, document, entity, notation, public, +system, or uri. + diff --git a/xml-commons-resolver-xparse.1 b/xml-commons-resolver-xparse.1 new file mode 100644 index 0000000..62f7573 --- /dev/null +++ b/xml-commons-resolver-xparse.1 @@ -0,0 +1,62 @@ +.TH XML-XPARSE 1 "11 April 2013" "xml-commons-resolver" "User commands" + +.SH NAME +xml-xparse - A simple command-line XML parsing application + +.SH SYNOPSIS + +.B xml-xparse +[options] document.xml + +.SH DESCRIPTION + +\fBxml-xparse\fP is a simple command-line XML Parser. It's just a little +wrapper around the JAXP Parser with support for catalogs. + +The process ends with error-level 1, if there were errors. + +.SH OPTIONS + +Command-line options are described below. + +.PP +.B -c +catalogfile +.RS 4 +Load a particular catalog file +.RE +.PP +.B -w +.RS 4 +Perform a well-formed parse, not a validating parse +.RE +.PP +.B -v +(default) +.RS 4 +Perform a validating parse +.RE +.PP +.B -n +.RS 4 +Perform a namespace-ignorant parse +.RE +.PP +.B -N +(default) +.RS 4 +Perform a namespace-aware parse +.RE +.PP +.B -d +integer +.RS 4 +Set the debug level. Warnings are shown if the debug level is > 2 +.RE +.PP +.B -E +integer +.RS 4 +Set the maximum number of errors to display +.RE + diff --git a/xml-commons-resolver-xread.1 b/xml-commons-resolver-xread.1 new file mode 100644 index 0000000..618e9e0 --- /dev/null +++ b/xml-commons-resolver-xread.1 @@ -0,0 +1,67 @@ +.TH XML-XREAD 1 "11 April 2013" "xml-commons-resolver" "User commands" + +.SH NAME +xml-xread - A simple command-line XML parsing application + +.SH SYNOPSIS + +.B xml-xread +[options] document.xml + +.SH DESCRIPTION + +\fBxml-xread\fP is a simple command-line XML Parser. It's just a little +wrapper around the JAXP XMLReader with support for catalogs. + +The process ends with error-level 1, if there were errors. + +.SH OPTIONS + +Command-line options are described below. + +.PP +.B -c +catalogfile +.RS 4 +Load a particular catalog file +.RE +.PP +.B -w +.RS 4 +Perform a well-formed parse, not a validating parse +.RE +.PP +.B -v +(default) +.RS 4 +Perform a validating parse +.RE +.PP +.B -s +.RS 4 +Enable W3C XML Schema validation +.RE +.PP +.B -n +.RS 4 +Perform a namespace-ignorant parse +.RE +.PP +.B -N +(default) +.RS 4 +Perform a namespace-aware parse +.RE +.PP +.B -d +integer +.RS 4 +Set the debug level. Warnings are shown if the debug level is > 2 +.RE +.PP +.B -E +integer +.RS 4 +Set the maximum number of errors to display +.RE + diff --git a/xml-commons-resolver.changes b/xml-commons-resolver.changes new file mode 100644 index 0000000..1ccdd6c --- /dev/null +++ b/xml-commons-resolver.changes @@ -0,0 +1,37 @@ +------------------------------------------------------------------- +Fri Mar 18 16:29:44 UTC 2022 - Fridrich Strba + +- Build with source/target levels 8 + +------------------------------------------------------------------- +Mon Apr 8 11:32:53 UTC 2019 - Fridrich Strba + +- Do not depend on the parent pom since we are not building using + Maven. + +------------------------------------------------------------------- +Fri Feb 1 16:33:40 UTC 2019 - Fridrich Strba + +- BuildIgnore xml-apis and xml-resolver, since this does not + strictly require them for build + +------------------------------------------------------------------- +Fri Feb 1 12:59:05 UTC 2019 - Fridrich Strba + +- BuildIgnore xerces-j2 to break cycle of OSGi requires + +------------------------------------------------------------------- +Thu Dec 13 10:52:02 UTC 2018 - Fridrich Strba + +- Obsolete the different other xml-resolver providers + +------------------------------------------------------------------- +Tue Dec 11 01:20:14 UTC 2018 - Jan Engelhardt + +- Fix RPM groups. Use improved file deletion. + +------------------------------------------------------------------- +Thu Dec 6 11:50:01 UTC 2018 - Fridrich Strba + +- Initial package of xml-commons-resolver +- Add compatibility symlinks as well as provides diff --git a/xml-commons-resolver.spec b/xml-commons-resolver.spec new file mode 100644 index 0000000..42230f7 --- /dev/null +++ b/xml-commons-resolver.spec @@ -0,0 +1,134 @@ +# +# spec file for package xml-commons-resolver +# +# Copyright (c) 2022 SUSE LLC +# +# All modifications and additions to the file contributed by third parties +# remain the property of their copyright owners, unless otherwise agreed +# upon. The license for this file, and modifications and additions to the +# file, is the same license as for the pristine package itself (unless the +# license for the pristine package is not an Open Source License, in which +# case the license is the MIT License). An "Open Source License" is a +# license that conforms to the Open Source Definition (Version 1.9) +# published by the Open Source Initiative. + +# Please submit bugfixes or comments via https://bugs.opensuse.org/ +# + + +%define resolverdir %{_sysconfdir}/java/resolver +Name: xml-commons-resolver +Version: 1.2 +Release: 0 +Summary: Resolver subproject of xml-commons +License: Apache-2.0 +Group: Development/Libraries/Java +URL: http://xerces.apache.org/xml-commons/components/resolver/ +Source0: http://www.apache.org/dist/xerces/xml-commons/%{name}-%{version}.tar.gz +Source5: %{name}-pom.xml +Source6: %{name}-resolver.1 +Source7: %{name}-xparse.1 +Source8: %{name}-xread.1 +Source10: %{name}-CatalogManager.properties +Patch0: %{name}-1.2-crosslink.patch +Patch1: %{name}-1.2-osgi.patch +BuildRequires: ant +BuildRequires: fdupes +BuildRequires: java-devel >= 1.8 +BuildRequires: javapackages-local +#!BuildIgnore: xerces-j2 xml-apis xml-resolver +# Explicit javapackages-tools requires since scripts use +# /usr/share/java-utils/java-functions +Requires: javapackages-tools +Conflicts: xml-commons-resolver-bootstrap +Provides: %{name}10 +Provides: %{name}11 +Provides: %{name}12 +Provides: xerces-j2-xml-resolver +Provides: xml-commons +Obsoletes: %{name}10 +Obsoletes: %{name}11 +Obsoletes: %{name}12 +Obsoletes: xerces-j2-xml-resolver +Obsoletes: xml-commons +Provides: xml-resolver = %{version}-%{release} +BuildArch: noarch + +%description +Resolver subproject of xml-commons. + +%package javadoc +Summary: Javadoc for %{name} +Group: Documentation/HTML + +%description javadoc +Javadoc for %{name}. + +%prep +%setup -q +%patch0 -p1 +%patch1 -p1 + +cp %{SOURCE5} pom.xml + +# remove all binary libs and prebuilt javadocs +find . -name "*.jar" -delete +rm -rf docs +sed -i 's/\r//' KEYS LICENSE.resolver.txt NOTICE-resolver.txt + +%pom_remove_parent . + +%build +%{ant} -f resolver.xml -Dant.build.javac.source=8 -Dant.build.javac.target=8 jar javadocs + +%install +# jar +install -d -m 0755 %{buildroot}%{_javadir} +install -pm 644 build/resolver.jar %{buildroot}%{_javadir}/%{name}.jar +pushd %{buildroot}%{_javadir} + for i in xerces-j2-xml-resolver xml-resolver %{name}10 %{name}11 %{name}12; do + ln -s %{name}.jar ${i}.jar + done +popd + +# pom +install -d -m 0755 %{buildroot}%{_mavenpomdir} +install -pm 644 pom.xml %{buildroot}%{_mavenpomdir}/%{name}.pom +%add_maven_depmap %{name}.pom %{name}.jar + +# javadoc +install -d -m 0755 %{buildroot}%{_javadocdir}/%{name} +cp -a build/apidocs/resolver/* %{buildroot}%{_javadocdir}/%{name} +%fdupes -s %{buildroot}%{_javadocdir} + +# Scripts +mkdir -p %{buildroot}%{_bindir} +%jpackage_script org.apache.xml.resolver.apps.resolver "" "" %{name} xml-resolver true +%jpackage_script org.apache.xml.resolver.apps.xread "" "" %{name} xml-xread true +%jpackage_script org.apache.xml.resolver.apps.xparse "" "" %{name} xml-xparse true + +# Man pages +install -d -m 755 %{buildroot}%{_mandir}/man1 +install -p -m 644 %{SOURCE6} %{buildroot}%{_mandir}/man1/xml-resolver.1 +install -p -m 644 %{SOURCE7} %{buildroot}%{_mandir}/man1/xml-xparse.1 +install -p -m 644 %{SOURCE8} %{buildroot}%{_mandir}/man1/xml-xread.1 + +# Central CatalogManager.properties +install -d -m 755 %{buildroot}%{resolverdir} +install -m 0644 %{SOURCE10} %{buildroot}%{resolverdir}/CatalogManager.properties + +%files -f .mfiles +%license LICENSE.resolver.txt +%doc KEYS NOTICE-resolver.txt +%{_mandir}/man1/* +%{_bindir}/xml-* +%config(noreplace) %{resolverdir}/* +%dir %{resolverdir} +%{_javadir}/* + +%files javadoc +%license LICENSE.resolver.txt +%doc NOTICE-resolver.txt +%{_javadocdir}/%{name} + +%changelog