Author: pawelz                       Date: Thu Apr  1 10:34:52 2010 GMT
Module: packages                      Tag: HEAD
---- Log message:
- renamed from xmlunit
- up to 1.3
- disabled doc, see TODO
- pldized/adapterized/unified/standarized/beautified/etc

---- Files affected:
packages/java-xmlunit:
   java-xmlunit.spec (1.9 -> 1.10) 

---- Diffs:

================================================================
Index: packages/java-xmlunit/java-xmlunit.spec
diff -u packages/java-xmlunit/java-xmlunit.spec:1.9 
packages/java-xmlunit/java-xmlunit.spec:1.10
--- packages/java-xmlunit/java-xmlunit.spec:1.9 Mon Feb 12 23:09:23 2007
+++ packages/java-xmlunit/java-xmlunit.spec     Thu Apr  1 12:34:47 2010
@@ -1,71 +1,127 @@
 # $Revision$, $Date$
+# TODO
+# - docs are broken. html docs seem to be incompatibile with our
+#   docbook-style-xsl. Does it require earlier version? pdf docs require
+#   dblatex command. I have no idea what it is and what should provide it.
+
+%bcond_with    doc             # build docs. Does not work.
+
+%if "%{pld_release}" == "ti"
+%bcond_without java_sun        # build with gcj
+%else
+%bcond_with    java_sun        # build with java-sun
+%endif
+#
+%include       /usr/lib/rpm/macros.java
+
+%define                srcname xmlunit
 Summary:       XMLUnit - extend JUnit and NUnit to enable unit testing of XML
 Summary(pl.UTF-8):     XMLUnit - rozszerzenie JUnita i NUnita o testowanie 
jednostkowe XML-a
-Name:          xmlunit
-Version:       1.0
+Name:          java-xmlunit
+Version:       1.3
 Release:       1
 License:       BSD
 Group:         Libraries
-Source0:       http://dl.sourceforge.net/xmlunit/%{name}%{version}.zip
-# Source0-md5: 4f03206acc9ed18bc6cc23fd38b4fc82
+Source0:       
http://downloads.sourceforge.net/project/xmlunit/xmlunit%20for%20Java/XMLUnit%20for%20Java%201.3/xmlunit-%{version}-src.zip
+# Source0-md5: 8b23f360367f18f393559dc2f0640dbe
 URL:           http://xmlunit.sourceforge.net/
 BuildRequires: ant >= 1.5
+%{!?with_java_sun:BuildRequires:       java-gcj-compat-devel}
+%{?with_java_sun:BuildRequires:        java-sun}
 BuildRequires: jaxp_parser_impl
 BuildRequires: jaxp_transform_impl
 BuildRequires: jpackage-utils
 BuildRequires: junit
+BuildRequires: rpm >= 4.4.9-56
 BuildRequires: rpmbuild(macros) >= 1.300
 Requires:      jaxp_parser_impl
 Requires:      jaxp_transform_impl
 Requires:      junit
 BuildArch:     noarch
-ExclusiveArch: i586 i686 pentium3 pentium4 athlon %{x8664} noarch
 BuildRoot:     %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
 
 %description
-XMLUnit extends JUnit and NUnit to enable unit testing of XML. It
-compares a control XML document to a test document or the result of a
+XMLUnit extends JUnit to enable unit testing of XML. It compares a
+control XML document to a test document or the result of a
 transformation, validates documents, and compares the results of XPath
 expressions.
 
 %description -l pl.UTF-8
-XMLUnit rozszerza JUnita i NUnita o możliwość testowania jednostkowego
-XML-a. Porównuje kontrolny dokument XML z dokumentem testowym lub
-wynikiem przekształcenia, sprawdza poprawność dokumentów i porównuje
-wyniki wyrażeń XPath.
+XMLUnit rozszerza JUnit o możliwość testowania jednostkowego XML-a.
+Porównuje kontrolny dokument XML z dokumentem testowym lub wynikiem
+przekształcenia, sprawdza poprawność dokumentów i porównuje wyniki
+wyrażeń XPath.
+
+%package javadoc
+Summary:       Online manual for %{name}
+Summary(pl.UTF-8):     Dokumentacja online do %{name}
+Group:         Documentation
+Requires:      jpackage-utils
+
+%description javadoc
+Documentation for %{name}.
+
+%description javadoc -l pl.UTF-8
+Dokumentacja do %{name}.
+
+%description javadoc -l fr.UTF-8
+Javadoc pour %{name}.
 
 %prep
-%setup -q -n %{name}
+%setup -q -n %{srcname}-%{version}
 
 %build
 required_jars='jaxp_parser_impl jaxp_transform_impl junit'
-export CLASSPATH="$CLASSPATH:`/usr/bin/build-classpath $required_jars`"
+CLASSPATH="$CLASSPATH:$(%{_bindir}/build-classpath $required_jars)"
 export JAVAC=%{javac}
 export JAVA=%{java}
 
-%ant
+%ant %{?with_doc:users-guide-html} %{?with_doc:users-guide-pdf} javadocs test 
jar
 
 %install
 rm -rf $RPM_BUILD_ROOT
 install -d $RPM_BUILD_ROOT%{_javadir}
 
-install lib/%{name}%{version}.jar $RPM_BUILD_ROOT%{_javadir}
-ln -s       %{name}%{version}.jar $RPM_BUILD_ROOT%{_javadir}/%{name}.jar
+install build/lib/%{srcname}-%{version}.jar 
$RPM_BUILD_ROOT%{_javadir}/%{srcname}-%{version}.jar
+ln -s %{srcname}-%{version}.jar $RPM_BUILD_ROOT%{_javadir}/%{srcname}.jar
+
+# javadoc
+%if %{with javadoc}
+install -d $RPM_BUILD_ROOT%{_javadocdir}/%{srcname}-%{version}
+cp -a dist/docs/api/* $RPM_BUILD_ROOT%{_javadocdir}/%{srcname}-%{version}
+ln -s %{srcname}-%{version} $RPM_BUILD_ROOT%{_javadocdir}/%{srcname} # ghost 
symlink
+%endif
 
 %clean
 rm -rf $RPM_BUILD_ROOT
 
+%post javadoc
+ln -nfs %{srcname}-%{version} %{_javadocdir}/%{srcname}
+
 %files
 %defattr(644,root,root,755)
-%doc README* *.html *.pdf LICENSE.txt
+%doc README* LICENSE.txt
 %{_javadir}/*.jar
 
+%if %{with javadoc}
+%files javadoc
+%defattr(644,root,root,755)
+%{_javadocdir}/%{srcname}-%{version}
+%ghost %{_javadocdir}/%{srcname}
+%endif
+
 %define date   %(echo `LC_ALL="C" date +"%a %b %d %Y"`)
 %changelog
 * %{date} PLD Team <[email protected]>
 All persons listed below can be reached at <cvs_login>@pld-linux.org
 
 $Log$
+Revision 1.10  2010/04/01 10:34:47  pawelz
+- renamed from xmlunit
+- up to 1.3
+- disabled doc, see TODO
+- pldized/adapterized/unified/standarized/beautified/etc
+
 Revision 1.9  2007/02/12 22:09:23  glen
 - tabs in preamble
 
================================================================

---- CVS-web:
    
http://cvs.pld-linux.org/cgi-bin/cvsweb.cgi/packages/java-xmlunit/java-xmlunit.spec?r1=1.9&r2=1.10&f=u

_______________________________________________
pld-cvs-commit mailing list
[email protected]
http://lists.pld-linux.org/mailman/listinfo/pld-cvs-commit

Reply via email to