1ccc76d
Name:             paranamer
1ccc76d
Version:          2.4.1
758274a
Release:          2%{?dist}
1ccc76d
Summary:          Library for accessing non-private method parameter names at run-time
1ccc76d
Group:            Development/Libraries
1ccc76d
License:          BSD
1ccc76d
URL:              http://paranamer.codehaus.org
1ccc76d
1ccc76d
# git clone git://git.codehaus.org/paranamer-git.git paranamer-2.4.1
1ccc76d
# cd paranamer-2.4.1 && git checkout paranamer-2.4.1
1ccc76d
# find . -name '*.jar' -delete
1ccc76d
# rm -rf .git
1ccc76d
# cd .. && tar cafJ paranamer-2.4.1-CLEAN.tar.xz paranamer-2.4.1
1ccc76d
Source0:          paranamer-%{version}-CLEAN.tar.xz
1ccc76d
1ccc76d
# Removed distribution, unnecessary
1ccc76d
Patch0:           paranamer-%{version}-pom.patch
1ccc76d
1ccc76d
BuildArch:        noarch
1ccc76d
1ccc76d
BuildRequires:    jpackage-utils
1ccc76d
BuildRequires:    java-devel
1ccc76d
BuildRequires:    maven
1ccc76d
BuildRequires:    maven-compiler-plugin
1ccc76d
BuildRequires:    maven-install-plugin
1ccc76d
BuildRequires:    maven-jar-plugin
1ccc76d
BuildRequires:    maven-javadoc-plugin
1ccc76d
1ccc76d
Requires:         jpackage-utils
1ccc76d
Requires:         java
1ccc76d
1ccc76d
%description
1ccc76d
It is a library that allows the parameter names of non-private methods
1ccc76d
and constructors to be accessed at runtime.
1ccc76d
1ccc76d
%package javadoc
1ccc76d
Summary:          Javadocs for %{name}
1ccc76d
Group:            Documentation
1ccc76d
Requires:         jpackage-utils
1ccc76d
1ccc76d
%description javadoc
1ccc76d
This package contains the API documentation for %{name}.
1ccc76d
1ccc76d
%prep
1ccc76d
%setup -q
1ccc76d
1ccc76d
%patch0 -p1
1ccc76d
1ccc76d
chmod -x LICENSE.txt
1ccc76d
1ccc76d
%build
1ccc76d
# No jmock package available
1ccc76d
mvn-rpmbuild -Dmaven.test.skip=true install javadoc:aggregate
1ccc76d
1ccc76d
%install
1ccc76d
install -d -m 755 $RPM_BUILD_ROOT%{_javadir}/%{name}
1ccc76d
install -d -m 755 $RPM_BUILD_ROOT%{_mavenpomdir}
1ccc76d
install -d -m 755 $RPM_BUILD_ROOT%{_javadocdir}/%{name}
1ccc76d
1ccc76d
# JAR
1ccc76d
install -pm 644 paranamer-generator/target/paranamer-generator-%{version}.jar $RPM_BUILD_ROOT%{_javadir}/%{name}/%{name}-generator.jar
1ccc76d
install -pm 644 paranamer-maven-plugin/target/paranamer-maven-plugin-%{version}.jar $RPM_BUILD_ROOT%{_javadir}/%{name}/%{name}-maven-plugin.jar
1ccc76d
install -pm 644 paranamer-integration-tests/it-011/target/paranamer-it-011-%{version}.jar $RPM_BUILD_ROOT%{_javadir}/%{name}/%{name}-it-011.jar
1ccc76d
install -pm 644 paranamer-ant/target/paranamer-ant-%{version}.jar $RPM_BUILD_ROOT%{_javadir}/%{name}/%{name}-ant.jar
1ccc76d
install -pm 644 paranamer/target/paranamer-%{version}.jar $RPM_BUILD_ROOT%{_javadir}/%{name}/%{name}.jar
1ccc76d
1ccc76d
# POM
1ccc76d
install -pm 644 paranamer-generator/pom.xml $RPM_BUILD_ROOT%{_mavenpomdir}/JPP.%{name}-%{name}-generator.pom
1ccc76d
install -pm 644 paranamer-maven-plugin/pom.xml $RPM_BUILD_ROOT%{_mavenpomdir}/JPP.%{name}-%{name}-maven-plugin.pom
1ccc76d
install -pm 644 paranamer-integration-tests/it-011/pom.xml $RPM_BUILD_ROOT%{_mavenpomdir}/JPP.%{name}-%{name}-it-011.pom
1ccc76d
install -pm 644 paranamer-integration-tests/pom.xml $RPM_BUILD_ROOT%{_mavenpomdir}/JPP.%{name}-%{name}-it.pom
1ccc76d
install -pm 644 paranamer-ant/pom.xml $RPM_BUILD_ROOT%{_mavenpomdir}/JPP.%{name}-%{name}-ant.pom
1ccc76d
install -pm 644 paranamer/pom.xml $RPM_BUILD_ROOT%{_mavenpomdir}/JPP.%{name}-%{name}.pom
1ccc76d
install -pm 644 pom.xml $RPM_BUILD_ROOT%{_mavenpomdir}/JPP.%{name}-%{name}-parent.pom
1ccc76d
1ccc76d
# DEPMAP
1ccc76d
%add_maven_depmap JPP.%{name}-%{name}-generator.pom %{name}/%{name}-generator.jar
1ccc76d
%add_maven_depmap JPP.%{name}-%{name}-maven-plugin.pom %{name}/%{name}-maven-plugin.jar
1ccc76d
%add_maven_depmap JPP.%{name}-%{name}-it-011.pom %{name}/%{name}-it-011.jar
1ccc76d
%add_maven_depmap JPP.%{name}-%{name}-ant.pom %{name}/%{name}-ant.jar
1ccc76d
%add_maven_depmap JPP.%{name}-%{name}.pom %{name}/%{name}.jar
1ccc76d
1ccc76d
%add_maven_depmap JPP.%{name}-%{name}-it.pom
1ccc76d
%add_maven_depmap JPP.%{name}-%{name}-parent.pom
1ccc76d
1ccc76d
# APIDOCS
1ccc76d
cp -rp target/site/apidocs/* $RPM_BUILD_ROOT%{_javadocdir}/%{name}
1ccc76d
1ccc76d
%files
1ccc76d
%{_mavenpomdir}/*
1ccc76d
%{_mavendepmapfragdir}/*
1ccc76d
%{_javadir}/*
1ccc76d
%doc LICENSE.txt
1ccc76d
1ccc76d
%files javadoc
1ccc76d
%{_javadocdir}/%{name}
1ccc76d
%doc LICENSE.txt
1ccc76d
1ccc76d
%changelog
758274a
* Fri Jul 20 2012 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 2.4.1-2
758274a
- Rebuilt for https://fedoraproject.org/wiki/Fedora_18_Mass_Rebuild
758274a
1ccc76d
* Mon Mar 12 2012 Marek Goldmann <mgoldman@redhat.com> 2.4.1-1
1ccc76d
- Upstream release 2.4.1
1ccc76d
- Cleanup in spec file
1ccc76d
1ccc76d
* Mon Mar 12 2012 Marek Goldmann <mgoldman@redhat.com> 2.2-2
1ccc76d
- Updated summary and url
1ccc76d
1ccc76d
* Tue Feb 21 2012 Marek Goldmann <mgoldman@redhat.com> 2.2-1
1ccc76d
- Initial packaging
1ccc76d