packages apache-xml-stylebook.spec
      Pages: < 1 >  DOWNLOAD      
%define javahome /usr/lib/jvm/jdk-gcj
Name:          apache-xml-stylebook
Version:       1.0
Release:       4mamba
Summary:       Apache XML Stylebook
Group:         Applications/Publishing
Vendor:        openmamba
Distribution:  openmamba
Packager:      gil <puntogil@...>
#svn export xml-stylebook-1.0
# tar cjf xml-stylebook-1.0-r313293-src.tar.bz2 xml-stylebook-1.0
Source:        xml-stylebook-%{version}-r313293-src.tar.bz2
# from JPackage
Patch0:        apache-xml-stylebook-1.0-r313293-image-printer.patch
Patch1:        apache-xml-stylebook-1.0-r313293-build-javadoc.patch
License:       Apache Software License 2.0
BuildRequires: apache-ant
BuildRequires: apache-ant-junit
BuildRequires: jakarta-bsf
BuildRequires: java-gcj-compat
BuildRequires: java-junit48
BuildRequires: java-openjdk
BuildRequires: jpackage-utils
BuildRequires: xalan-j2
BuildRequires: xerces-j2
BuildRequires: xml-commons-apis
Requires:      xml-commons-apis
Requires:      xalan-j2
Obsoletes:     java-xml-stylebook
Provides:      java-xml-stylebook
BuildRoot:     %{_tmppath}/%{name}-%{version}-root

Apache XML Stylebook.

%package javadoc
Group:         Documentation
Summary:       Javadoc for %{name}
Requires:      sun-java-javadoc

%description javadoc
Apache XML Stylebook.

This package contains javadoc for %{name}.

%package demo
Group:         Development/Libraries/Java
Summary:       Examples for %{name}
Requires:      %{name} = %{?epoch:%epoch:}%{version}-%{release}

%description demo
Apache XML Stylebook.

This package contains examples demonstrating the use of %{name}.


%setup -q -n xml-stylebook-%{version}
%patch0 -p0
%patch1 -p0

# contains an errant font
rm -r styles/christmas/

for j in $(find . -name "*.jar"); do
     rm -rf $j

export JAVA_HOME=%javahome
export CLASSPATH=$(build-classpath xalan-j2 xerces-j2 xml-commons-apis bsf junit48 ant/ant-junit)

pushd docs
rm run.bat
java -classpath $(build-classpath xalan-j2 xerces-j2 xml-commons-apis bsf junit48 ant/ant-junit):../bin/stylebook-%{version}-b3_xalan-2.jar \
  org.apache.stylebook.StyleBook "targetDirectory=../results" book.xml ../styles/apachexml

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

mkdir -p %{buildroot}%{_javadir}
install -m 644  bin/stylebook-%{version}-b3_xalan-2.jar \

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

mkdir -p %{buildroot}%{_javadocdir}/xml-stylebook-%{version}
cp -pr build/javadoc/* %{buildroot}%{_javadocdir}/xml-stylebook-%{version}
ln -sf xml-stylebook-%{version} %{buildroot}%{_javadocdir}/xml-stylebook

mkdir -p %{buildroot}%{_datadir}/xml-stylebook
cp -pr docs %{buildroot}%{_datadir}/xml-stylebook
cp -pr styles %{buildroot}%{_datadir}/xml-stylebook
cp -pr results %{buildroot}%{_datadir}/xml-stylebook

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

%doc LICENSE.txt

%files javadoc

%files demo

* Mon Mar 14 2011 gil <puntogil@...> 1.0-4mamba
- rebuilt with java-gcj-compat & java-openjdk support

* Wed Dec 22 2010 gil <puntogil@...> 1.0-3mamba
- update to 1.0-r313293

* Thu Nov 04 2010 gil <puntogil@...> 1.0-2mamba
- rebuilt devel

* Fri Mar 06 2009 gil <puntogil@...> 1.0-1mamba
- package created by autospec