Build with plexus-containers 1.5.4
This commit is contained in:
parent
3ab930dfeb
commit
2e681bcc9c
11
maven-plugin-testing-harness-AbstractMojoTestCase.patch
Normal file
11
maven-plugin-testing-harness-AbstractMojoTestCase.patch
Normal file
@ -0,0 +1,11 @@
|
||||
--- maven-plugin-testing-harness/src/main/java/org/apache/maven/plugin/testing/AbstractMojoTestCase.java.orig 2010-09-20 20:40:23.409198838 +0800
|
||||
+++ maven-plugin-testing-harness/src/main/java/org/apache/maven/plugin/testing/AbstractMojoTestCase.java 2010-09-20 20:41:24.184959518 +0800
|
||||
@@ -181,7 +181,7 @@
|
||||
|
||||
Mojo mojo = (Mojo) lookup( Mojo.ROLE, groupId + ":" + artifactId + ":" + version + ":" + goal );
|
||||
|
||||
- Log mojoLogger = new DefaultLog( getContainer().getLoggerManager().getLoggerForComponent( Mojo.ROLE ) );
|
||||
+ Log mojoLogger = new DefaultLog(((org.codehaus.plexus.MutablePlexusContainer)getContainer()).getLoggerManager().getLoggerForComponent( Mojo.ROLE ) );
|
||||
|
||||
mojo.setLog( mojoLogger );
|
||||
|
||||
11
maven-plugin-testing-harness-ArtifactStub.patch
Normal file
11
maven-plugin-testing-harness-ArtifactStub.patch
Normal file
@ -0,0 +1,11 @@
|
||||
--- maven-plugin-testing-harness/src/main/java/org/apache/maven/plugin/testing/stubs/ArtifactStub.java.orig 2010-09-17 17:22:42.971256182 +0800
|
||||
+++ maven-plugin-testing-harness/src/main/java/org/apache/maven/plugin/testing/stubs/ArtifactStub.java 2010-09-17 17:45:26.268003574 +0800
|
||||
@@ -497,4 +497,8 @@
|
||||
sb.append( getClassifier() );
|
||||
}
|
||||
}
|
||||
+
|
||||
+ public ArtifactMetadata getMetadata(Class metadataClass) {
|
||||
+ return null;
|
||||
+ }
|
||||
}
|
||||
13
maven-plugin-testing-harness-SilentLog.patch
Normal file
13
maven-plugin-testing-harness-SilentLog.patch
Normal file
@ -0,0 +1,13 @@
|
||||
--- maven-plugin-testing-harness/src/main/java/org/apache/maven/plugin/testing/SilentLog.java.orig 2010-09-17 17:21:00.628814598 +0800
|
||||
+++ maven-plugin-testing-harness/src/main/java/org/apache/maven/plugin/testing/SilentLog.java 2010-09-17 17:22:11.113099358 +0800
|
||||
@@ -325,4 +325,10 @@
|
||||
{
|
||||
return null;
|
||||
}
|
||||
+
|
||||
+ public void setThreshold( int currentThreshold )
|
||||
+ {
|
||||
+ //this.currentThreshold = currentThreshold;
|
||||
+ }
|
||||
+
|
||||
}
|
||||
19
maven-plugin-testing-harness-pom.patch
Normal file
19
maven-plugin-testing-harness-pom.patch
Normal file
@ -0,0 +1,19 @@
|
||||
--- maven-plugin-testing-harness/pom.xml.orig 2010-09-20 20:09:03.589974798 +0800
|
||||
+++ maven-plugin-testing-harness/pom.xml 2010-09-20 20:11:27.724063086 +0800
|
||||
@@ -34,6 +34,16 @@
|
||||
<!-- maven -->
|
||||
<dependency>
|
||||
<groupId>org.apache.maven</groupId>
|
||||
+ <artifactId>maven-artifact</artifactId>
|
||||
+ <version>2.0.6</version>
|
||||
+ </dependency>
|
||||
+ <dependency>
|
||||
+ <groupId>org.codehaus.plexus</groupId>
|
||||
+ <artifactId>plexus-container-default</artifactId>
|
||||
+ <version>1.5.4</version>
|
||||
+ </dependency>
|
||||
+ <dependency>
|
||||
+ <groupId>org.apache.maven</groupId>
|
||||
<artifactId>maven-project</artifactId>
|
||||
<version>2.0</version>
|
||||
</dependency>
|
||||
13
maven-plugin-testing-pom.patch
Normal file
13
maven-plugin-testing-pom.patch
Normal file
@ -0,0 +1,13 @@
|
||||
--- pom.xml.orig 2010-09-15 16:37:56.940616245 +0800
|
||||
+++ pom.xml 2010-09-15 16:38:51.049390461 +0800
|
||||
@@ -173,5 +173,10 @@
|
||||
<artifactId>junit</artifactId>
|
||||
<version>3.8.2</version>
|
||||
</dependency>
|
||||
+ <dependency>
|
||||
+ <groupId>org.apache.maven.wagon</groupId>
|
||||
+ <artifactId>wagon-provider-api</artifactId>
|
||||
+ <version>2.0.4</version>
|
||||
+ </dependency>
|
||||
</dependencies>
|
||||
</project>
|
||||
@ -1,6 +1,6 @@
|
||||
Name: maven-plugin-testing
|
||||
Version: 1.2
|
||||
Release: 6%{?dist}
|
||||
Release: 7%{?dist}
|
||||
Summary: Maven Plugin Testing
|
||||
|
||||
Group: Development/Libraries
|
||||
@ -10,6 +10,13 @@ URL: http://maven.apache.org/plugin-testing/
|
||||
#tar caf maven-plugin-testing-1.2 maven-plugin-testing-1.2/
|
||||
Source0: %{name}-%{version}.tar.xz
|
||||
Source1: %{name}-depmap.xml
|
||||
Patch0: %{name}-pom.patch
|
||||
|
||||
# patch for building with plexus-containers 1.5.4
|
||||
Patch1: maven-plugin-testing-harness-SilentLog.patch
|
||||
Patch2: maven-plugin-testing-harness-ArtifactStub.patch
|
||||
Patch3: maven-plugin-testing-harness-AbstractMojoTestCase.patch
|
||||
|
||||
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
|
||||
|
||||
BuildArch: noarch
|
||||
@ -21,6 +28,7 @@ BuildRequires: maven2-plugin-compiler
|
||||
BuildRequires: maven2-plugin-resources
|
||||
BuildRequires: maven2-plugin-jar
|
||||
BuildRequires: maven2-plugin-source
|
||||
BuildRequires: maven2-plugin-site
|
||||
BuildRequires: plexus-maven-plugin
|
||||
BuildRequires: maven-javadoc-plugin
|
||||
BuildRequires: maven-doxia-sitetools
|
||||
@ -28,6 +36,7 @@ BuildRequires: maven-surefire-maven-plugin
|
||||
BuildRequires: maven-surefire-provider-junit
|
||||
BuildRequires: maven-shared-reporting-impl
|
||||
BuildRequires: maven-shared-test-tools
|
||||
|
||||
Requires: maven2
|
||||
Requires: jpackage-utils
|
||||
Requires: java
|
||||
@ -79,6 +88,10 @@ Framework to test Maven Plugins with Easymock objects.
|
||||
%prep
|
||||
%setup -q #You may need to update this according to your Source0
|
||||
rm -fr src/site/site.xml
|
||||
%patch0 -b .sav0
|
||||
%patch1 -b .sav1
|
||||
%patch2 -b .sav2
|
||||
%patch3 -b .sav3
|
||||
|
||||
%build
|
||||
export MAVEN_REPO_LOCAL=$(pwd)/.m2/repository
|
||||
@ -88,7 +101,7 @@ mvn-jpp \
|
||||
-Dmaven.repo.local=$MAVEN_REPO_LOCAL \
|
||||
-Dmaven2.jpp.depmap.file=%{SOURCE1} \
|
||||
-Dmaven.test.skip=true \
|
||||
install javadoc:javadoc
|
||||
install javadoc:aggregate
|
||||
#tests are skipped due to some test failures most probably caused by issues with our plexus container
|
||||
|
||||
%install
|
||||
@ -122,15 +135,13 @@ install -pm 644 maven-test-tools/pom.xml %{buildroot}%{_mavenpomdir}/JPP.%{name}
|
||||
%add_to_maven_depmap org.apache.maven.shared maven-test-tools %{version} JPP/%{name} maven-test-tools
|
||||
|
||||
# javadoc
|
||||
install -d -m 0755 %{buildroot}%{_javadocdir}/%{name}
|
||||
install -d -m 0755 %{buildroot}%{_javadocdir}/%{name}/%{name}-harness
|
||||
install -d -m 0755 %{buildroot}%{_javadocdir}/%{name}/%{name}-tools
|
||||
install -d -m 0755 %{buildroot}%{_javadocdir}/%{name}/maven-test-tools
|
||||
install -d -m 755 $RPM_BUILD_ROOT%{_javadocdir}/%{name}-%{version}
|
||||
cp -pr target/site/apidocs/* \
|
||||
$RPM_BUILD_ROOT%{_javadocdir}/%{name}-%{version}/
|
||||
|
||||
cp -pr %{name}-harness/target/site/api*/* %{buildroot}%{_javadocdir}/%{name}/%{name}-harness
|
||||
cp -pr %{name}-tools/target/site/api*/* %{buildroot}%{_javadocdir}/%{name}/%{name}-tools
|
||||
cp -pr maven-test-tools/target/site/api*/* %{buildroot}%{_javadocdir}/%{name}/maven-test-tools
|
||||
ln -s %{name}-%{version} $RPM_BUILD_ROOT%{_javadocdir}/%{name}
|
||||
|
||||
ls -lR $RPM_BUILD_ROOT
|
||||
|
||||
%post
|
||||
%update_maven_depmap
|
||||
@ -149,7 +160,7 @@ rm -rf %{buildroot}
|
||||
|
||||
%files javadoc
|
||||
%defattr(-,root,root,-)
|
||||
%{_javadocdir}/%{name}
|
||||
%{_javadocdir}/*
|
||||
|
||||
%files harness
|
||||
%defattr(-,root,root,-)
|
||||
@ -164,6 +175,9 @@ rm -rf %{buildroot}
|
||||
%{_javadir}/%{name}/maven-test-tools*
|
||||
|
||||
%changelog
|
||||
* Mon Sep 20 2010 Yong Yang <yyang@redhat.com> 1.1-7
|
||||
- Build with plexus-containers 1.5.4
|
||||
|
||||
* Mon May 31 2010 Alexander Kurtakov <akurtako@redhat.com> 1.2-6
|
||||
- Proper obsolete for maven-shared-test-tools.
|
||||
|
||||
|
||||
Loading…
Reference in New Issue
Block a user