c37bf7
Name:          msv
c37bf7
Epoch:         1
c37bf7
Version:       2013.6.1
c37bf7
Release:       11%{?dist}
c37bf7
Summary:       Multi-Schema Validator
c37bf7
License:       BSD and ASL 1.1
c37bf7
URL:           http://msv.java.net/
c37bf7
c37bf7
# To generate tarball from upstream source control:
c37bf7
# $ ./create-tarball
c37bf7
Source0:       %{name}-%{version}-clean.tar.gz
c37bf7
c37bf7
Source2:       http://www.apache.org/licenses/LICENSE-2.0.txt
c37bf7
Source3:       create-tarball.sh
c37bf7
c37bf7
# Use CatalogResolver from xml-commons-resolver package
c37bf7
Patch1:        %{name}-Use-CatalogResolver-class-from-xml-commons-resolver.patch
c37bf7
c37bf7
BuildRequires:  maven-local
c37bf7
BuildRequires:  mvn(isorelax:isorelax)
c37bf7
BuildRequires:  mvn(jdom:jdom)
c37bf7
BuildRequires:  mvn(junit:junit)
c37bf7
BuildRequires:  mvn(net.java:jvnet-parent:pom:)
c37bf7
BuildRequires:  mvn(org.apache.ant:ant)
c37bf7
BuildRequires:  mvn(org.apache.felix:maven-bundle-plugin)
c37bf7
BuildRequires:  mvn(org.apache.maven.plugins:maven-enforcer-plugin)
c37bf7
BuildRequires:  mvn(org.apache.maven.plugins:maven-source-plugin)
c37bf7
BuildRequires:  mvn(org.codehaus.mojo:build-helper-maven-plugin)
c37bf7
BuildRequires:  mvn(relaxngDatatype:relaxngDatatype)
c37bf7
BuildRequires:  mvn(xerces:xercesImpl)
c37bf7
BuildRequires:  mvn(xml-resolver:xml-resolver)
c37bf7
c37bf7
BuildArch:     noarch
c37bf7
c37bf7
Obsoletes:     %{name}-relames < %{version}-%{release}
c37bf7
c37bf7
%description
c37bf7
The Sun Multi-Schema XML Validator (MSV) is a Java technology tool to validate
c37bf7
XML documents against several kinds of XML schemata. It supports RELAX NG,
c37bf7
RELAX Namespace, RELAX Core, TREX, XML DTDs, and a subset of XML Schema Part 1.
c37bf7
This latest (version 1.2) release includes several bug fixes and adds better
c37bf7
conformance to RELAX NG/W3C XML standards and JAXP masquerading.
c37bf7
c37bf7
%package       msv
c37bf7
Summary:       Multi-Schema Validator Core
c37bf7
# src/com/sun/msv/reader/xmlschema/DOMLSInputImpl.java is under ASL 2.0
c37bf7
# msv/src/com/sun/msv/writer/ContentHandlerAdaptor.java is partially under Public Domain
c37bf7
License:       BSD and ASL 1.1 and ASL 2.0 and Public Domain
c37bf7
c37bf7
%description   msv
c37bf7
%{summary}.
c37bf7
c37bf7
%package       rngconv
c37bf7
Summary:       Multi-Schema Validator RNG Converter
c37bf7
c37bf7
%description   rngconv
c37bf7
%{summary}.
c37bf7
c37bf7
%package       xmlgen
c37bf7
Summary:       Multi-Schema Validator Generator
c37bf7
c37bf7
%description   xmlgen
c37bf7
%{summary}.
c37bf7
c37bf7
%package       xsdlib
c37bf7
Summary:       Multi-Schema Validator XML Schema Library
c37bf7
c37bf7
%description   xsdlib
c37bf7
%{summary}.
c37bf7
c37bf7
%package       javadoc
c37bf7
Summary:       API documentation for Multi-Schema Validator
c37bf7
License:       BSD and ASL 1.1 and ASL 2.0 and Public Domain
c37bf7
c37bf7
%description   javadoc
c37bf7
%{summary}.
c37bf7
c37bf7
%package       manual
c37bf7
Summary:       Manual for Multi-Schema Validator
c37bf7
License:       BSD
c37bf7
c37bf7
%description   manual
c37bf7
%{summary}.
c37bf7
c37bf7
%package       demo
c37bf7
Summary:       Samples for Multi-Schema Validator
c37bf7
License:       BSD
c37bf7
Requires:      msv-msv
c37bf7
Requires:      msv-xsdlib
c37bf7
c37bf7
%description   demo
c37bf7
%{summary}.
c37bf7
c37bf7
%prep
c37bf7
%setup -q
c37bf7
c37bf7
# We don't have this plugin
c37bf7
%pom_remove_plugin :buildnumber-maven-plugin
c37bf7
c37bf7
# javadoc generation fails due to strict doclint in JDK 8
c37bf7
%pom_remove_plugin :maven-javadoc-plugin
c37bf7
c37bf7
# Needed becuase of patch3
c37bf7
%pom_add_dep xml-resolver:xml-resolver
c37bf7
c37bf7
# ASL 2.0 license text
c37bf7
cp %{SOURCE2} Apache-LICENSE-2.0.txt
c37bf7
c37bf7
# Delete anything pre-compiled
c37bf7
find -name '*.class' -exec rm -f '{}' \;
c37bf7
find -name '*.jar' -exec rm -f '{}' \;
c37bf7
find -name '*.zip' -exec rm -f '{}' \;
c37bf7
c37bf7
# Test sources in default package break BND
c37bf7
rm -f testharness/src/*.java
c37bf7
c37bf7
# Delete class-path entries from manifests
c37bf7
for m in $(find . -name MANIFEST.MF) ; do
c37bf7
  sed --in-place -e '/^[Cc]lass-[Pp]ath:/d' $m
c37bf7
done
c37bf7
c37bf7
# Apply patches
c37bf7
%patch1 -p1
c37bf7
c37bf7
# Fix isorelax groupId
c37bf7
%pom_xpath_replace "pom:dependency[pom:groupId[text()='com.sun.xml.bind.jaxb']]/pom:groupId" "<groupId>isorelax</groupId>"
c37bf7
%pom_xpath_replace "pom:dependency[pom:groupId[text()='com.sun.xml.bind.jaxb']]/pom:groupId" "<groupId>isorelax</groupId>" msv
c37bf7
c37bf7
# Change encoding of non utf-8 files
c37bf7
for m in $(find . -name copyright.txt) ; do
c37bf7
  iconv -f iso-8859-1 -t utf-8 < $m > $m.utf8
c37bf7
  mv $m.utf8 $m
c37bf7
done
c37bf7
c37bf7
%mvn_file ":%{name}-core" %{name}-core %{name}-%{name}
c37bf7
%mvn_file ":%{name}-rngconverter" %{name}-rngconverter %{name}-rngconv
c37bf7
%mvn_file ":%{name}-generator" %{name}-generator %{name}-xmlgen
c37bf7
%mvn_file ":xsdlib" xsdlib %{name}-xsdlib
c37bf7
c37bf7
%mvn_alias ":xsdlib" "com.sun.msv.datatype.xsd:xsdlib"
c37bf7
c37bf7
%mvn_package ":*::{tests,javadoc,sources}:" __noinstall
c37bf7
%mvn_package ":%{name}{,-testharness}::{}:" __noinstall
c37bf7
%mvn_package ":%{name}{,-core}::{}:" %{name}-msv
c37bf7
c37bf7
%build
c37bf7
%mvn_build -s
c37bf7
c37bf7
%install
c37bf7
%mvn_install
c37bf7
c37bf7
# Manuals
c37bf7
install -d -m 755 %{buildroot}%{_docdir}/%{name}/msv
c37bf7
install -m 644 msv/doc/*.html     %{buildroot}%{_docdir}/%{name}/msv
c37bf7
install -m 644 msv/doc/*.gif      %{buildroot}%{_docdir}/%{name}/msv
c37bf7
install -m 644 msv/doc/README.txt %{buildroot}%{_docdir}/%{name}/msv
c37bf7
c37bf7
install -d -m 755 %{buildroot}%{_docdir}/%{name}/rngconverter
c37bf7
install -m 644 rngconverter/README.txt %{buildroot}%{_docdir}/%{name}/rngconverter
c37bf7
c37bf7
install -d -m 755 %{buildroot}%{_docdir}/%{name}/generator
c37bf7
install -m 644 generator/*.html     %{buildroot}%{_docdir}/%{name}/generator
c37bf7
install -m 644 generator/README.txt %{buildroot}%{_docdir}/%{name}/generator
c37bf7
c37bf7
install -d -m 755 %{buildroot}%{_docdir}/%{name}/xsdlib
c37bf7
install -m 644 xsdlib/*.html     %{buildroot}%{_docdir}/%{name}/xsdlib
c37bf7
install -m 644 xsdlib/README.txt %{buildroot}%{_docdir}/%{name}/xsdlib
c37bf7
c37bf7
# Examples
c37bf7
install -d -m 755 %{buildroot}%{_datadir}/%{name}/msv
c37bf7
cp -pr msv/examples/* %{buildroot}%{_datadir}/%{name}/msv
c37bf7
install -d -m 755 %{buildroot}%{_datadir}/%{name}/xsdlib
c37bf7
cp -pr xsdlib/examples/* %{buildroot}%{_datadir}/%{name}/xsdlib
c37bf7
c37bf7
# Scripts
c37bf7
%jpackage_script com.sun.msv.driver.textui.Driver "" "" msv-msv:msv-xsdlib:relaxngDatatype:isorelax msv true
c37bf7
%jpackage_script com.sun.msv.generator.Driver "" "" msv-xmlgen:msv-msv:msv-xsdlib:relaxngDatatype:isorelax:xerces-j2 xmlgen true
c37bf7
%jpackage_script com.sun.msv.writer.relaxng.Driver "" "" msv-rngconv:msv-msv:msv-xsdlib:relaxngDatatype:isorelax:xerces-j2 rngconv true
c37bf7
c37bf7
%files msv -f .mfiles-msv-msv
c37bf7
%{_bindir}/msv
c37bf7
%doc License.txt
c37bf7
%doc msv/doc/Apache-LICENSE-1.1.txt
c37bf7
%doc Apache-LICENSE-2.0.txt
c37bf7
c37bf7
%files rngconv -f .mfiles-msv-rngconverter
c37bf7
%{_bindir}/rngconv
c37bf7
%doc msv/doc/Apache-LICENSE-1.1.txt
c37bf7
%doc License.txt
c37bf7
c37bf7
%files xmlgen -f .mfiles-msv-generator
c37bf7
%{_bindir}/xmlgen
c37bf7
%doc msv/doc/Apache-LICENSE-1.1.txt
c37bf7
%doc License.txt
c37bf7
c37bf7
%files xsdlib -f .mfiles-xsdlib
c37bf7
%doc msv/doc/Apache-LICENSE-1.1.txt
c37bf7
%doc License.txt
c37bf7
c37bf7
%files javadoc -f .mfiles-javadoc
c37bf7
%doc License.txt
c37bf7
%doc msv/doc/Apache-LICENSE-1.1.txt
c37bf7
%doc Apache-LICENSE-2.0.txt
c37bf7
c37bf7
%files manual
c37bf7
%doc %{_docdir}/%{name}
c37bf7
%doc License.txt
c37bf7
c37bf7
%files demo
c37bf7
%{_datadir}/%{name}
c37bf7
c37bf7
%changelog
c37bf7
* Thu Feb 08 2018 Fedora Release Engineering <releng@fedoraproject.org> - 1:2013.6.1-11
c37bf7
- Rebuilt for https://fedoraproject.org/wiki/Fedora_28_Mass_Rebuild
c37bf7
c37bf7
* Wed Jul 26 2017 Fedora Release Engineering <releng@fedoraproject.org> - 1:2013.6.1-10
c37bf7
- Rebuilt for https://fedoraproject.org/wiki/Fedora_27_Mass_Rebuild
c37bf7
c37bf7
* Fri Feb 10 2017 Fedora Release Engineering <releng@fedoraproject.org> - 1:2013.6.1-9
c37bf7
- Rebuilt for https://fedoraproject.org/wiki/Fedora_26_Mass_Rebuild
c37bf7
c37bf7
* Thu Feb 04 2016 Fedora Release Engineering <releng@fedoraproject.org> - 1:2013.6.1-8
c37bf7
- Rebuilt for https://fedoraproject.org/wiki/Fedora_24_Mass_Rebuild
c37bf7
c37bf7
* Wed Sep 23 2015 Mikolaj Izdebski <mizdebsk@redhat.com> - 1:2013.6.1-7
c37bf7
- Remove testharness sources from default package
c37bf7
- Resolves: rhbz#1263628
c37bf7
c37bf7
* Wed Jun 17 2015 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1:2013.6.1-6
c37bf7
- Rebuilt for https://fedoraproject.org/wiki/Fedora_23_Mass_Rebuild
c37bf7
c37bf7
* Thu May 14 2015 Mikolaj Izdebski <mizdebsk@redhat.com> - 1:2013.6.1-5
c37bf7
- Remove maven-javadoc-plugin execution
c37bf7
c37bf7
* Sun Sep 14 2014 Gerard Ryan <galileo@fedoraproject.org> - 1:2013.6.1-4
c37bf7
- Don't install testharness jar: pulls in ant
c37bf7
- Fix changelog bogus date warning
c37bf7
c37bf7
* Mon Aug  4 2014 Mikolaj Izdebski <mizdebsk@redhat.com> - 1:2013.6.1-3
c37bf7
- Remove unneeded build-requires
c37bf7
- Fix build-requires on jvnet-parent
c37bf7
c37bf7
* Sat Jun 07 2014 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1:2013.6.1-2
c37bf7
- Rebuilt for https://fedoraproject.org/wiki/Fedora_21_Mass_Rebuild
c37bf7
c37bf7
* Mon Sep 23 2013 Michal Srb <msrb@redhat.com> - 1:2013.6.1-1
c37bf7
- Update to upstream version 2013.6.1
c37bf7
c37bf7
* Mon Sep 23 2013 Michal Srb <msrb@redhat.com> - 1:2013.5.1-7
c37bf7
- Adapt to current guidelines
c37bf7
c37bf7
* Wed Aug 07 2013 Michal Srb <msrb@redhat.com> - 1:2013.5.1-6
c37bf7
- Unversioned doc dir (Resolves: #993980)
c37bf7
- See: http://fedoraproject.org/wiki/Changes/UnversionedDocdirs
c37bf7
c37bf7
* Tue Aug 06 2013 Michal Srb <msrb@redhat.com> - 1:2013.5.1-5
c37bf7
- Provide net.java.dev.msv:msv (Resolves: #993872)
c37bf7
c37bf7
* Sat Aug 03 2013 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1:2013.5.1-4
c37bf7
- Rebuilt for https://fedoraproject.org/wiki/Fedora_20_Mass_Rebuild
c37bf7
c37bf7
* Thu Aug 01 2013 Michal Srb <msrb@redhat.com> - 1:2013.5.1-3
c37bf7
- Fix license tag (+Public Domain)
c37bf7
- Add create-tarball.sh to SRPM
c37bf7
c37bf7
* Wed Jul 31 2013 Michal Srb <msrb@redhat.com> - 1:2013.5.1-2
c37bf7
- Do not build module with unclear licensing (relames)
c37bf7
- Replace %%add_to_maven_depmap with %%add_maven_depmap
c37bf7
c37bf7
* Fri Jun 07 2013 Michal Srb <msrb@redhat.com> - 1:2013.5.1-1
c37bf7
- Update to latest upstream version 2013.5.1
c37bf7
- Clean up tarball
c37bf7
- Fix BR/R
c37bf7
c37bf7
* Fri Apr 12 2013 Michal Srb <msrb@redhat.com> - 1:2013.2.3-3
c37bf7
- Fix license tags in javadoc, manual, demo subpackages
c37bf7
c37bf7
* Fri Apr 12 2013 Michal Srb <msrb@redhat.com> - 1:2013.2.3-2
c37bf7
- Fix license tag for msv subpackage
c37bf7
- Remove unneeded patches
c37bf7
c37bf7
* Thu Apr 11 2013 Michal Srb <msrb@redhat.com> - 1:2013.2.3-1
c37bf7
- Update to upstream version 2013.2.3
c37bf7
- Resolves: rhbz#876845
c37bf7
- Fix URL and license tag
c37bf7
c37bf7
* Mon Feb 25 2013 Mikolaj Izdebski <mizdebsk@redhat.com> - 1:2009.1-14
c37bf7
- Add missing BR: maven-local
c37bf7
c37bf7
* Thu Feb 14 2013 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1:2009.1-13
c37bf7
- Rebuilt for https://fedoraproject.org/wiki/Fedora_19_Mass_Rebuild
c37bf7
c37bf7
* Fri Jul 20 2012 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1:2009.1-12
c37bf7
- Rebuilt for https://fedoraproject.org/wiki/Fedora_18_Mass_Rebuild
c37bf7
c37bf7
* Fri Apr 6 2012 Alexander Kurtakov <akurtako@redhat.com> 1:2009.1-11
c37bf7
- Drop unneeded BR/R.
c37bf7
c37bf7
* Fri Jan 13 2012 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1:2009.1-10
c37bf7
- Rebuilt for https://fedoraproject.org/wiki/Fedora_17_Mass_Rebuild
c37bf7
c37bf7
* Tue Nov 29 2011 Alexander Kurtakov <akurtako@redhat.com> 1:2009.1-9
c37bf7
- Build with maven 3.
c37bf7
- Adapt to current guidelines.
c37bf7
c37bf7
* Tue Feb 08 2011 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1:2009.1-8
c37bf7
- Rebuilt for https://fedoraproject.org/wiki/Fedora_15_Mass_Rebuild
c37bf7
c37bf7
* Tue Nov  2 2010 Ville Skyttä <ville.skytta@iki.fi> - 1:2009.1-7
c37bf7
- Add msv, relames, xmlgen, and rngconv command line scripts.
c37bf7
c37bf7
* Thu Oct 28 2010 Alexander Kurtakov <akurtako@redhat.com> 1:2009.1-6
c37bf7
- BR junit4.
c37bf7
c37bf7
* Thu Oct 28 2010 Alexander Kurtakov <akurtako@redhat.com> 1:2009.1-5
c37bf7
- Fix depmaps and install jars required by msv.pom.
c37bf7
c37bf7
* Fri Sep 24 2010 Mat Booth <fedora@matbooth.co.uk> - 1:2009.1-4
c37bf7
- Really require a version of xml-commons-resolver that provides the necessary
c37bf7
  maven pom and depmap.
c37bf7
c37bf7
* Sun Sep 19 2010 Mat Booth <fedora@matbooth.co.uk> - 1:2009.1-3
c37bf7
- Require a version of xml-commons-resolver that provides the necessary maven
c37bf7
  pom and depmap.
c37bf7
c37bf7
* Sun Sep 19 2010 Mat Booth <fedora@matbooth.co.uk> - 1:2009.1-2
c37bf7
- Re-patch build to link to local javadocs.
c37bf7
- Install maven poms/depmap.
c37bf7
c37bf7
* Thu Sep 16 2010 Mat Booth <fedora@matbooth.co.uk> - 1:2009.1-1
c37bf7
- Update to latest tagged release.
c37bf7
- Drop support for GCJ ahead of time compilation.
c37bf7
- Fix RHBZ #627688, RHBZ #631076
c37bf7
- This project now builds with maven instead of ant.
c37bf7
- The new build in this release aggregates javadocs, so now we have one javadoc
c37bf7
  package that obsoletes the many javadoc packages we had before.
c37bf7
- Use new jar names that upstream use, provide the old names.
c37bf7
- Misc other changes for guideline compliance.
c37bf7
c37bf7
* Sat Jul 25 2009 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1:1.2-0.4.20050722.3.4.1
c37bf7
- Rebuilt for https://fedoraproject.org/wiki/Fedora_12_Mass_Rebuild
c37bf7
c37bf7
* Fri May 08 2009 Karsten Hopp <karsten@redhat.com> 1.2-0.3.20050722.3.4.1
c37bf7
- Specify source and target as 1.4 to make it build
c37bf7
c37bf7
* Wed Feb 25 2009 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1:1.2-0.3.20050722.3.4
c37bf7
- Rebuilt for https://fedoraproject.org/wiki/Fedora_11_Mass_Rebuild
c37bf7
c37bf7
* Wed Jul  9 2008 Tom "spot" Callaway <tcallawa@redhat.com> - 1:1.2-0.2.20050722.3.4
c37bf7
- drop repotag
c37bf7
c37bf7
* Tue Feb 19 2008 Fedora Release Engineering <rel-eng@fedoraproject.org> - 1:1.2-0.2.20050722.3jpp.3
c37bf7
- Autorebuild for GCC 4.3
c37bf7
c37bf7
* Wed Sep 12 2007 Matt Wringe <mwringe@redhat.com> 0:1,2-0.1.20050722.3jpp.3
c37bf7
- Make package build with new gcj. Remove .class files from demo package and
c37bf7
  remove demo exclude from aot-compile-rpm 
c37bf7
c37bf7
* Tue Sep 11 2007 Matt Wringe <mwringe@redhat.com> 0:1.2-0.1.20050722.3jpp.2
c37bf7
- Fix unowned directories
c37bf7
- Change copyright files to utf-8 format
c37bf7
- Change license field to BSD (from BSD-Style)
c37bf7
c37bf7
* Fri Feb 16 2007 Andrew Overholt <overholt@redhat.com> 0:1.2-0.1.20050722.3jpp.1
c37bf7
- Remove postun Requires on jpackage-utils
c37bf7
- Set gcj_support to 1
c37bf7
- Fix groups to shut up rpmlint
c37bf7
- Add versions to the Provides and Obsoletes
c37bf7
- Add patch to take out Class-Path in MANIFEST.MF
c37bf7
c37bf7
* Thu Feb 15 2007 Matt Wringe <mwringe at redhat.com> - 0:1.2-0.1.20050722.3jpp.1.fc7
c37bf7
- Extract sources from a fresh CVS export of the given tag and add extra source
c37bf7
  required to build the package not present in the 20050722 tag anymore
c37bf7
- Add a patch to remove compile time dependency on crimson
c37bf7
- Add a patch to enable compression of jar files
c37bf7
- Add jpackage-utils as a requires for the packages/subpackages
c37bf7
c37bf7
* Mon Feb 12 2007 Ralph Apel <r.apel at r-apel.de> - 0:1.2-0.20050722.3jpp
c37bf7
- Add bootstrap option to build without saxon nor jdom
c37bf7
- Add gcj_support option
c37bf7
c37bf7
* Fri Feb 17 2006 Fernando Nasser <fnasser@redhat.com> - 0:1.2-0.20050722.2jpp
c37bf7
- First JPP 1.7 build
c37bf7
c37bf7
* Wed Aug 17 2005 Ralph Apel <r.apel at r-apel.de> - 0:1.2-0.20050722.1jpp
c37bf7
- First JPP from this code base