Sophie

Sophie

distrib > Fedora > 15 > x86_64 > by-pkgid > bc4f5db9f5cdba5e58897b873a6683c7 > files > 3

mojo-signatures-1.1-0.4.svn11457.fc15.src.rpm

Name:           mojo-signatures
Version:        1.1
Release:        0.4.svn11457%{?dist}
Summary:        Mojo API signatures project

Group:          Development/Libraries
License:        MIT
URL:            http://mojo.codehaus.org/

# we are using svn because upstream doesn't provide source tarballs
# and we want to have all available signatures together anyway (just
# in case)
# svn export http://svn.codehaus.org/mojo/trunk/signatures -r11457 mojo-signatures-1.1
# tar caf mojo-signatures-1.1.tar.xz mojo-signatures-1.1
Source0:        %{name}-%{version}.tar.xz

Patch0:         0001-pom.xml-files.patch
BuildRoot:      %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
BuildArch:      noarch


# specific release required for objectweb-asm dependency in pom.xml
BuildRequires:  animal-sniffer >= 1.6-3
BuildRequires:  jpackage-utils
BuildRequires:  maven2
BuildRequires:  maven-enforcer-plugin
BuildRequires:  maven-site-plugin
BuildRequires:  maven-install-plugin
BuildRequires:  maven-plugin-cobertura
BuildRequires:  objectweb-asm
BuildRequires:  mojo-parent

# we should probably generate java15 signature with 1.5 jdk, but this
# doesn't work with gcj. The signatures are probably incorrect because
# of this, but at least they exist and noone complained yet :-)


# specific release required for handling "signature" packaging
Requires:       maven2 >= 2.2.1-12
Requires:       mojo-parent

Requires:       jpackage-utils
Requires(post):       jpackage-utils
Requires(postun):     jpackage-utils

%description
The API Signatures project contains a number of projects which
generate signatures of various APIs, such as the Java Runtime. These
signatures are generated by and consumed by the Animal Sniffer
project.

%prep
%setup -q
%patch0 -p1

%build
export MAVEN_REPO_LOCAL=$(pwd)/.m2/repository

pushd signatures-parent
mvn-jpp \
        -Dmaven.repo.local=$MAVEN_REPO_LOCAL \
        install
popd

for sig in java15 java16;do
    pushd $sig
    mvn-jpp \
            -Dmaven.repo.local=$MAVEN_REPO_LOCAL \
            install
    popd
done

%install
rm -rf %{buildroot}

install -d -m 755 %{buildroot}%{_mavenpomdir}
install -d -m 755 %{buildroot}%{_javadir}/%{name}

install -pm 644 signatures-parent/pom.xml \
    %{buildroot}%{_mavenpomdir}/JPP.%{name}-parent.pom

for sig in java15 java16;do
   pushd $sig
      install -pm 644 pom.xml %{buildroot}%{_mavenpomdir}/JPP.%{name}-$sig.pom
      install -pm 644 target/*signature %{buildroot}%{_javadir}/%{name}/$sig-%{version}.signature
      %add_to_maven_depmap org.codehaus.mojo.signature $sig %{version} JPP/%{name} $sig
   popd
done

(cd $RPM_BUILD_ROOT%{_javadir}/%{name} && for sig in *-%{version}*; do ln -sf ${sig} `echo $sig| sed "s|-%{version}||g"`; done)


%clean
rm -rf $RPM_BUILD_ROOT

%post
%update_maven_depmap

%postun
%update_maven_depmap


%files
%defattr(-,root,root,-)
%{_mavenpomdir}/*
%{_mavendepmapfragdir}/*
%{_javadir}/%{name}



%changelog
* Tue Feb 08 2011 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1.1-0.4.svn11457
- Rebuilt for https://fedoraproject.org/wiki/Fedora_15_Mass_Rebuild

* Mon Oct 11 2010 Stanislav Ochotnicky <sochotnicky@redhat.com> - 1.1-0.3.svn11457
- Add mojo-parent to Requires

* Thu Sep 30 2010 Stanislav Ochotnicky <sochotnicky@redhat.com> - 1.1-0.2.svn11457
- Add mojo-parent to BRs

* Fri Sep 17 2010 Stanislav Ochotnicky <sochotnicky@redhat.com> - 1.1-0.1.svn11457
- Initial version of package