[maven-shared-jar] Initial commit

Tomas Radej tradej at fedoraproject.org
Fri Jan 25 09:41:54 UTC 2013


commit 2dfd9f89e385038cea10637c2f1f5d8ea9d8c02a
Author: Tomas Radej <tradej at redhat.com>
Date:   Fri Jan 25 10:31:36 2013 +0100

    Initial commit

 .gitignore            |    2 +
 maven-shared-jar.spec |   93 +++++++++++++++++++++++++++++++++++++++++++++++++
 sources               |    2 +
 3 files changed, 97 insertions(+), 0 deletions(-)
---
diff --git a/.gitignore b/.gitignore
index e69de29..86db9bf 100644
--- a/.gitignore
+++ b/.gitignore
@@ -0,0 +1,2 @@
+/LICENSE-2.0.txt
+/maven-shared-jar-1.1-source-release.zip
diff --git a/maven-shared-jar.spec b/maven-shared-jar.spec
new file mode 100644
index 0000000..0b57429
--- /dev/null
+++ b/maven-shared-jar.spec
@@ -0,0 +1,93 @@
+Name:           maven-shared-jar
+Version:        1.1
+Release:        2%{?dist}
+# Maven-shared defines maven-shared-jar version as 1.1
+Epoch:          1
+Summary:        Maven JAR Utilities
+License:        ASL 2.0
+URL:            http://maven.apache.org/shared/maven-shared-jar
+Source0:        http://repo1.maven.org/maven2/org/apache/maven/shared/%{name}/%{version}/%{name}-%{version}-source-release.zip
+
+BuildArch:      noarch
+
+BuildRequires:  java-devel
+BuildRequires:  jpackage-utils
+BuildRequires:  maven
+BuildRequires:  plexus-containers-component-metadata
+BuildRequires:  plexus-containers-container-default
+BuildRequires:  maven-surefire-provider-junit
+Requires:       apache-commons-collections
+Requires:       bcel
+Requires:       java
+Requires:       jpackage-utils
+Requires:       maven
+Requires:       plexus-digest
+
+Obsoletes:      maven-shared-jar < %{epoch}:%{version}-%{release} 
+Provides:       maven-shared-jar = %{epoch}:%{version}-%{release}
+
+%description
+Utilities that help identify the contents of a JAR, including Java class
+analysis and Maven metadata analysis.
+
+This is a replacement package for maven-shared-jar
+
+%package javadoc
+Group:          Documentation
+Summary:        Javadoc for %{name}
+Requires:       jpackage-utils
+    
+%description javadoc
+API documentation for %{name}.
+
+
+%prep
+%setup -q
+
+%pom_add_dep org.codehaus.plexus:plexus-container-default
+
+find -type f -iname '*.jar' -delete
+
+# Replace plexus-maven-plugin with plexus-component-metadata
+find -name 'pom.xml' -exec sed \
+    -i 's/<artifactId>plexus-maven-plugin<\/artifactId>/<artifactId>plexus-component-metadata<\/artifactId>/' '{}' ';'
+find -name 'pom.xml' -exec sed \
+    -i 's/<goal>descriptor<\/goal>/<goal>generate-metadata<\/goal>/' '{}' ';'
+
+%build
+# Tests require the jars that were removed
+mvn-rpmbuild package javadoc:aggregate -Dmaven.test.skip
+
+%install
+# JAR
+install -Ddm 755 %{buildroot}/%{_javadir}
+install -Dpm 644 target/%{name}-%{version}.jar %{buildroot}%{_javadir}/%{name}.jar
+
+# POM
+install -Ddm 755 %{buildroot}/%{_mavenpomdir}
+install -Dpm 644 pom.xml %{buildroot}%{_mavenpomdir}/JPP-%{name}.pom
+
+# JavaDoc
+install -Ddm 755 %{buildroot}/%{_javadocdir}/%{name}
+cp -pr target/site/apidocs/* %{buildroot}%{_javadocdir}/%{name}
+
+%add_maven_depmap JPP-%{name}.pom %{name}.jar
+
+%files
+%doc LICENSE NOTICE
+%{_javadir}/%{name}.jar
+%{_mavenpomdir}/JPP-%{name}.pom
+%{_mavendepmapfragdir}/%{name}
+
+%files javadoc
+%doc LICENSE NOTICE
+%doc %{_javadocdir}/%{name}
+
+
+%changelog
+* Wed Jan 23 2013 Tomas Radej <tradej at redhat.com> - 1:1.1-2
+- Removed jars and skipped tests
+
+* Tue Jan 15 2013 Tomas Radej <tradej at redhat.com> - 1:1.1-1
+- Initial version
+
diff --git a/sources b/sources
index e69de29..b774626 100644
--- a/sources
+++ b/sources
@@ -0,0 +1,2 @@
+3b83ef96387f14655fc854ddc3c6bd57  LICENSE-2.0.txt
+f71afcad0365eabf07fa151682b2620a  maven-shared-jar-1.1-source-release.zip


More information about the scm-commits mailing list