%define pkgver %(echo %version | tr . -) %define javahome %{_jvmdir}/jdk Name: java-saxon9 Version: 9.1.0.7 Release: 3mamba Summary: Saxon XSLT and XQuery Processor Group: Development/Libraries/Java Vendor: openmamba Distribution: openmamba Packager: gil URL: http://saxon.sourceforge.net # http://saxon.svn.sourceforge.net/viewvc/saxon Source0: http://downloads.sourceforge.net/project/saxon/Saxon-B/%{version}/saxonb%{pkgver}source.zip Source1: java-saxon9-services.tar.gz Source2: java-saxon9.build.script Patch0: java-saxon9.1.0.7-Configuration.patch License: MPL BuildRequires: apache-ant %if "%{stage1}" != "1" BuildRequires: apache-fop == 0.95 BuildRequires: apache-fop-javadoc == 0.95 %endif BuildRequires: java-xom BuildRequires: java-xqjapi BuildRequires: java-dom BuildRequires: java-dom-javadoc BuildRequires: java-bea-stax BuildRequires: java-bea-stax-api BuildRequires: java-dom4j BuildRequires: jpackage-utils BuildRequires: xml-commons-apis Requires: java-bea-stax Requires: java-bea-stax-api Requires: java-dom Requires: java-dom4j Requires: jpackage-utils Requires: xml-commons-apis Obsoletes: saxon9 Provides: saxon9 BuildRoot: %{_tmppath}/%{name}-%{version}-root %description The Saxon XSLT and XQuery processor, developed by Michael Kay The SAXON package is a collection of tools for processing XML documents. The main components are: - An XSLT processor, which implements the Version 1.0 XSLT and XPath Recommendations from the World Wide Web Consortium, found at http://www.w3.org/TR/1999/REC-xslt-19991116 and http://www.w3.org/TR/1999/REC-xpath-19991116 with a number of powerful extensions. This version of Saxon also includes many of the new features defined in the XSLT 1.1 working draft, but for conformance and portability reasons these are not available if the stylesheet header specifies version="1.0". - A Java library, which supports a similar processing model to XSL, but allows full programming capability, which you need if you want to perform complex processing of the data or to access external services such as a relational database. So you can use SAXON with any SAX-compliant XML parser by writing XSLT stylesheets, by writing Java applications, or by any combination of the two. %package dom Summary: DOM support for %{name} Group: Applications/Publishing Requires: %{name} = %{version}-%{release} Obsoletes: saxon9-dom Provides: saxon9-dom %description dom The SAXON package is a collection of tools for processing XML documents. Provides additional classes enabling Saxon to be used with the DOM Document Object Model. Supports using a DOM as the input or output of transformations and queries, and calling extension functions that use DOM interfaces to access a Saxon tree structure. Requires DOM level 3 (dom.jar, part of JAXP 1.3) to be on the classpath, if not running under JDK 1.5. %package jdom Group: Development/Libraries/Java Summary: JDOM support for %{name} Requires: java-dom Requires: %{name} = %{version}-%{release} Obsoletes: saxon9-jdom Provides: saxon9-jdom %description jdom The SAXON package is a collection of tools for processing XML documents. This package contains JDOM support for %{name}. %package dom4j Group: Development/Libraries/Java Summary: DOM4J support for %{name} Requires: java-dom Requires: %{name} = %{version}-%{release} Obsoletes: saxon9-dom4j Provides: saxon9-dom4j %description dom4j The SAXON package is a collection of tools for processing XML documents. This package contains DOM4J support for %{name}. %package sql Group: Applications/Publishing Summary: SQL support for %{name} Requires: %{name} = %{version}-%{release} Obsoletes: saxon9-sql Provides: saxon9-sql %description sql The SAXON package is a collection of tools for processing XML documents. This package contains supports XSLT extensions for accessing and updating a relational database from within a stylesheet. %package s9api Group: Development/Libraries/Java Summary: Java API for %{name} Obsoletes: saxon9-s9api Provides: saxon9-s9api %description s9api The SAXON package is a collection of tools for processing XML documents. This package provides a Java API for %{name} %package xom Group: Applications/Publishing Summary: XOM support for %{name} Group: Applications/Publishing Requires: %{name} = %{version}-%{release} Requires: java-xom Obsoletes: saxon9-xom Provides: saxon9-xom %description xom The SAXON package is a collection of tools for processing XML documents. Provides additional classes enabling Saxon to be used with XOM trees. Supports using a XOM document as the input or output of transformations and queries. Requires xom.jar on the classpath. %package xpath Group: Applications/Publishing Summary: XPATH support for %{name} Requires: %{name} = %{version}-%{release} Obsoletes: saxon9-xpath Provides: saxon9-xpath %description xpath The SAXON package is a collection of tools for processing XML documents. Provides support for the JAXP 1.3 XPath API. Requires the JAXP 1.3 version of jaxp-api.jar on the classpath, if not running under JDK 1.5. %package xqj Group: Applications/Publishing Summary: XQUERY support for %{name} Requires: %{name} = %{version}-%{release} Requires: java-xqjapi Obsoletes: saxon9-xqj Provides: saxon9-xqj %description xqj The SAXON package is a collection of tools for processing XML documents. This package contains XQUERY support for %{name}. %package javadoc Group: Documentation Summary: Javadoc for %{name} Requires: java-dom-javadoc %description javadoc The SAXON package is a collection of tools for processing XML documents. This package contains javadoc for %{name} %prep %setup -q -c -n saxonb-%{version} -a 1 for j in $(find -name "*.jar"); do mv $j $j.no done for j in $(find -name "*.class"); do rm -rf $j done rm -rf docs/api find -name "*.exe" -exec rm -rf {} \; for j in $(find -name ".svn"); do rm -rf $j done cp -p %{S:2} ./build.xml # require for .NET compilation: IKVM rm -rf bj/net/sf/saxon/dotnet rm -rf net/sf/saxon/dotnet mkdir -p build/classes cp -pr net src/ %patch0 %build export JAVA_HOME=%javahome %if "%{stage1}" != "1" export CLASSPATH=$(build-classpath xml-commons-apis xom fop jdom dom4j bea-stax-ri bea-stax-api xqjapi):build/classes %else export CLASSPATH=$(build-classpath xml-commons-apis xom jdom dom4j bea-stax-ri bea-stax-api xqjapi):build/classes %endif ant \ -Dj2se.javadoc=%{_javadocdir}/java-gcj-compat \ -Djdom.javadoc=%{_javadocdir}/jdom \ -Dfop.javadoc=%{_javadocdir}/fop %install [ "%{buildroot}" != / ] && rm -rf "%{buildroot}" mkdir -p %{buildroot}%{_javadir} install -m 644 build/lib/saxon9-dom4j.jar \ %{buildroot}%{_javadir}/saxon9-dom4j-%{version}.jar install -m 644 build/lib/saxon9-dom.jar \ %{buildroot}%{_javadir}/saxon9-dom-%{version}.jar install -m 644 build/lib/saxon9-jdom.jar \ %{buildroot}%{_javadir}/saxon9-jdom-%{version}.jar install -m 644 build/lib/saxon9-s9api.jar \ %{buildroot}%{_javadir}/saxon9-s9api-%{version}.jar install -m 644 build/lib/saxon9-sql.jar \ %{buildroot}%{_javadir}/saxon9-sql-%{version}.jar install -m 644 build/lib/saxon9-xom.jar \ %{buildroot}%{_javadir}/saxon9-xom-%{version}.jar install -m 644 build/lib/saxon9-xqj.jar \ %{buildroot}%{_javadir}/saxon9-xqj-%{version}.jar install -m 644 build/lib/saxon9-xpath.jar \ %{buildroot}%{_javadir}/saxon9-xpath-%{version}.jar install -m 644 build/lib/saxon9.jar \ %{buildroot}%{_javadir}/saxon9-%{version}.jar ( cd %{buildroot}%{_javadir} for jar in *-%{version}*; do ln -sf ${jar} `echo $jar| sed "s|-%{version}||g"` done ) mkdir -p %{buildroot}%{_javadocdir}/saxon9-%{version} cp -pr build/api/* %{buildroot}%{_javadocdir}/saxon9-%{version} ln -sf saxon9-%{version} %{buildroot}%{_javadocdir}/saxon9 %clean [ "%{buildroot}" != / ] && rm -rf "%{buildroot}" %files %defattr(-,root,root) %{_javadir}/saxon9-%{version}.jar %{_javadir}/saxon9.jar %files dom %defattr(-,root,root) %{_javadir}/saxon9-dom-%{version}.jar %{_javadir}/saxon9-dom.jar %files dom4j %defattr(-,root,root) %{_javadir}/saxon9-dom4j-%{version}.jar %{_javadir}/saxon9-dom4j.jar %files jdom %defattr(-,root,root) %{_javadir}/saxon9-jdom-%{version}.jar %{_javadir}/saxon9-jdom.jar %files s9api %defattr(-,root,root) %{_javadir}/saxon9-s9api-%{version}.jar %{_javadir}/saxon9-s9api.jar %files sql %defattr(-,root,root) %{_javadir}/saxon9-sql-%{version}.jar %{_javadir}/saxon9-sql.jar %files xom %defattr(-,root,root) %{_javadir}/saxon9-xom-%{version}.jar %{_javadir}/saxon9-xom.jar %files xpath %defattr(-,root,root) %{_javadir}/saxon9-xpath-%{version}.jar %{_javadir}/saxon9-xpath.jar %files xqj %defattr(-,root,root) %{_javadir}/saxon9-xqj-%{version}.jar %{_javadir}/saxon9-xqj.jar %files javadoc %defattr(-,root,root) %{_javadocdir}/saxon9-%{version} %{_javadocdir}/saxon9 %changelog * Fri Mar 25 2011 gil 9.1.0.7-3mamba - rebuilt with java-gcj-compat support * Wed Nov 24 2010 gil 9.1.0.7-2mamba - rebuilt devel * Fri May 08 2009 gil 9.1.0.7-1mamba - package created by autospec