From c58fe5076b8b0964c150e7a0028d513ac007512b Mon Sep 17 00:00:00 2001 From: Hui Wang Date: Wed, 19 May 2010 03:48:13 +0000 Subject: [PATCH] - Cvs import --- .cvsignore | 1 + import.log | 1 + maven-resources-plugin.spec | 106 ++++++++++++++++++++++++++++++++++++ sources | 1 + 4 files changed, 109 insertions(+) create mode 100644 import.log create mode 100644 maven-resources-plugin.spec diff --git a/.cvsignore b/.cvsignore index e69de29..f857c14 100644 --- a/.cvsignore +++ b/.cvsignore @@ -0,0 +1 @@ +maven-resources-plugin-2.2.tar.gz diff --git a/import.log b/import.log new file mode 100644 index 0000000..a35c6a5 --- /dev/null +++ b/import.log @@ -0,0 +1 @@ +maven-resources-plugin-2_2-2:HEAD:maven-resources-plugin-2.2-2.src.rpm:1274239409 diff --git a/maven-resources-plugin.spec b/maven-resources-plugin.spec new file mode 100644 index 0000000..1721e39 --- /dev/null +++ b/maven-resources-plugin.spec @@ -0,0 +1,106 @@ +Name: maven-resources-plugin +Version: 2.2 +Release: 2%{?dist} +Summary: Maven Resources Plugin + +Group: Development/Libraries +License: ASL 2.0 +URL: http://maven.apache.org/plugins/maven-resources-plugin +#svn export http://svn.apache.org/repos/asf/maven/plugins/tags/maven-resources-plugin-2.2 maven-resources-plugin-2.2 +#tar zcf maven-resources-plugin-2.2.tar.gz maven-resources-plugin-2.2/ +Source0: %{name}-%{version}.tar.gz +BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n) + +BuildArch: noarch + +BuildRequires: java-devel >= 1:1.6.0 +BuildRequires: maven2 +BuildRequires: maven2-plugin-plugin +BuildRequires: maven2-plugin-compiler +BuildRequires: maven2-plugin-jar +BuildRequires: maven2-plugin-install +BuildRequires: maven2-plugin-resources +BuildRequires: maven2-plugin-javadoc +BuildRequires: maven-surefire-maven-plugin +BuildRequires: maven-surefire-provider-junit +BuildRequires: maven-doxia-sitetools +BuildRequires: maven-shared-plugin-testing-harness + +Requires: maven2 +Requires: jpackage-utils +Requires: java +Requires(post): jpackage-utils +Requires(postun): jpackage-utils + +%description +The Resources Plugin handles the copying of project resources +to the output directory. + +%package javadoc +Group: Documentation +Summary: Javadoc for %{name} +Requires: jpackage-utils + +%description javadoc +API documentation for %{name}. + + +%prep +%setup -q -n %{name}-%{version} + +%build +export MAVEN_REPO_LOCAL=$(pwd)/.m2/repository +mvn-jpp \ + -e \ + -Dmaven2.jpp.mode=true \ + -Dmaven.repo.local=$MAVEN_REPO_LOCAL \ + install javadoc:javadoc + +%install +rm -rf %{buildroot} + +# jars +install -d -m 0755 %{buildroot}%{_javadir} +install -m 644 target/%{name}-%{version}.jar %{buildroot}%{_javadir}/%{name}-%{version}.jar + +(cd %{buildroot}%{_javadir} && for jar in *-%{version}*; \ + do ln -sf ${jar} `echo $jar| sed "s|-%{version}||g"`; done) + +%add_to_maven_depmap org.apache.maven.plugins maven-resources-plugin %{version} JPP maven-resources-plugin + +# poms +install -d -m 755 %{buildroot}%{_mavenpomdir} +install -pm 644 pom.xml \ + %{buildroot}%{_mavenpomdir}/JPP-%{name}.pom + +# javadoc +install -d -m 0755 %{buildroot}%{_javadocdir}/%{name}-%{version} +cp -pr target/site/api*/* %{buildroot}%{_javadocdir}/%{name}-%{version}/ +ln -s %{name}-%{version} %{buildroot}%{_javadocdir}/%{name} +rm -rf target/site/api* + +%post +%update_maven_depmap + +%postun +%update_maven_depmap + +%clean +rm -rf %{buildroot} + +%files +%defattr(-,root,root,-) +%{_javadir}/* +%{_mavenpomdir}/* +%{_mavendepmapfragdir}/* + +%files javadoc +%defattr(-,root,root,-) +%{_javadocdir}/%{name}-%{version} +%{_javadocdir}/%{name} + +%changelog +* Mon May 17 2010 Hui Wang - 2.2-2 +- Fixed install -pm 644 pom.xml +* Thu May 13 2010 Hui Wang - 2.2-1 +- Initial version of the package \ No newline at end of file diff --git a/sources b/sources index e69de29..07b2d46 100644 --- a/sources +++ b/sources @@ -0,0 +1 @@ +71020dea0609aeee5bccdbe947832ad8 maven-resources-plugin-2.2.tar.gz