2 # - generate docs without using forrest. It seems to be possible.
5 %bcond_with docs # build with docs (require apache-forrest)
7 Summary: Java SVG support
8 Summary(pl.UTF-8): Wsparcie dla SVG dla języka Java
13 Group: Applications/Publishing/XML/Java
14 Source0: http://www.apache.org/dist/xmlgraphics/batik/%{name}-src-%{version}.zip
15 # Source0-md5: c117ca2241907f62a2b3031167ebf917
16 Patch0: %{name}-nodocs.patch
17 URL: http://xml.apache.org/batik/
18 %{?with_docs:BuildRequires: apache-forrest}
20 BuildRequires: jpackage-utils
24 BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
26 %define _javaclassdir %{_libdir}/java
31 %description -l pl.UTF-8
32 Wsparcie dla SVG dla języka Java.
35 Summary: Documentation for the Batik library
36 Summary(pl.UTF-8): Dokumentacja dla biblioteki Batik
40 Documentation for the Batik library.
42 %description doc -l pl.UTF-8
43 Dokumentacja dla biblioteki Batik.
54 export JAVA_HOME="%{java_home}"
56 #sh build.sh dist-tgz # does not work :-(
60 rm -rf $RPM_BUILD_ROOT
61 install -d $RPM_BUILD_ROOT%{_javaclassdir}/%{name}/lib
63 install %{name}-%{version}/lib/*.jar $RPM_BUILD_ROOT%{_javaclassdir}/%{name}/lib
64 install %{name}-%{version}/*.jar $RPM_BUILD_ROOT%{_javaclassdir}/%{name}
67 rm -rf $RPM_BUILD_ROOT
70 %defattr(644,root,root,755)
72 %dir %{_javaclassdir}/%{name}
73 %{_javaclassdir}/%{name}/*.jar
74 %dir %{_javaclassdir}/%{name}/lib
75 %{_javaclassdir}/%{name}/lib/*.jar
79 %defattr(644,root,root,755)
80 %doc %{name}-%{version}/docs/* %{name}-%{version}/samples