Update to upstream version 2.0.2

This commit is contained in:
Mikolaj Izdebski 2020-05-16 15:53:32 +02:00
parent 24d4d35226
commit 023f778c5b
3 changed files with 18 additions and 63 deletions

1
.gitignore vendored
View File

@ -2,3 +2,4 @@
/LICENSE-2.0.txt
/noarch
/*.src.rpm
/1.0.1.tar.gz

View File

@ -1,29 +1,14 @@
Name: atinject
Version: 1
Release: 31.20100611svn86%{?dist}
Version: 1.0.1
Release: 1%{?dist}
Summary: Dependency injection specification for Java (JSR-330)
License: ASL 2.0
URL: http://code.google.com/p/atinject/
URL: https://github.com/eclipse-ee4j/injection-api
BuildArch: noarch
# latest release doesn't generate javadocs and there is no source
# tarball with pom.xml or ant build file
#
# svn export -r86 http://atinject.googlecode.com/svn/trunk atinject-1
# rm -rf atinject-1/{lib,javadoc}/
# tar caf atinject-1.tar.xz atinject-1
Source0: %{name}-%{version}.tar.xz
# These manifests based on the ones shipped by eclipse.org
Source1: MANIFEST.MF
Source2: MANIFEST-TCK.MF
Source3: http://www.apache.org/licenses/LICENSE-2.0.txt
Source0: https://github.com/eclipse-ee4j/injection-api/archive/%{version}.tar.gz
# Compile with source/target 1.6
Patch0: %{name}-target-1.6.patch
BuildRequires: javapackages-local
BuildRequires: java-1.8.0-openjdk-devel
BuildRequires: junit
BuildRequires: maven-local
%description
This package specifies a means for obtaining objects in such a way as
@ -32,61 +17,31 @@ traditional approaches such as constructors, factories, and service
locators (e.g., JNDI). This process, known as dependency injection, is
beneficial to most nontrivial applications.
%package tck
Summary: TCK for testing %{name} compatibility with JSR-330
Requires: %{name} = %{version}-%{release}
Requires: junit
%description tck
%{summary}.
%{?module_package}
%{?javadoc_package}
%prep
%setup -q
cp %{SOURCE3} LICENSE
mkdir lib
build-jar-repository -p lib junit
%setup -q -n injection-api-%{version}
%patch0 -p1
%pom_remove_parent
%pom_remove_plugin -r :maven-javadoc-plugin
# Fix dep in TCK pom
sed -i -e 's/pom\.groupId/project.groupId/' tck-pom.xml
# J2EE API symlinks
%mvn_file :javax.inject atinject javax.inject/atinject
# TCK sub-package
%mvn_file :javax.inject-tck atinject-tck
%mvn_package :javax.inject-tck tck
%mvn_alias : javax.inject:javax.inject
%mvn_file : atinject
%build
set -e
alias rm=:
alias xargs=:
alias javadoc='javadoc -Xdoclint:none'
export PATH="%{_jvmlibdir}/java-1.8.0-openjdk/bin:${PATH}"
. ./build.sh
# Inject OSGi manifests required by Eclipse.
jar umf %{SOURCE1} build/dist/javax.inject.jar
jar umf %{SOURCE2} build/tck/dist/javax.inject-tck.jar
%mvn_artifact pom.xml build/dist/javax.inject.jar
%mvn_artifact tck-pom.xml build/tck/dist/javax.inject-tck.jar
mv build/tck/javadoc build/javadoc/tck
%mvn_build
%install
%mvn_install -J build/javadoc
%mvn_install
%files -n %{?module_prefix}%{name} -f .mfiles
%license LICENSE
%files tck -f .mfiles-tck
%license LICENSE.txt NOTICE.md
%changelog
* Sat May 16 2020 Mikolaj Izdebski <mizdebsk@redhat.com> - 1.0.1-1
- Update to upstream version 1.0.1
* Sat Jan 25 2020 Mikolaj Izdebski <mizdebsk@redhat.com> - 1-31.20100611svn86
- Build with OpenJDK 8

View File

@ -1,2 +1 @@
SHA512 (atinject-1.tar.xz) = 45cef31ebfe7b3b7b327aa8aa5c06c86701071e14694f60df0a581c5d25e9691a92a27c31aee03c6226035b9d96b5a40cc8e4a490eea4ef23e289b8c36c60d49
SHA512 (LICENSE-2.0.txt) = 98f6b79b778f7b0a15415bd750c3a8a097d650511cb4ec8115188e115c47053fe700f578895c097051c9bc3dfb6197c2b13a15de203273e1a3218884f86e90e8
SHA512 (1.0.1.tar.gz) = bdbc0ae1e06574ebe5baf82d7f4ba7ea20d161cec893c687d60549b9f426134f8c6cc834774804a50de577e3a4327645e87560b79712febc51f9a7815de1d896