diff --git a/stringtemplate-3.1-build-junit.patch b/stringtemplate-3.1-build-junit.patch index 2ae1972..a4d3ef7 100644 --- a/stringtemplate-3.1-build-junit.patch +++ b/stringtemplate-3.1-build-junit.patch @@ -1,6 +1,23 @@ ---- stringtemplate-3.1.orig/build.xml 2008-01-23 21:24:06.000000000 -0500 -+++ stringtemplate-3.1/build.xml 2008-04-04 18:54:46.000000000 -0400 -@@ -235,7 +235,22 @@ +--- build.xml.orig 2009-09-22 23:00:17.000000000 +0200 ++++ build.xml 2010-01-29 03:34:13.000000000 +0100 +@@ -94,6 +94,7 @@ + + + ++ + + + +@@ -110,7 +111,7 @@ + + + +- ++ + + + +@@ -239,7 +240,22 @@ diff --git a/stringtemplate-3.1-disable-broken-test.patch b/stringtemplate-3.1-disable-broken-test.patch deleted file mode 100644 index 3b382a3..0000000 --- a/stringtemplate-3.1-disable-broken-test.patch +++ /dev/null @@ -1,69 +0,0 @@ ---- stringtemplate-3.1.orig/src/org/antlr/stringtemplate/test/TestStringTemplate.java 2008-01-23 21:24:06.000000000 -0500 -+++ stringtemplate-3.1/src/org/antlr/stringtemplate/test/TestStringTemplate.java 2008-04-04 19:29:06.000000000 -0400 -@@ -2227,6 +2227,9 @@ - assertEquals("Terence", buf.toString()); - } - -+ // These three tests depend on the ordering of values returned from maps. -+ // Disabling them. --walters, 2008-04-04 -+ /* - public void testApplyAnonymousTemplateToMapAndSet() throws Exception { - StringTemplate st = - new StringTemplate("$items:{
  • $it$
  • }$"); -@@ -2288,6 +2291,7 @@ - expecting = "
  • 1
  • 2
  • "; - assertEquals(expecting, st.toString()); - } -+ */ - - public void testSuperTemplateRef() - throws Exception -@@ -3839,6 +3843,7 @@ - * - * Maybe make a RestIterator like I have CatIterator. - */ -+ /* - public void testRepeatedRestOpAsArg() throws Exception { - String templates = - "group test;" +newline+ -@@ -3854,6 +3859,7 @@ - String expecting = "Tom, Tom"; - assertEquals(expecting, e.toString()); - } -+ */ - - public void testIncomingLists() throws Exception { - StringTemplate e = new StringTemplate( -@@ -4030,6 +4036,8 @@ - assertEquals(expecting, e.toString()); - } - -+ /* This looks like a legitimate failure? -+ - public void testFirstWithListOfMaps2() throws Exception { - StringTemplate e = new StringTemplate( - "$first(maps):{ $it.Ter$ }$" -@@ -4050,6 +4058,7 @@ - expecting = "x5707"; - assertEquals(expecting, e.toString()); - } -+ */ - - public void testJustCat() throws Exception { - StringTemplate e = new StringTemplate( -@@ -5212,6 +5221,7 @@ - *

    - * Bug ref: JIRA bug ST-2 - */ -+ /* - public void testGroupTrailingSemiColon() throws Exception { - //try { - String templates = -@@ -5232,6 +5242,7 @@ - //} catch (ParseError??) { - //} - } -+ */ - - public void testSuperReferenceInIfClause() throws Exception { - String superGroupString = diff --git a/stringtemplate.spec b/stringtemplate.spec index c4994bb..a936917 100644 --- a/stringtemplate.spec +++ b/stringtemplate.spec @@ -1,17 +1,17 @@ Summary: A Java template engine Name: stringtemplate -Version: 3.1 -Release: 3%{?dist} +Version: 3.2.1 +Release: 1%{?dist} URL: http://www.stringtemplate.org/ -Source0: http://www.stringtemplate.org/download/stringtemplate-3.1.tar.gz -# Both patches emailed to upstream 20080404 +Source0: http://www.stringtemplate.org/download/stringtemplate-%{version}.tar.gz +# Build jUnit tests + make the antlr2 generated code before preparing sources Patch0: stringtemplate-3.1-build-junit.patch -Patch1: stringtemplate-3.1-disable-broken-test.patch License: BSD Group: Development/Libraries BuildArch: noarch BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n) BuildRequires: ant-antlr, ant-junit +BuildRequires: antlr # Standard deps BuildRequires: java-devel >= 1:1.6.0 BuildRequires: jpackage-utils @@ -35,11 +35,10 @@ API documentation for %{name}. %prep %setup -q -%patch0 -p1 -%patch1 -p1 +%patch0 %build -rm -f lib/*.jar +rm -rf lib target ant jar ant javadocs -Dpackages= -Djavadocs.additionalparam= @@ -50,9 +49,18 @@ install -D build/stringtemplate.jar $RPM_BUILD_ROOT%{_datadir}/java/stringtempla install -dm 755 $RPM_BUILD_ROOT%{_javadocdir}/%{name} cp -pR docs/api/* $RPM_BUILD_ROOT%{_javadocdir}/%{name} +install -Dpm 644 pom.xml $RPM_BUILD_ROOT%{_mavenpomdir}/JPP-%{name}.pom +%add_to_maven_depmap org.antlr %{name} %{version} JPP %{name} + %clean rm -rf $RPM_BUILD_ROOT +%post +%update_maven_depmap + +%postun +%update_maven_depmap + %check ant test @@ -60,12 +68,19 @@ ant test %defattr(-,root,root) %doc LICENSE.txt README.txt %{_datadir}/java/*.jar +%{_mavenpomdir}/JPP-%{name}.pom +%config(noreplace) %{_mavendepmapfragdir}/%{name} %files javadoc %defattr(-,root,root) %{_javadocdir}/%{name} %changelog +* Fri Jan 29 2010 Miloš Jakubíček - 3.2.1-1 +- Update to 3.2.1 +- Supply maven POM files +- Drop stringtemplate-3.1-disable-broken-test.patch (merged upstream) + * Sun Jul 26 2009 Fedora Release Engineering - 3.1-3 - Rebuilt for https://fedoraproject.org/wiki/Fedora_12_Mass_Rebuild