packages apache-xmlbeans.spec
      Pages: < 1 >  DOWNLOAD      
%define        with_oldxbean     0
%define        javahome          %{_jvmdir}/jdk
Name:          apache-xmlbeans
Version:       2.4.0
Release:       5mamba
Summary:       XML-Java binding tool
Group:         Development/Libraries/Java
Vendor:        openmamba
Distribution:  openmamba
Packager:      Silvan Calarco <silvan.calarco@...>
Patch0:        apache-xmlbeans-2.4.0-crosslink.patch
License:       Apache Software License 2.0
BuildRequires: apache-ant
%if "%{stage1}" != "1"
BuildRequires: apache-DdlUtils
BuildRequires: java-bea-stax
BuildRequires: java-bea-stax-api
BuildRequires: java-piccolo
BuildRequires: java-saxon8
BuildRequires: java-saxon8-dom
BuildRequires: java-saxon9
BuildRequires: java-saxon9-dom
BuildRequires: java-gcj-compat
#BuildRequires: java-gcj-compat-javadoc
BuildRequires: java-junit3
BuildRequires: xerces-j2-javadoc-apis
BuildRequires: xerces-j2-javadoc-impl
BuildRequires: xerces-j2-javadoc-other
BuildRequires: xerces-j2-javadoc-xni
BuildRequires: xml-commons-resolver
Requires:      jpackage-utils
Obsoletes:     java-xmlbeans
Provides:      java-xmlbeans
BuildRoot:     %{_tmppath}/%{name}-%{version}-root

XMLBeans is a technology for accessing XML by binding it to Java types. 
XMLBeans provides several ways to get at the XML, including:

* Through XML schema that has been compiled to generate Java types that represent schema types. 
In this way, you can access instances of the schema through JavaBeans-style accessors after the fashion of "getFoo" and "setFoo".

The XMLBeans API also allows you to reflect into the XML schema itself through an XML Schema Object model.
* A cursor model through which you can traverse the full XML infoset.
* Support for XML DOM.

%package        javadoc
Group:          Documentation
Summary:        Javadoc for %{name}

%description    javadoc
XMLBeans is a technology for accessing XML by binding it to Java types

This package contains javadoc for %{name}.

%package        manual
Group:          Documentation
Summary:        Manual for %{name}

%description    manual
XMLBeans is a technology for accessing XML by binding it to Java types

This package contains documentation for %{name}.

%package        tools
Group:          Development/Tools
Summary:        Useful command-line scripts for %{name}

%description    tools
XMLBeans is a technology for accessing XML by binding it to Java types

This package contains useful command-line scripts for %{name}.


%setup -q -n xmlbeans-%{version}
for j in $(find -name "*.jar"); do
  	mv $j  $


pushd external/lib
  mv piccolo_apache_dist_20040711_v2.jar
%if "%{stage1}" != "1"
#  ln -sf $(build-classpath piccolo) piccolo_apache_dist_20040711_v2.jar
  ln -sf $(build-classpath piccolo) piccolo_apache_dist_20040711.jar
  ln -sf $(build-classpath piccolo) piccolo_apache_dist_20040629_v2.jar
  ln -sf $(build-classpath saxon8-dom) saxon8.jar
  ln -sf $(build-classpath saxon8) saxon8-dom.jar
  ln -sf $(build-classpath saxon9) saxon9.jar
  ln -sf $(build-classpath saxon9-dom) .
  ln -sf $(build-classpath bea-stax-api) jsr173_1.0_api.jar
  ln -sf $(build-classpath bea-stax-ri) jsr173_1.0_api_bundle.jar
  mv jam-0.1.0-src.jar
  ln -sf $(build-classpath junit-3.8.2) junit.jar
  ln -sf $(build-classpath xml-commons-resolver) resolver.jar
%if %with_oldxbean
  ln -sf $(build-classpath xmlbeans/xbean) oldxbean.jar  
# 2.3.0
  mv oldxbean.jar
