2018-10-24 08:52:50 +02:00
|
|
|
#
|
2024-02-21 09:21:45 +01:00
|
|
|
# spec file for package beust-jcommander
|
2018-10-24 08:52:50 +02:00
|
|
|
#
|
2024-02-21 09:21:45 +01:00
|
|
|
# Copyright (c) 2024 SUSE LLC
|
2018-10-24 08:52:50 +02:00
|
|
|
#
|
|
|
|
# All modifications and additions to the file contributed by third parties
|
|
|
|
# remain the property of their copyright owners, unless otherwise agreed
|
|
|
|
# upon. The license for this file, and modifications and additions to the
|
|
|
|
# file, is the same license as for the pristine package itself (unless the
|
|
|
|
# license for the pristine package is not an Open Source License, in which
|
|
|
|
# case the license is the MIT License). An "Open Source License" is a
|
|
|
|
# license that conforms to the Open Source Definition (Version 1.9)
|
|
|
|
# published by the Open Source Initiative.
|
|
|
|
|
|
|
|
# Please submit bugfixes or comments via https://bugs.opensuse.org/
|
|
|
|
#
|
|
|
|
|
|
|
|
|
2024-05-20 19:10:22 +02:00
|
|
|
%define __requires_exclude java-headless
|
2018-10-24 08:52:50 +02:00
|
|
|
%global short_name jcommander
|
|
|
|
Name: beust-%{short_name}
|
2024-05-20 19:00:39 +02:00
|
|
|
Version: 1.83
|
2018-10-24 08:52:50 +02:00
|
|
|
Release: 0
|
|
|
|
Summary: Java framework for parsing command line parameters
|
|
|
|
License: Apache-2.0
|
|
|
|
Group: Development/Libraries/Java
|
2024-05-20 19:01:48 +02:00
|
|
|
URL: https://jcommander.org/
|
2023-05-03 11:14:34 +02:00
|
|
|
Source0: %{short_name}-%{version}.tar.xz
|
2018-10-24 08:52:50 +02:00
|
|
|
# Adapted from earlier version that still shipped poms. It uses kobalt for building now
|
|
|
|
Source1: %{name}.pom
|
2019-01-27 21:44:14 +01:00
|
|
|
Source2: %{name}-build.xml
|
2018-10-24 08:52:50 +02:00
|
|
|
Patch0: 0001-ParseValues-NullPointerException-patch.patch
|
2019-01-27 21:44:14 +01:00
|
|
|
BuildRequires: ant
|
2018-10-24 08:52:50 +02:00
|
|
|
BuildRequires: fdupes
|
2024-05-20 19:10:22 +02:00
|
|
|
BuildRequires: java-devel >= 9
|
2024-05-17 23:57:19 +02:00
|
|
|
BuildRequires: javapackages-local >= 6
|
2018-10-25 22:55:59 +02:00
|
|
|
Requires: java >= 1.8
|
2018-10-24 08:52:50 +02:00
|
|
|
Obsoletes: %{short_name} < %{version}-%{release}
|
|
|
|
Provides: %{short_name} = %{version}-%{release}
|
|
|
|
BuildArch: noarch
|
|
|
|
|
|
|
|
%description
|
2019-02-07 21:35:12 +01:00
|
|
|
JCommander is a Java framework that allows parsing command line
|
|
|
|
parameters (with annotations).
|
2018-10-24 08:52:50 +02:00
|
|
|
|
|
|
|
%package javadoc
|
|
|
|
Summary: API documentation for %{name}
|
|
|
|
Group: Development/Libraries/Java
|
|
|
|
|
|
|
|
%description javadoc
|
|
|
|
This package contains the %{summary}.
|
|
|
|
|
|
|
|
%prep
|
|
|
|
%setup -q -n %{short_name}-%{version}
|
2024-02-21 09:21:45 +01:00
|
|
|
%patch -P 0 -p1
|
2018-10-24 08:52:50 +02:00
|
|
|
|
|
|
|
chmod -x license.txt
|
|
|
|
cp -p %{SOURCE1} pom.xml
|
2019-01-27 21:44:14 +01:00
|
|
|
cp -p %{SOURCE2} build.xml
|
|
|
|
sed -i 's/@VERSION@/%{version}/g' pom.xml build.xml
|
|
|
|
|
2018-10-24 08:52:50 +02:00
|
|
|
%build
|
2019-01-27 21:44:14 +01:00
|
|
|
%{ant} jar javadoc
|
2018-10-24 08:52:50 +02:00
|
|
|
|
|
|
|
%install
|
|
|
|
# jars
|
|
|
|
install -d -m 0755 %{buildroot}%{_javadir}
|
2019-01-27 21:44:14 +01:00
|
|
|
install -m 644 target/%{short_name}-%{version}.jar \
|
|
|
|
%{buildroot}%{_javadir}/%{name}.jar
|
2018-10-24 08:52:50 +02:00
|
|
|
|
|
|
|
# pom
|
|
|
|
install -d -m 755 %{buildroot}%{_mavenpomdir}
|
2024-02-21 09:21:45 +01:00
|
|
|
%{mvn_install_pom} pom.xml %{buildroot}%{_mavenpomdir}/%{name}.pom
|
2019-01-27 21:44:14 +01:00
|
|
|
%add_maven_depmap %{name}.pom %{name}.jar
|
2018-10-24 08:52:50 +02:00
|
|
|
|
|
|
|
# javadoc
|
|
|
|
install -dm 755 %{buildroot}%{_javadocdir}/%{name}
|
2019-01-27 21:44:14 +01:00
|
|
|
cp -pr target/site/apidocs/* %{buildroot}%{_javadocdir}/%{name}/
|
2018-10-24 08:52:50 +02:00
|
|
|
%fdupes -s %{buildroot}%{_javadocdir}/%{name}/
|
|
|
|
|
2019-01-27 21:44:14 +01:00
|
|
|
%files -f .mfiles
|
2018-10-24 08:52:50 +02:00
|
|
|
%license license.txt
|
|
|
|
%doc notice.md README.markdown
|
|
|
|
|
|
|
|
%files javadoc
|
|
|
|
%{_javadocdir}/%{name}
|
|
|
|
|
|
|
|
%changelog
|