2019-04-01 11:31:21 +02:00
|
|
|
#
|
2024-01-30 10:26:34 +01:00
|
|
|
# spec file for package xmvn-mojo
|
2019-04-01 11:31:21 +02:00
|
|
|
#
|
2024-01-30 10:26:34 +01:00
|
|
|
# Copyright (c) 2024 SUSE LLC
|
2019-04-01 11:31:21 +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/
|
|
|
|
#
|
|
|
|
|
|
|
|
|
|
|
|
%global parent xmvn
|
|
|
|
%global subname mojo
|
|
|
|
Name: %{parent}-%{subname}
|
2023-05-01 19:43:17 +02:00
|
|
|
Version: 4.2.0
|
2019-04-01 11:31:21 +02:00
|
|
|
Release: 0
|
|
|
|
Summary: XMvn MOJO
|
|
|
|
License: Apache-2.0
|
|
|
|
Group: Development/Tools/Building
|
|
|
|
URL: https://fedora-java.github.io/xmvn/
|
|
|
|
Source0: https://github.com/fedora-java/%{parent}/releases/download/%{version}/%{parent}-%{version}.tar.xz
|
2023-07-24 10:43:30 +02:00
|
|
|
Patch0: UUID.patch
|
2023-09-13 19:00:16 +02:00
|
|
|
Patch1: 0001-Do-not-leave-a-stray-options-file-in-the-generated-j.patch
|
2019-04-01 11:31:21 +02:00
|
|
|
BuildRequires: %{parent}-api = %{version}
|
|
|
|
BuildRequires: %{parent}-core = %{version}
|
|
|
|
BuildRequires: fdupes
|
|
|
|
BuildRequires: javapackages-local
|
|
|
|
BuildRequires: xmvn
|
|
|
|
BuildRequires: xmvn-install
|
|
|
|
BuildRequires: xmvn-resolve
|
|
|
|
BuildRequires: mvn(org.apache.maven.plugin-tools:maven-plugin-annotations)
|
|
|
|
BuildRequires: mvn(org.apache.maven.plugins:maven-compiler-plugin)
|
|
|
|
BuildRequires: mvn(org.apache.maven.plugins:maven-jar-plugin)
|
|
|
|
BuildRequires: mvn(org.apache.maven.plugins:maven-javadoc-plugin)
|
|
|
|
BuildRequires: mvn(org.apache.maven.plugins:maven-plugin-plugin)
|
|
|
|
BuildRequires: mvn(org.apache.maven.plugins:maven-resources-plugin)
|
|
|
|
BuildRequires: mvn(org.apache.maven.plugins:maven-surefire-plugin)
|
|
|
|
BuildRequires: mvn(org.apache.maven.resolver:maven-resolver-util)
|
|
|
|
BuildRequires: mvn(org.apache.maven:maven-artifact)
|
|
|
|
BuildRequires: mvn(org.apache.maven:maven-core)
|
|
|
|
BuildRequires: mvn(org.apache.maven:maven-model)
|
|
|
|
BuildRequires: mvn(org.apache.maven:maven-plugin-api)
|
2023-05-01 21:54:01 +02:00
|
|
|
BuildRequires: mvn(org.ow2.asm:asm)
|
2019-04-04 12:07:55 +02:00
|
|
|
#!BuildRequires: maven-compiler-plugin-bootstrap
|
|
|
|
#!BuildRequires: maven-jar-plugin-bootstrap
|
|
|
|
#!BuildRequires: maven-javadoc-plugin-bootstrap
|
|
|
|
#!BuildRequires: maven-plugin-plugin-bootstrap
|
|
|
|
#!BuildRequires: maven-resources-plugin-bootstrap
|
|
|
|
#!BuildRequires: maven-surefire-plugin-bootstrap
|
2019-04-01 11:31:21 +02:00
|
|
|
BuildArch: noarch
|
|
|
|
|
|
|
|
%description
|
|
|
|
This package provides XMvn MOJO, which is a Maven plugin that consists
|
|
|
|
of several MOJOs. Some goals of these MOJOs are intended to be
|
|
|
|
attached to default Maven lifecycle when building packages, others can
|
|
|
|
be called directly from Maven command line.
|
|
|
|
|
|
|
|
%package javadoc
|
|
|
|
Summary: API documentation for %{name}
|
|
|
|
Group: Documentation/HTML
|
|
|
|
|
|
|
|
%description javadoc
|
|
|
|
This package provides %{summary}.
|
|
|
|
|
|
|
|
%prep
|
|
|
|
%setup -q -n %{parent}-%{version}
|
|
|
|
|
2022-05-05 13:00:06 +02:00
|
|
|
%autopatch -p1
|
|
|
|
|
2019-04-01 11:31:21 +02:00
|
|
|
# Resolver IT won't work either - it tries to execute JAR file, which
|
|
|
|
# relies on Class-Path in manifest, which is forbidden in Fedora...
|
|
|
|
find -name ResolverIntegrationTest.java -delete
|
|
|
|
|
|
|
|
%pom_remove_plugin -r :maven-site-plugin
|
|
|
|
|
|
|
|
%{mvn_package} ":xmvn{,-it}" __noinstall
|
|
|
|
|
|
|
|
# Upstream code quality checks, not relevant when building RPMs
|
|
|
|
%pom_remove_plugin -r :apache-rat-plugin
|
|
|
|
%pom_remove_plugin -r :maven-checkstyle-plugin
|
|
|
|
%pom_remove_plugin -r :jacoco-maven-plugin
|
|
|
|
# FIXME pom macros don't seem to support submodules in profile
|
|
|
|
%pom_remove_plugin :jacoco-maven-plugin xmvn-it
|
|
|
|
|
|
|
|
# remove dependency plugin maven-binaries execution
|
|
|
|
# we provide apache-maven by symlink
|
|
|
|
%pom_xpath_remove "pom:executions/pom:execution[pom:id[text()='maven-binaries']]"
|
|
|
|
|
|
|
|
# Don't put Class-Path attributes in manifests
|
|
|
|
%pom_remove_plugin :maven-jar-plugin xmvn-tools
|
|
|
|
|
2022-05-09 19:01:34 +02:00
|
|
|
# Remove all dependencies with scope test, since a raw xmvn does not hide them
|
|
|
|
%pom_remove_dep -r :::test:
|
2019-11-21 15:31:07 +01:00
|
|
|
|
2024-05-15 14:31:37 +02:00
|
|
|
%pom_xpath_inject "pom:project/pom:build/pom:plugins/pom:plugin[pom:artifactId='maven-plugin-plugin']/pom:configuration" '
|
|
|
|
<goalPrefix>xmvn-mojo</goalPrefix>' xmvn-mojo
|
|
|
|
|
2019-04-01 11:31:21 +02:00
|
|
|
pushd %{name}
|
|
|
|
%{mvn_file} :{*} %{parent}/@1
|
|
|
|
popd
|
|
|
|
|
|
|
|
%build
|
|
|
|
pushd %{name}
|
|
|
|
xmvn \
|
2019-04-04 12:07:55 +02:00
|
|
|
--batch-mode --offline \
|
2019-04-01 11:31:21 +02:00
|
|
|
-Dmaven.test.skip=true -Dsource=8 \
|
2019-04-04 12:07:55 +02:00
|
|
|
package org.apache.maven.plugins:maven-javadoc-plugin:aggregate
|
2019-04-01 11:31:21 +02:00
|
|
|
|
|
|
|
%{mvn_artifact} pom.xml target/%{name}-%{version}.jar
|
|
|
|
|
|
|
|
popd
|
|
|
|
|
|
|
|
%install
|
|
|
|
pushd %{name}
|
|
|
|
%mvn_install
|
|
|
|
%fdupes -s %{buildroot}%{_javadocdir}
|
|
|
|
popd
|
|
|
|
|
|
|
|
%files -f %{name}/.mfiles
|
|
|
|
%license LICENSE NOTICE
|
|
|
|
%doc AUTHORS README.md
|
|
|
|
|
|
|
|
%files javadoc -f %{name}/.mfiles-javadoc
|
|
|
|
%license LICENSE NOTICE
|
|
|
|
|
|
|
|
%changelog
|