Accepting request 546919 from home:thomas-schraitle:branches:Java:packages

Correct several smaller issues:

* Use .changes file from older jing package
* Spec additions:
  * Add dtdinst.1 manpage source
  * Use correct license BSD-3-Clause to avoid warning
  * Improve description
  * Install manpages of jing, trang, and dtdinst

* Fix bsc#1069796

OBS-URL: https://build.opensuse.org/request/show/546919
OBS-URL: https://build.opensuse.org/package/show/Java:packages/jing-trang?expand=0&rev=4
This commit is contained in:
Fridrich Strba 2017-12-01 08:55:59 +00:00 committed by Git OBS Bridge
parent 1489d17886
commit 04c108eabe
3 changed files with 152 additions and 13 deletions

20
dtdinst.1 Normal file
View File

@ -0,0 +1,20 @@
.TH DTDINST "1" "September 2009" "DTDinst" "User Commands"
.SH NAME
dtdinst \- XML DTD to XML instance format converter
.SH SYNOPSIS
\fBdtdinst\fR \fB[ \-i ]\fR \fB[ \-r \fIdir\fB ]\fR \fIDTD\fR
.SH DESCRIPTION
.B dtdinst
writes an XML representation of the DTD in DTDinst format to the standard
output.
.SH OPTIONS
.TP
\fB\-r \fIdir\fR
make DTDinst write one or more files containing a RELAX NG schema to the
directory \fIdir\fR.
.TP
\fI\-i\fR
inline ATTLIST declarations. Without this option, DTDinst will generate a define
in the RELAX NG schema for each ATTLIST declaration in the DTD. With this
option, DTDinst will move the patterns generated from ATTLIST declarations into
the corresponding element pattern.

View File

