2014-05-21 19:07:25 +02:00
|
|
|
#
|
|
|
|
# spec file for package apache-commons-cli
|
|
|
|
#
|
2024-02-20 12:53:18 +01:00
|
|
|
# Copyright (c) 2024 SUSE LLC
|
2014-05-21 19:07:25 +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.
|
|
|
|
|
2018-10-23 19:57:46 +02:00
|
|
|
# Please submit bugfixes or comments via https://bugs.opensuse.org/
|
2014-05-21 19:07:25 +02:00
|
|
|
#
|
|
|
|
|
|
|
|
|
|
|
|
%global base_name cli
|
|
|
|
%global short_name commons-%{base_name}
|
|
|
|
Name: apache-commons-cli
|
2024-05-02 14:10:05 +02:00
|
|
|
Version: 1.7.0
|
2014-05-21 19:07:25 +02:00
|
|
|
Release: 0
|
|
|
|
Summary: Command Line Interface Library for Java
|
|
|
|
License: Apache-2.0
|
|
|
|
Group: Development/Libraries/Java
|
2021-12-16 21:22:31 +01:00
|
|
|
URL: https://commons.apache.org/%{base_name}/
|
2024-05-02 14:44:45 +02:00
|
|
|
Source0: https://archive.apache.org/dist/commons/%{base_name}/source/%{short_name}-%{version}-src.tar.gz
|
2021-02-12 14:11:04 +01:00
|
|
|
Source1: %{name}-build.xml
|
2021-12-16 21:22:31 +01:00
|
|
|
Source2: apache-commons-cli-rpmlintrc
|
2019-01-28 07:38:37 +01:00
|
|
|
Patch0: CLI-253-workaround.patch
|
2014-05-21 19:07:25 +02:00
|
|
|
BuildRequires: ant
|
2018-05-15 08:22:56 +02:00
|
|
|
BuildRequires: fdupes
|
2023-09-29 15:11:20 +02:00
|
|
|
BuildRequires: javapackages-local >= 6
|
2014-05-21 19:07:25 +02:00
|
|
|
Provides: jakarta-%{short_name} = %{version}-%{release}
|
2021-02-12 13:57:36 +01:00
|
|
|
Obsoletes: jakarta-%{short_name} < %{version}-%{release}
|
|
|
|
Provides: apache-cli = %{version}-%{release}
|
|
|
|
Obsoletes: apache-cli < %{version}-%{release}
|
2019-01-28 07:38:37 +01:00
|
|
|
BuildArch: noarch
|
2014-05-21 19:07:25 +02:00
|
|
|
|
|
|
|
%description
|
2019-02-05 16:29:34 +01:00
|
|
|
The CLI library provides an API for working with the
|
2014-05-21 19:07:25 +02:00
|
|
|
command line arguments and options.
|
|
|
|
|
|
|
|
%package javadoc
|
|
|
|
Summary: Javadoc for %{name}
|
2019-02-05 16:29:34 +01:00
|
|
|
Group: Documentation/HTML
|
2021-02-12 13:57:36 +01:00
|
|
|
Provides: jakarta-%{short_name}-javadoc = %{version}-%{release}
|
|
|
|
Obsoletes: jakarta-%{short_name}-javadoc < %{version}-%{release}
|
2014-05-21 19:07:25 +02:00
|
|
|
|
|
|
|
%description javadoc
|
|
|
|
This package contains the API documentation for %{name}.
|
|
|
|
|
|
|
|
%prep
|
2021-02-12 14:11:04 +01:00
|
|
|
%setup -q -n %{short_name}-%{version}-src
|
|
|
|
cp %{SOURCE1} build.xml
|
2024-02-20 12:53:18 +01:00
|
|
|
%patch -P 0 -p1
|
2014-05-21 19:07:25 +02:00
|
|
|
|
2019-03-25 18:19:52 +01:00
|
|
|
%pom_remove_parent
|
|
|
|
|
2014-05-21 19:07:25 +02:00
|
|
|
%build
|
2023-09-29 15:11:20 +02:00
|
|
|
%{ant} package javadoc
|
2014-05-21 19:07:25 +02:00
|
|
|
|
|
|
|
%install
|
|
|
|
# jars
|
2019-01-28 07:38:37 +01:00
|
|
|
install -Dpm 644 target/%{short_name}-%{version}.jar %{buildroot}%{_javadir}/%{short_name}.jar
|
|
|
|
ln -sf %{short_name}.jar %{buildroot}%{_javadir}/%{name}.jar
|
2014-05-21 19:07:25 +02:00
|
|
|
|
|
|
|
# pom
|
|
|
|
install -d -m 755 %{buildroot}%{_mavenpomdir}
|
2023-09-29 15:11:20 +02:00
|
|
|
%{mvn_install_pom} pom.xml %{buildroot}%{_mavenpomdir}/%{short_name}.pom
|
2019-01-28 07:38:37 +01:00
|
|
|
%add_maven_depmap %{short_name}.pom %{short_name}.jar -a "org.apache.commons:%{short_name}"
|
2014-05-21 19:07:25 +02:00
|
|
|
|
|
|
|
# javadoc
|
2019-01-28 08:24:57 +01:00
|
|
|
install -d -m 0755 %{buildroot}%{_javadocdir}/%{name}
|
|
|
|
cp -pr target/site/api*/* %{buildroot}%{_javadocdir}/%{name}
|
|
|
|
%fdupes -s %{buildroot}%{_javadocdir}/%{name}
|
2014-05-21 19:07:25 +02:00
|
|
|
|
2019-01-28 07:38:37 +01:00
|
|
|
%files -f .mfiles
|
|
|
|
%license LICENSE.txt NOTICE.txt
|
|
|
|
%doc README.md RELEASE-NOTES.txt
|
|
|
|
%{_javadir}/%{name}.jar
|
2014-05-21 19:07:25 +02:00
|
|
|
|
|
|
|
%files javadoc
|
2019-01-28 07:38:37 +01:00
|
|
|
%license LICENSE.txt
|
2019-01-28 08:24:57 +01:00
|
|
|
%{_javadocdir}/%{name}
|
2014-05-21 19:07:25 +02:00
|
|
|
|
|
|
|
%changelog
|