File apache-maven-jxr.spec of Package apache-maven-jxr

#
# spec file for package apache-maven-jxr
#
# Copyright (c) 2024 SUSE LLC
#
# 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/
#


%global short_name maven-jxr
Name:           apache-%{short_name}
Version:        3.3.2
Release:        0
Summary:        Apache Maven JXR (Plugin)
# FIXME: Select a correct license from https://github.com/openSUSE/spec-cleaner#spdx-licenses
License:        Apache-2.0
Group:          Development/Libraries/Java
URL:            https://maven.apache.org/jxr/
Source0:        https://github.com/apache/%{short_name}/archive/refs/tags/jxr-%{version}.tar.gz
Source1:        https://www.apache.org/licenses/LICENSE-2.0.txt
BuildRequires:  fdupes
BuildRequires:  maven-local
BuildRequires:  mvn(org.apache.maven.plugins:maven-plugin-plugin)
BuildRequires:  mvn(org.apache.maven.reporting:maven-reporting-impl)
BuildRequires:  mvn(org.apache.maven:maven-parent:pom:)
BuildRequires:  mvn(org.apache.velocity:velocity)
BuildRequires:  mvn(org.eclipse.sisu:sisu-maven-plugin)
BuildArch:      noarch

%description
Maven JXR project (formally Java Cross Reference) is a library to analyze a set
of Java source files and produces documentation in HTML format à la Javadoc.

%package javadoc
Summary:        API documentation for %{name}
Group:          Documentation/HTML

%description javadoc
API documentation for %{name}.

%prep
%autosetup -n %{short_name}-jxr-%{version}

cp %{SOURCE1} .

%build
%{mvn_build} -f -- \
	-Dproject.build.outputTimestamp=$(date -u -d @${SOURCE_DATE_EPOCH:-$(date +%%s)} +%%Y-%%m-%%dT%%H:%%M:%%SZ)

%install
%mvn_install
%fdupes %{buildroot}%{_javadocdir}/%{name}

%files -f .mfiles
%license LICENSE-2.0.txt
%doc README.md

%files javadoc -f .mfiles-javadoc
%license LICENSE-2.0.txt

%changelog
openSUSE Build Service is sponsored by