mkdir -p build/lib
ln -sf $(build-classpath saxon9-dom) build/lib/saxon9-dom.jar
ln -sf $(build-classpath saxon9) build/lib/saxon9.jar
# mv samples/vxsdb/external/ samples/vxsdb/external/DdlUtils-1.0-RC1.jar
ln -sf $(build-classpath ddlutils) samples/vxsdb/external/DdlUtils-1.0-RC1.jar
mkdir -p external/lib/xml-commons-resolver-1.1
ln -sf $(build-classpath xml-commons-resolver) external/lib/xml-commons-resolver-1.1/resolver.jar
mkdir -p xkit
mkdir -p test/cases/xbean/xmlobject

%if "%{stage1}" != "1"
export CLASSPATH=$(build-classpath saxon9 saxon9-dom xml-commons-resolver)
export CLASSPATH=$(build-classpath xml-commons-resolver)
ant \
  -Dj2se.javadoc=%{_javadocdir}/java-gcj-compat \
  -Dresolver.jar.exists=true \
%if "%{stage1}" != "1"
  -Dsaxon9.jar.exists=true \
  -Dxerces-apis.javadoc=%{_javadocdir}/xerces-j2-apis \
  -Dxerces-impl.javadoc=%{_javadocdir}/xerces-j2-impl \
  -Dxerces-other.javadoc=%{_javadocdir}/xerces-j2-other \
  -Dxerces-xni.javadoc=%{_javadocdir}/xerces-j2-xni \
  dist docs

[ "%{buildroot}" != / ] && rm -rf "%{buildroot}"

mkdir -p %{buildroot}%{_javadir}/xmlbeans
install -p -m 644 build/lib/xmlpublic.jar %{buildroot}%{_javadir}/xmlbeans/xmlpublic-%{version}.jar
install -p -m 644 build/lib/xbean_xpath.jar %{buildroot}%{_javadir}/xmlbeans/xbean_xpath-%{version}.jar
install -p -m 644 build/lib/xmlbeans-qname.jar %{buildroot}%{_javadir}/xmlbeans/xmlbeans-qname-%{version}.jar
install -p -m 644 build/lib/xbean.jar %{buildroot}%{_javadir}/xmlbeans/xbean-%{version}.jar

ln -s xmlpublic-%{version}.jar %{buildroot}%{_javadir}/xmlbeans/xmlpublic.jar
ln -s xbean_xpath-%{version}.jar %{buildroot}%{_javadir}/xmlbeans/xbean_xpath.jar
ln -s xmlbeans-qname-%{version}.jar %{buildroot}%{_javadir}/xmlbeans/xmlbeans-qname.jar
ln -s xbean-%{version}.jar %{buildroot}%{_javadir}/xmlbeans/xbean.jar

mkdir -p %{buildroot}%{_datadir}/xmlbeans-%{version}/xkit
cp -pr bin/*.cmd %{buildroot}%{_datadir}/xmlbeans-%{version}/xkit
rm -rf bin/*.cmd
mkdir -p %{buildroot}%{_bindir}
install -p -m 755 bin/* %{buildroot}%{_bindir}
mkdir -p %{buildroot}%{_javadocdir}/xmlbeans-%{version}
cp -pr build/docs/reference/* %{buildroot}%{_javadocdir}/xmlbeans-%{version}
ln -s xmlbeans-%{version} %{buildroot}%{_javadocdir}/xmlbeans
rm -rf build/docs/reference

mkdir -p %{buildroot}%{_docdir}/xmlbeans-%{version}
cp -pr build/docs/* %{buildroot}%{_docdir}/xmlbeans-%{version}
cp LICENSE.txt %{buildroot}%{_docdir}/xmlbeans-%{version}

[ "%{buildroot}" != / ] && rm -rf "%{buildroot}"

%doc LICENSE.txt NOTICE.txt README.txt

%files tools

%files manual

%files javadoc

* Fri Mar 25 2011 gil <puntogil@...> 2.4.0-5mamba
- rebuilt with java-gcj-compat support

* Wed Nov 24 2010 gil <puntogil@...> 2.4.0-4mamba
- rebuilt devel

* Fri Jan 22 2010 gil <puntogil@...> 2.4.0-3mamba
- rebuilt with java-saxon9

* Wed Mar 11 2009 gil <puntogil@...> 2.4.0-2mamba
- rebuilt with apache-DdlUtils

* Sun Feb 22 2009 gil <puntogil@...> 2.4.0-1mamba
- package created by autospec