[Jpackage-commits] dist/maven-jar-plugin/devel .cvsignore, 1.1, 1.2 maven-jar-plugin-jpp-depmap.xml, NONE, 1.1 maven-jar-plugin.spec, NONE, 1.1 sources, 1.1, 1.2

David Walluck david at ryu.zarb.org
Wed Oct 12 22:55:51 CEST 2011


Update of /home/projects/jpackage/cvs/dist/maven-jar-plugin/devel
In directory ryu.zarb.org:/tmp/cvs-serv8476/devel

Modified Files:
	.cvsignore sources 
Added Files:
	maven-jar-plugin-jpp-depmap.xml maven-jar-plugin.spec 
Log Message:
- intiail import

Index: .cvsignore
===================================================================
RCS file: /home/projects/jpackage/cvs/dist/maven-jar-plugin/devel/.cvsignore,v
retrieving revision 1.1
retrieving revision 1.2
diff -C 2 -d -r1.1 -r1.2
*** .cvsignore	12 Oct 2011 20:55:17 -0000	1.1
--- .cvsignore	12 Oct 2011 20:55:49 -0000	1.2
***************
*** 0 ****
--- 1 ----
+ maven-jar-plugin-2.4.tar.bz2

Index: sources
===================================================================
RCS file: /home/projects/jpackage/cvs/dist/maven-jar-plugin/devel/sources,v
retrieving revision 1.1
retrieving revision 1.2
diff -C 2 -d -r1.1 -r1.2
*** sources	12 Oct 2011 20:55:17 -0000	1.1
--- sources	12 Oct 2011 20:55:49 -0000	1.2
***************
*** 0 ****
--- 1 ----
+ 0455083751f66eb21eb77e7d018efdd9  maven-jar-plugin-2.4.tar.bz2

--- NEW FILE: maven-jar-plugin-jpp-depmap.xml ---
<dependencies>
	<dependency>
	  <maven>
		<groupId>commons-codec</groupId>
		<artifactId>commons-codec</artifactId>
	  </maven>
	  <jpp>
		<groupId>JPP</groupId>
		<artifactId>commons-codec</artifactId>
	  </jpp>
	</dependency>
</dependencies>
--- NEW FILE: maven-jar-plugin.spec ---
%global _mavenpomdir %{_datadir}/maven2/poms/
Name:           maven-jar-plugin
Version:        2.4
Release:        1%{?dist}
Summary:        Maven JAR Plugin

Group:          Development/Libraries
License:        ASL 2.0
URL:            http://maven.apache.org/plugins/maven-jar-plugin/
# svn export http://svn.apache.org/repos/asf/maven/plugins/tags/maven-jar-plugin-2.4/ && tar cjf maven-jar-plugin-2.4.tar.bz2 maven-jar-plugin-2.4
Source0:        maven-jar-plugin-2.4.tar.bz2
Source1:        %{name}-jpp-depmap.xml
BuildRoot:      %{_tmppath}/%{name}-%{version}-%{release}-root

BuildArch: noarch

BuildRequires: java-devel >= 1:1.6.0
BuildRequires: maven2
BuildRequires: maven2-common-poms
BuildRequires: maven-plugin-plugin
BuildRequires: maven-jar-plugin
BuildRequires: maven-install-plugin
BuildRequires: maven-resources-plugin
BuildRequires: maven-compiler-plugin
BuildRequires: maven-javadoc-plugin
BuildRequires: maven-surefire-maven-plugin
BuildRequires: maven-archiver
BuildRequires: plexus-archiver
BuildRequires: jakarta-commons-lang
Requires: maven2
Requires: plexus-archiver
Requires: maven-archiver
Requires: jakarta-commons-lang
Requires:       jpackage-utils
Requires:       java
Requires(post):       jpackage-utils
Requires(postun):     jpackage-utils

Provides:       maven2-plugin-jar = %{version}-%{release}
Obsoletes:      maven2-plugin-jar <= 0:2.0.8

%description
Builds a Java Archive (JAR) file from the compiled 
project classes and resources.

%package javadoc
Group:          Documentation
Summary:        Javadoc for %{name}
Requires:       jpackage-utils

%description javadoc
API documentation for %{name}.


%prep
%setup -q 
#let plexus-container-default be retrieved as a dependency
sed -i -e "s|plexus-container-default|plexus-container|g" pom.xml

%build
export MAVEN_REPO_LOCAL=$(pwd)/.m2/repository
mvn-jpp \
        -e \
        -Dmaven2.jpp.mode=true \
        -Dmaven.repo.local=$MAVEN_REPO_LOCAL \
        -Dmaven2.jpp.depmap.file=%{SOURCE1} \
        -Dmaven.test.skip=true \
        install javadoc:aggregate

%install
rm -rf %{buildroot}

# jars
install -d -m 0755 %{buildroot}%{_javadir}
install -p -m 644 target/maven-jar-plugin-%{version}.jar %{buildroot}%{_javadir}/%{name}-%{version}.jar

(cd %{buildroot}%{_javadir} && for jar in *-%{version}*; \
    do ln -s ${jar} `echo $jar| sed "s|-%{version}||g"`; done)

%add_to_maven_depmap org.apache.maven.plugins maven-jar-plugin %{version} JPP maven-jar-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}

%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 Sep 19 2011 David Walluck <dwalluck at redhat.com> 2.4-1
- 2.4
- skip tests

* Tue Sep 28 2010 Hui Wang <huwang at redhat.com> 2.3.1-3
- Adjust BRs

* Mon Sep 13 2010 Hui Wang <huwang at redhat.com> 2.3.1-2
- Adjust BRs
- Add depmap file

* Fri Sep 10 2010 Alexander Kurtakov <akurtako at redhat.com> 2.3.1-1
- Update to 2.3.1.
- Keep plexus-container-default on the dependency tree.
- Drop depmap - not needed now.

* Wed May 19 2010 Alexander Kurtakov <akurtako at redhat.com> 2.3-3
- Add depmap.

* Wed May 19 2010 Alexander Kurtakov <akurtako at redhat.com> 2.3-2
- Requires maven-shared-archiver.

* Thu May 13 2010 Alexander Kurtakov <akurtako at redhat.com> 2.3-1
- Initial package




More information about the JPackage-commits mailing list