@ -1,4 +1,87 @@
-------------------------------------------------------------------
Thu Nov 30 15:45:18 UTC 2017 - fstrba@suse.com
- Initial commit based on Fedora package
-------------------------------------------------------------------
Wed Nov 15 13:50:44 UTC 2017 - thomas.schraitle@suse.com
- First attempt to combine jing and trang packages into a
single package on OBS
- Use patches and instructions from Fedora, but use %buildroot
instead of $RPM_BUILD_ROOT
- Install manpages for dtdinst, jing, and trang
- Use spec-cleaner
-------------------------------------------------------------------
Tue Nov 14 14:50:00 UTC 2017 - toms@opensuse.org
- Use saxon9 instead of saxon6 for jing script
- Apply spec-cleaner for spec file
-------------------------------------------------------------------
Mon Jan 26 14:25:32 UTC 2015 - toms@opensuse.org
- Fixed name of saxon jar [bsc#914681]
-------------------------------------------------------------------
Mon Sep 9 11:06:03 UTC 2013 - tchvatal@suse.com
- Move from jpackage-utils to javapackage-tools
-------------------------------------------------------------------
Thu Nov 29 15:02:09 UTC 2012 - mvyskocil@suse.com
- used saxon9 for build and as a dependency (bnc#780666)
-------------------------------------------------------------------
Sun Nov 13 19:36:49 UTC 2011 - toms@opensuse.org
- Improved jing script: use now jpackage-utils, added
xml-commons-resolver to better support catalogs
- Adapted requires and buildrequires in spec file
- Updated documentation
* explained -C and -s options, removed obsolete -f
* updated version
-------------------------------------------------------------------
Mon Mar 15 16:46:41 CET 2010 - prusnak@suse.cz
- updated to 20091111
* add -C option to specify the catalog
* fix schematron test suite schema
* provide a resolver that implements OASIS XML catalogs
* take advantage of Java 5 features
-------------------------------------------------------------------
Wed Mar 18 15:14:29 CET 2009 - prusnak@suse.cz
- added documentation (manpage) by Thomas Schraitle
-------------------------------------------------------------------
Thu Nov 27 14:38:07 CET 2008 - prusnak@suse.cz
- updated to 20081028
-------------------------------------------------------------------
Tue Feb 19 16:02:09 CET 2008 - prusnak@suse.cz
- fixed build
-------------------------------------------------------------------
Thu Mar 29 17:46:49 CEST 2007 - rguenther@suse.de
- add unzip BuildRequires
-------------------------------------------------------------------
Wed Jan 25 21:46:46 CET 2006 - mls@suse.de
- converted neededforbuild to BuildRequires
-------------------------------------------------------------------
Mon Jun 6 14:18:13 CEST 2005 - ke@suse.de
- Add wrapper script; proposed by Martin Vidner.
-------------------------------------------------------------------
Fri Jun 3 11:15:16 CEST 2005 - ke@suse.de
- New package: jing version 20030619.

View File

@ -20,13 +20,16 @@ Name: jing-trang
Version: 20151127
Release: 0
Summary: Schema validation and conversion based on RELAX NG
License: BSD
License: BSD-3-Clause
URL: https://github.com/relaxng/jing-trang
Source0: https://github.com/relaxng/jing-trang/archive/V%{version}.tar.gz
Source1: dtdinst.1
#
Patch0: 0001-Various-build-fixes.patch
Patch1: 0002-Use-Xalan-instead-of-Saxon-for-the-build-655601.patch
Patch2: %{name}-20091111-datatype-sample.patch
Patch3: %{name}-%{version}-notestng.patch
#
BuildRequires: bsh
BuildRequires: isorelax
BuildRequires: java-devel >= 1.6
@ -40,11 +43,16 @@ BuildRequires: xerces-j2-xml-apis
BuildRequires: xml-apis >= 2.0
BuildRequires: xml-commons-resolver
#!BuildIgnore: xml-commons-jaxp-1.3-apis
BuildRequires: fdupes
BuildArch: noarch
BuildRequires: ant >= 1.8.2
%description
%{summary}.
%{summary}:
jing: Schema validator
trang: Multi-format schema converter
%package -n jing
Summary: RELAX NG validator in Java
@ -54,14 +62,22 @@ Requires: jpackage-utils
Requires: relaxngDatatype
Requires: xerces-j2
Requires: xml-commons-resolver
Recommends: saxon9
%description -n jing
Jing is a RELAX NG validator written in Java. It implements the RELAX
NG 1.0 Specification, RELAX NG Compact Syntax, and parts of RELAX NG
DTD Compatibility, specifically checking of ID/IDREF/IDREFS. It also
has experimental support for schema languages other than RELAX NG;
specifically W3C XML Schema, Schematron 1.5, and Namespace Routing
Language.
jing is an XML validator implemented in Java. It validates against the
RELAX NG schema language and implements the following specifications:
* RELAX NG 1.0 Specification
* RELAX NG Compact Syntax
* Parts of RELAX NG DTD Compatibility (checking of ID/IDREF/IDREFS)
It also comes with experimental support for schema languages other than
RELAX NG:
* W3C XML Schema (based on Xerces-J)
* Schematron 1.5
* Namespace Routing Language
%package -n jing-javadoc
Summary: Javadoc API documentation for Jing
@ -99,13 +115,17 @@ format.
%prep
%setup -q
cp %{SOURCE1} .
mv gcj/{trang,jing}.1 .
rm -r gcj mod/datatype/src/main/org $(find . -name "*.jar")
%patch0 -p1
%patch1 -p1
%patch2 -p1
%patch3 -p1
sed -i -e 's/\r//g' lib/isorelax.copying.txt
find . -name "OldSaxon*.java" -delete # No "old" saxon available in Fedora
find . -name "OldSaxon*.java" -delete # No "old" saxon available in SUSE
sed -i -e 's|"\(copying\.txt\)"|"%{_licensedir}/dtdinst/\1"|' \
dtdinst/index.html
sed -i -e 's|"\(copying\.txt\)"|"%{_licensedir}/trang/\1"|' \
@ -124,27 +144,41 @@ CLASSPATH=$(build-classpath \
%install
rm -rf %{buildroot} *-%{version}
install -dm 755 $RPM_BUILD_ROOT{%{_javadir},%{_javadocdir}}
install -dm 755 $RPM_BUILD_ROOT{%{_javadir},%{_javadocdir},%{_mandir}/man1}
unzip build/dist/jing-%{version}.zip
install -Dpm 644 jing-%{version}/bin/jing.jar %{buildroot}%{_javadir}
mv jing-%{version}/doc/api %{buildroot}%{_javadocdir}/jing
rm -f jing-%{version}/sample/datatype/datatype-sample.jar
# We need to redefine name here to make jpackage_script aware of
# the correct name, otherwise it would use "jing-trang" in configuration names etc.
%define name jing
%jpackage_script com.thaiopensource.relaxng.util.Driver "" "" jing:relaxngDatatype:xml-commons-resolver:xerces-j2 jing true
mkdir -p jing-%{version}/_licenses
mv jing-%{version}/doc/*copying.* jing-%{version}/_licenses
unzip build/dist/trang-%{version}.zip
install -pm 644 trang-%{version}/trang.jar %{buildroot}%{_javadir}
%define name trang
%jpackage_script com.thaiopensource.relaxng.translate.Driver "" "" trang:relaxngDatatype:xml-commons-resolver:xerces-j2 trang true
unzip build/dist/dtdinst-%{version}.zip
install -pm 644 dtdinst-%{version}/dtdinst.jar %{buildroot}%{_javadir}
%define name dtdinst
%jpackage_script com.thaiopensource.xml.dtd.app.Driver "" "" dtdinst dtdinst true
# Install manpages and replace @VERSION@
install -D -m 0644 {dtdinst,jing,trang}.1 %{buildroot}%{_mandir}/man1/
sed -i 's/@VERSION@/%{version}/g' %{buildroot}%{_mandir}/man1/*.1
%fdupes %{buildroot}%{_javadocdir}
%files -n jing
%license jing-%{version}/_licenses/*
%doc jing-%{version}/{readme.html,doc,sample}
%{_mandir}/man1/jing.1%{ext_man}
%{_bindir}/jing
%{_javadir}/jing.jar
@ -157,6 +191,7 @@ install -pm 644 dtdinst-%{version}/dtdinst.jar %{buildroot}%{_javadir}
%doc trang-%{version}/*.html
%{_bindir}/trang
%{_javadir}/trang.jar
%{_mandir}/man1/trang.1%{ext_man}
%files -n dtdinst
%license dtdinst-%{version}/copying.txt
@ -164,5 +199,6 @@ install -pm 644 dtdinst-%{version}/dtdinst.jar %{buildroot}%{_javadir}
%doc dtdinst-%{version}/{dtdinst.rnc.txt,teixml.dtd.txt,example}
%{_bindir}/dtdinst
%{_javadir}/dtdinst.jar
%{_mandir}/man1/dtdinst.1%{ext_man}
%changelog