- Initial SUSE packaging based on jpp 5.0

OBS-URL: https://build.opensuse.org/package/show/Java:packages/jsr-305?expand=0&rev=2
This commit is contained in:
Michal Vyskocil 2009-06-03 13:01:50 +00:00 committed by Git OBS Bridge
parent 21e3cad7bd
commit 50c3c30deb
2 changed files with 12 additions and 66 deletions

5
jsr-305.changes Normal file
View File

@ -0,0 +1,5 @@
-------------------------------------------------------------------
Wed Jun 3 14:58:27 CEST 2009 - mvyskocil@suse.cz
- Initial SUSE packaging based on jpp 5.0

View File

@ -1,42 +1,8 @@
# Copyright (c) 2000-2008, JPackage Project
# All rights reserved.
#
# Redistribution and use in source and binary forms, with or without
# modification, are permitted provided that the following conditions
# are met:
#
# 1. Redistributions of source code must retain the above copyright
# notice, this list of conditions and the following disclaimer.
# 2. Redistributions in binary form must reproduce the above copyright
# notice, this list of conditions and the following disclaimer in the
# documentation and/or other materials provided with the
# distribution.
# 3. Neither the name of the JPackage Project nor the names of its
# contributors may be used to endorse or promote products derived
# from this software without specific prior written permission.
#
# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
# "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
# LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
# A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
# OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
# SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
# LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
# DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
# THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
# (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
# OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
#
%define gcj_support %{?_with_gcj_support:1}%{!?_with_gcj_support:%{?_without_gcj_support:0}%{!?_without_gcj_support:%{?_gcj_support:%{_gcj_support}}%{!?_gcj_support:0}}}
%define section free %define section free
Name: jsr-305 Name: jsr-305
Version: 0.1 Version: 0.1
%define jpp_release 1 Release: 1
Release: 1%{?dist}
Epoch: 0
Summary: JSR 305: Annotations for Software Defect Detection in Java Summary: JSR 305: Annotations for Software Defect Detection in Java
# http://groups.google.com/group/jsr-305/browse_thread/thread/8105869a258c8c4f # http://groups.google.com/group/jsr-305/browse_thread/thread/8105869a258c8c4f
License: BSD License: BSD
@ -46,17 +12,13 @@ URL: http://code.google.com/p/jsr-305/
# tar cjf jsr-305-0.1.bz2 jsr-305-0.1 # tar cjf jsr-305-0.1.bz2 jsr-305-0.1
Source0: http://code.google.com/p/jsr-305/jsr-305-0.1.tar.bz2 Source0: http://code.google.com/p/jsr-305/jsr-305-0.1.tar.bz2
Source1: jsr-305-ri-build.xml Source1: jsr-305-ri-build.xml
Provides: jsr305 = %{epoch}:%{version}-%{release} Provides: jsr305 = %{version}-%{release}
Requires: jpackage-utils Requires: jpackage-utils
BuildRequires: ant BuildRequires: ant
BuildRequires: java-devel BuildRequires: java-devel
BuildRequires: java-javadoc BuildRequires: java-javadoc
BuildRequires: jpackage-utils BuildRequires: jpackage-utils
%if %{gcj_support}
BuildRequires: java-gcj-compat-devel
%else
Buildarch: noarch Buildarch: noarch
%endif
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root
%description %description
@ -70,7 +32,10 @@ Summary: Javadoc for %{name}
Group: Development/Documentation Group: Development/Documentation
%description javadoc %description javadoc
Javadoc for %{name}. This project contains reference implementations, test cases, and other
documents under source code control for Java Specification Request 305:
Annotations for Software Defect Detection. More information at the Google
group: http://groups.google.com/group/jsr-305.
%prep %prep
%setup -q %setup -q
@ -85,8 +50,6 @@ pushd ri
popd popd
%install %install
%{__rm} -rf %{buildroot}
# jars # jars
%{__mkdir_p} %{buildroot}%{_javadir} %{__mkdir_p} %{buildroot}%{_javadir}
%{__cp} -a ri/jsr-305-%{version}.jar %{buildroot}%{_javadir}/%{name}-%{version}.jar %{__cp} -a ri/jsr-305-%{version}.jar %{buildroot}%{_javadir}/%{name}-%{version}.jar
@ -104,30 +67,14 @@ popd
%{__cp} -a ri/javadoc/* %{buildroot}%{_javadocdir}/%{name}-%{version} %{__cp} -a ri/javadoc/* %{buildroot}%{_javadocdir}/%{name}-%{version}
%{__ln_s} %{name}-%{version} %{buildroot}%{_javadocdir}/%{name} %{__ln_s} %{name}-%{version} %{buildroot}%{_javadocdir}/%{name}
%if %{gcj_support}
%{_bindir}/aot-compile-rpm
%endif
%clean %clean
%{__rm} -rf %{buildroot} %{__rm} -rf %{buildroot}
%post %post
%update_maven_depmap %update_maven_depmap
%if %{gcj_support}
if [ -x %{_bindir}/rebuild-gcj-db ]
then
%{_bindir}/rebuild-gcj-db || :
fi
%endif
%postun %postun
%update_maven_depmap %update_maven_depmap
%if %{gcj_support}
if [ -x %{_bindir}/rebuild-gcj-db ]
then
%{_bindir}/rebuild-gcj-db || :
fi
%endif
%files %files
%defattr(0644,root,root,0755) %defattr(0644,root,root,0755)
@ -136,11 +83,7 @@ fi
%{_javadir}/jsr305-%{version}.jar %{_javadir}/jsr305-%{version}.jar
%{_javadir}/jsr305.jar %{_javadir}/jsr305.jar
%{_datadir}/maven2/poms/* %{_datadir}/maven2/poms/*
%{_mavendepmapfragdir}/* %config %{_mavendepmapfragdir}/*
%if %{gcj_support}
%dir %{_libdir}/gcj/%{name}
%attr(-,root,root) %{_libdir}/gcj/%{name}/*
%endif
%files javadoc %files javadoc
%defattr(0644,root,root,0755) %defattr(0644,root,root,0755)
@ -148,5 +91,3 @@ fi
%{_javadocdir}/%{name} %{_javadocdir}/%{name}
%changelog %changelog
* Fri Aug 08 2008 David Walluck <dwalluck@redhat.com> 0:0.1-1
- release