2012-10-25 11:37:36 +02:00
|
|
|
#
|
2013-03-21 12:28:25 +01:00
|
|
|
# spec file for package apache-commons-io
|
2012-10-25 11:37:36 +02:00
|
|
|
#
|
2019-02-26 18:45:09 +01:00
|
|
|
# Copyright (c) 2019 SUSE LINUX GmbH, Nuernberg, Germany.
|
2012-10-25 11:37:36 +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.
|
|
|
|
|
2019-02-26 18:45:09 +01:00
|
|
|
# Please submit bugfixes or comments via https://bugs.opensuse.org/
|
2012-10-25 11:37:36 +02:00
|
|
|
#
|
|
|
|
|
2013-03-21 12:28:25 +01:00
|
|
|
|
2012-10-25 11:37:36 +02:00
|
|
|
%define base_name io
|
|
|
|
%define short_name commons-%{base_name}
|
2019-02-26 18:45:09 +01:00
|
|
|
%bcond_with tests
|
2012-10-25 11:37:36 +02:00
|
|
|
Name: apache-commons-io
|
2019-02-26 18:45:09 +01:00
|
|
|
Version: 2.6
|
2012-10-25 11:37:36 +02:00
|
|
|
Release: 0
|
|
|
|
Summary: Utilities to assist with developing IO functionality
|
|
|
|
License: Apache-2.0
|
2013-03-21 12:28:25 +01:00
|
|
|
Group: Development/Libraries/Java
|
2019-02-26 18:45:09 +01:00
|
|
|
URL: http://commons.apache.org/%{base_name}
|
2013-03-21 12:28:25 +01:00
|
|
|
Source0: http://archive.apache.org/dist/commons/%{base_name}/source/%{short_name}-%{version}-src.tar.gz
|
2019-02-26 18:45:09 +01:00
|
|
|
Source1: %{name}-build.xml
|
2012-10-25 11:37:36 +02:00
|
|
|
BuildRequires: ant >= 1.6
|
2018-05-15 12:41:50 +02:00
|
|
|
BuildRequires: fdupes
|
|
|
|
BuildRequires: java-devel >= 1.8
|
2017-05-19 12:13:47 +02:00
|
|
|
BuildRequires: javapackages-local
|
2012-10-25 11:37:36 +02:00
|
|
|
Provides: %{short_name} = %{version}-%{release}
|
|
|
|
Provides: jakarta-%{short_name} = %{version}-%{release}
|
2019-02-26 18:45:09 +01:00
|
|
|
Obsoletes: jakarta-%{short_name} < %{version}-%{release}
|
2014-07-07 16:53:20 +02:00
|
|
|
BuildArch: noarch
|
2019-02-26 18:45:09 +01:00
|
|
|
%if %{with tests}
|
|
|
|
BuildRequires: ant-junit
|
|
|
|
%endif
|
2012-10-25 11:37:36 +02:00
|
|
|
|
|
|
|
%description
|
|
|
|
Commons-IO contains utility classes, stream implementations,
|
|
|
|
file filters, and endian classes. It is a library of utilities
|
|
|
|
to assist with developing IO functionality.
|
|
|
|
|
|
|
|
%package javadoc
|
|
|
|
Summary: Commons IO Package
|
2019-02-26 18:45:09 +01:00
|
|
|
Group: Documentation/HTML
|
2012-10-25 11:37:36 +02:00
|
|
|
|
|
|
|
%description javadoc
|
|
|
|
This package contains the API documentation for %{name}.
|
|
|
|
|
|
|
|
%prep
|
|
|
|
%setup -q -n %{short_name}-%{version}-src
|
2019-02-26 18:45:09 +01:00
|
|
|
cp %{SOURCE1} build.xml
|
2012-10-25 11:37:36 +02:00
|
|
|
|
|
|
|
%build
|
2019-02-26 18:45:09 +01:00
|
|
|
%{ant} \
|
|
|
|
-Dcompiler.source=1.8 \
|
|
|
|
%if %{without tests }
|
|
|
|
-Dtest.skip=true \
|
|
|
|
%endif
|
|
|
|
jar javadoc
|
2012-10-25 11:37:36 +02:00
|
|
|
|
|
|
|
%install
|
|
|
|
# jars
|
|
|
|
install -d -m 0755 %{buildroot}%{_javadir}
|
|
|
|
install -p -m 0644 target/%{short_name}-%{version}.jar \
|
2019-02-26 18:45:09 +01:00
|
|
|
%{buildroot}%{_javadir}/%{short_name}.jar
|
|
|
|
ln -sf %{short_name}.jar %{buildroot}%{_javadir}/%{name}.jar
|
2012-10-25 11:37:36 +02:00
|
|
|
# pom
|
|
|
|
install -d -m 755 %{buildroot}%{_mavenpomdir}
|
2019-02-26 18:45:09 +01:00
|
|
|
install -pm 644 pom.xml %{buildroot}%{_mavenpomdir}/%{short_name}.pom
|
|
|
|
%add_maven_depmap %{short_name}.pom %{short_name}.jar -a "org.apache.commons:commons-io"
|
2012-10-25 11:37:36 +02:00
|
|
|
# javadoc
|
|
|
|
install -d -m 755 %{buildroot}%{_javadocdir}/%{name}
|
2019-02-26 18:45:09 +01:00
|
|
|
cp -pr target/site/apidocs/* %{buildroot}%{_javadocdir}/%{name}
|
|
|
|
%fdupes -s %{buildroot}%{_javadocdir}
|
2012-10-25 11:37:36 +02:00
|
|
|
|
2019-02-26 18:45:09 +01:00
|
|
|
%files -f .mfiles
|
|
|
|
%license LICENSE.txt NOTICE.txt
|
|
|
|
%doc RELEASE-NOTES.txt
|
|
|
|
%{_javadir}/%{name}.jar
|
2012-10-25 11:37:36 +02:00
|
|
|
|
|
|
|
%files javadoc
|
|
|
|
%doc %{_javadocdir}/%{name}
|
|
|
|
|
|
|
|
%changelog
|