[ehcache-core/f18] disable embedded ehcache-sizeof-agent.jar copy, switch to pom macros

gil gil at fedoraproject.org
Mon Jun 24 13:15:06 UTC 2013


commit 5055a292e6aba9e550e067fb983db22db76f5ddc
Author: gil <puntogil at libero.it>
Date:   Mon Jun 24 15:14:49 2013 +0200

    disable embedded ehcache-sizeof-agent.jar copy, switch to pom macros

 ehcache-core.spec |   78 ++++++++++++++++++++++++++++++++--------------------
 1 files changed, 48 insertions(+), 30 deletions(-)
---
diff --git a/ehcache-core.spec b/ehcache-core.spec
index cf10773..ff7a498 100644
--- a/ehcache-core.spec
+++ b/ehcache-core.spec
@@ -1,6 +1,6 @@
 Name:          ehcache-core
 Version:       2.6.0
-Release:       2%{?dist}
+Release:       3%{?dist}
 Summary:       Easy Hibernate Cache
 Group:         Development/Libraries
 License:       ASL 2.0
@@ -11,19 +11,6 @@ URL:           http://ehcache.org/
 # find ehcache-core-2.6.0 -name '*.class' -delete
 # tar czf ehcache-core-2.6.0-clean-src-svn.tar.gz ehcache-core-2.6.0
 Source0:       %{name}-%{version}-clean-src-svn.tar.gz
-# force use tomcat 7.x apis
-Source1:       %{name}-%{version}-depmap
-# remove gmaven-plugin maven-checkstyle-plugin
-# fix java.vendor
-# add servlet-api version
-Patch0:        %{name}-%{version}-pom.patch
-# Don't use buildnumber-plugin, because jna is required (and currently broken)
-Patch1:        %{name}-%{version}-disable-buildnumber-plugin.patch
-# circular deps
-# org.hibernate hibernate-ehcache 3.3.2.GA
-# unavailable deps
-# net.sf.hibernate hibernate
-Patch2:        %{name}-%{version}-remove-unavailable-test-deps.patch
 
 BuildRequires: ehcache-parent
 BuildRequires: java-devel
@@ -35,18 +22,21 @@ BuildRequires: ehcache-sizeof-agent
 BuildRequires: slf4j
 BuildRequires: tomcat-servlet-3.0-api
 
-# TODO test
-#BuildRequires: apache-commons-logging
-#BuildRequires: mvn(org.hibernate:hibernate-ehcache)
-#BuildRequires: bsh
-#BuildRequires: btm
-#BuildRequires: derby
-#BuildRequires: dom4j
-#BuildRequires: hamcrest12
-#BuildRequires: javassist
-#BuildRequires: junit4
-#BuildRequires: mockito
-#BuildRequires: xsom
+# test
+%if 0
+BuildRequires: apache-commons-logging
+BuildRequires: mvn(net.sf.hibernate:hibernate) >= 2.1.8
+BuildRequires: mvn(org.hibernate:hibernate-ehcache)
+BuildRequires: bsh
+BuildRequires: btm
+BuildRequires: derby
+BuildRequires: dom4j
+BuildRequires: hamcrest12
+BuildRequires: javassist
+BuildRequires: junit
+BuildRequires: mockito
+BuildRequires: xsom
+%endif
 
 BuildRequires: maven
 BuildRequires: maven-assembly-plugin
@@ -85,14 +75,38 @@ This package contains javadoc for %{name}.
 
 %prep
 %setup -q
-%patch0 -p0
-%patch1 -p0
-%patch2 -p0
+
+%pom_remove_plugin org.codehaus.gmaven:gmaven-plugin
+%pom_remove_plugin org.eclipse.m2e:lifecycle-mapping
+%pom_remove_plugin org.apache.maven.plugins:maven-checkstyle-plugin
+
+# don't generate source archive
+%pom_remove_plugin :maven-assembly-plugin
+
+%pom_xpath_remove "pom:profile[pom:id='no-interruptible-io-solaris']/pom:activation/pom:property/pom:value"
+%pom_xpath_inject "pom:profile[pom:id='no-interruptible-io-solaris']/pom:activation/pom:property" "
+<value>Oracle Corporation</value>"
+
+# Make sure we require version '3' of Hibernate
+%pom_xpath_remove "pom:dependencies/pom:dependency[pom:groupId = 'org.hibernate']/pom:version"
+%pom_xpath_inject "pom:dependencies/pom:dependency[pom:groupId = 'org.hibernate']" "<version>3</version>"
+
+# Don't use buildnumber-plugin, because jna is required (and currently broken)
+%pom_xpath_remove "pom:profiles/pom:profile[pom:id = 'buildnumber-git']"
+
+# circular deps
+# org.hibernate hibernate-ehcache 3.3.2.GA
+# unavailable deps
+%pom_remove_dep net.sf.hibernate:hibernate
+%pom_xpath_remove "pom:dependencies/pom:dependency[pom:scope = 'test']"
+
+# disable embedded ehcache-sizeof-agent.jar copy
+%pom_remove_plugin :maven-dependency-plugin
 
 %build
 
 # tests skipped. cause: missing dependencies
-mvn-rpmbuild -X -Dmaven.local.depmap.file="%{SOURCE1}" -Dmaven.test.skip=true install javadoc:aggregate
+mvn-rpmbuild -X -Dmaven.local.depmap.file="%{_mavendepmapfragdir}/tomcat-tomcat-servlet-api" -Dmaven.test.skip=true install javadoc:aggregate
 
 %install
 
@@ -117,6 +131,10 @@ cp -rp target/site/apidocs/* %{buildroot}%{_javadocdir}/%{name}
 %doc src/assemble/EHCACHE-CORE-LICENSE.txt
 
 %changelog
+* Mon Jun 24 2013 gil cattaneo <puntogil at libero.it> - 2.6.0-3
+- disable embedded ehcache-sizeof-agent.jar copy
+- switch to pom macros
+
 * Wed Jul 18 2012 Fedora Release Engineering <rel-eng at lists.fedoraproject.org> - 2.6.0-2
 - Rebuilt for https://fedoraproject.org/wiki/Fedora_18_Mass_Rebuild
 


More information about the scm-commits mailing list