-
Notifications
You must be signed in to change notification settings - Fork 4
/
Copy pathovirt-engine-extensions-api.spec.in
88 lines (60 loc) · 2.08 KB
/
ovirt-engine-extensions-api.spec.in
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
Name: ovirt-engine-extensions-api
Version: @VERSION@
Release: @RELEASE@%{?dist}
Summary: oVirt engine extensions API
Group: %{ovirt_product_group}
License: ASL 2.0
URL: http://www.ovirt.org
Source0: %{name}-%{version}.tar.gz
# We need to disable automatic generation of "Requires: java-headless >= 1:11"
# by xmvn, becase JDK 11 doesn't provide java-headless artifact, but it
# provides java-11-headless.
AutoReq: no
BuildArch: noarch
BuildRequires: java-11-openjdk-devel
BuildRequires: maven-local
BuildRequires: mvn(org.apache.maven.plugins:maven-compiler-plugin)
BuildRequires: mvn(org.apache.maven.plugins:maven-source-plugin)
# Required because of old xmvn version in COPR
BuildRequires: maven
# On EL8 maven-javadoc-plugin has been merged into xmvn, but on Fedora
# we still need to require it
%if 0%{?fedora} >= 30
BuildRequires: mvn(org.apache.maven.plugins:maven-javadoc-plugin)
%endif
Requires: java-11-openjdk-headless >= 1:11.0.0
Requires: javapackages-filesystem
Obsoletes: ovirt-engine-extensions-api-impl
%description
%{name} provides classes that define API for oVirt engine extensions
%package javadoc
Summary: oVirt engine extensions API documentation
Group: %{ovirt_product_group}
%description javadoc
oVirt engine extensions API documentation
%prep
%setup -c -q
# On EL8 maven-javadoc-plugin has been merged into xmvn, so we need to remove
# reference to it from pom.xml
%if 0%{?rhel} >= 8
%pom_remove_plugin :maven-javadoc-plugin pom.xml
%endif
# maven-release-plugin is not used during package build, so we can remove it
# from pom.xml
%pom_remove_plugin :maven-release-plugin pom.xml
%build
# Necessary to override the default for xmvn, which is JDK 8
export JAVA_HOME="/usr/lib/jvm/java-11-openjdk"
%mvn_build
%install
%mvn_install
%files -f .mfiles
%license LICENSE
%dir %{_javadir}/%{name}
%files javadoc -f .mfiles-javadoc
%changelog
* Thu Feb 13 2020 Martin Perina <mperina@redhat.com> 1.0.1-1
- Fix RPM packaging issues
* Mon Feb 10 2020 Martin Perina <mperina@redhat.com> 1.0.0-1
- Extracted from ovirt-engine into standalone project
- Bump requirements to JDK 11