packages java-google-safesax.spec
      Pages: < 1 >  DOWNLOAD      
Name:          java-google-safesax
Version:       0
Release:       2mamba
Summary:       Wraps SAX to protect you against bugs, bad performance, and boilerplate code
Group:         Development/Libraries/Java
Vendor:        openmamba
Distribution:  openmamba
Packager:      gil <puntogil@...>
URL:           http://code.google.com/p/google-safesax/
# svn export http://google-safesax.googlecode.com/svn/trunk safesax
# tar czf safesax-0-src-svn.tar.gz safesax
Source0:       safesax-%{version}-src-svn.tar.gz
Patch0:        java-google-safesax-0-crosslink.patch
License:       Apache Software License Version 2.0
BuildRequires: apache-ant
BuildRequires: java-junit3
BuildRequires: sun-java-javadoc
BuildRequires: jpackage-utils
Requires:      jpackage-utils
BuildRoot:     %{_tmppath}/%{name}-%{version}-root

%description
SafeSax is highly optimized and appropriate for embedded devices with SAX support.
Despite adding a layer of abstraction, SafeSax performs as well as (or better than)
hand tuned SAX handlers. Compared to raw SAX, SafeSax makes common tasks like
retrieving the body of an element fast and easy.

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

%description javadoc
Wraps SAX to protect you against bugs, bad performance, and boilerplate code.

This package contains documentation for %{name}.

%prep

%setup -q -n safesax

%patch0

for j in $(find . -name "*.jar"); do
       mv $j $j.no
done

ln -sf $(build-classpath objenesis junit-3.8.2) lib/junit.jar

%build

ant \
	-Dversion=%{version} \
	-Djavase.api=%{_javadocdir}/java \
	jar javadoc

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

mkdir -p %{buildroot}%{_javadir}

install -m 644 build/safesax-%{version}.jar \
	%{buildroot}%{_javadir}/google-safesax-%{version}.jar


(
	cd %{buildroot}%{_javadir}
	for jar in *-%{version}.jar; do
		ln -sf ${jar} `echo $jar| sed "s|google-||g"`
	done
)


(
	cd %{buildroot}%{_javadir}
	for jar in *-%{version}.jar; do
		ln -sf ${jar} `echo $jar| sed "s|-%{version}||g"`
	done
)

mkdir -p %{buildroot}%{_javadocdir}/google-safesax-%{version}
cp -pr build/javadoc/* %{buildroot}%{_javadocdir}/google-safesax-%{version}
ln -s google-safesax-%{version} %{buildroot}%{_javadocdir}/google-safesax


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

%files
%defattr(-,root,root)
%{_javadir}/google-safesax-%{version}.jar
%{_javadir}/google-safesax.jar
%{_javadir}/safesax-%{version}.jar
%{_javadir}/safesax.jar

%files javadoc
%defattr(-,root,root)
%{_javadocdir}/google-safesax-%{version}
%{_javadocdir}/google-safesax

%changelog
* Wed Dec 15 2010 gil <puntogil@...> 0-2mamba
- rebuilt devel

* Sun Nov 14 2010 gil <puntogil@...> 0-1mamba
- package created by autospec