2019-11-11 13:10:41 +01:00
|
|
|
#
|
|
|
|
# spec file for package eclipse-jgit
|
|
|
|
#
|
2023-03-27 10:19:16 +02:00
|
|
|
# Copyright (c) 2023 SUSE LLC
|
2019-11-11 13:10:41 +01: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/
|
|
|
|
#
|
|
|
|
|
|
|
|
|
2021-07-30 12:15:11 +02:00
|
|
|
%global gittag 5.11.0.202103091610-r
|
2020-09-08 12:13:02 +02:00
|
|
|
%define __provides_exclude osgi*
|
2020-04-08 22:13:20 +02:00
|
|
|
Name: eclipse-jgit
|
2021-07-30 12:15:11 +02:00
|
|
|
Version: 5.11.0
|
2019-11-11 13:10:41 +01:00
|
|
|
Release: 0
|
|
|
|
Summary: Eclipse JGit
|
2019-11-11 13:25:26 +01:00
|
|
|
License: BSD-3-Clause
|
2019-11-11 13:10:41 +01:00
|
|
|
Group: Development/Libraries/Java
|
|
|
|
URL: https://www.eclipse.org/egit/
|
2021-07-30 12:15:11 +02:00
|
|
|
Source0: https://git.eclipse.org/c/jgit/jgit.git/snapshot/jgit-%{gittag}.tar.xz
|
2020-07-01 13:57:40 +02:00
|
|
|
# Set the correct classpath for the command line tools
|
|
|
|
# Switch to feature requirements for third-party bundles, also makes the following changes:
|
|
|
|
# javaewah -> com.googlecode.javaewah.JavaEWAH
|
|
|
|
# org.slf4j.api -> slf4j.api
|
|
|
|
# org.slf4j.impl.log4j12 -> slf4j.simple
|
|
|
|
Patch1: 0002-Don-t-embed-versions-of-third-party-libs-use-feature.patch
|
2021-07-30 12:15:11 +02:00
|
|
|
Patch2: jgit-shade.patch
|
|
|
|
Patch3: jgit-5.11.0-java8.patch
|
|
|
|
Patch4: jgit-apache-sshd-2.7.0.patch
|
2023-05-31 21:54:12 +02:00
|
|
|
Patch5: jgit-jsch.patch
|
2020-07-01 13:57:40 +02:00
|
|
|
# For main build
|
|
|
|
BuildRequires: ant
|
2020-04-08 22:13:20 +02:00
|
|
|
BuildRequires: apache-commons-compress
|
2021-07-30 12:15:11 +02:00
|
|
|
BuildRequires: apache-sshd >= 2.7
|
2020-04-08 22:13:20 +02:00
|
|
|
BuildRequires: args4j
|
2020-07-01 13:57:40 +02:00
|
|
|
BuildRequires: bouncycastle
|
|
|
|
BuildRequires: bouncycastle-pg
|
|
|
|
BuildRequires: bouncycastle-pkix
|
2019-11-11 13:10:41 +01:00
|
|
|
BuildRequires: eclipse-platform-bootstrap
|
2020-07-01 13:57:40 +02:00
|
|
|
BuildRequires: ed25519-java
|
|
|
|
BuildRequires: fdupes
|
|
|
|
BuildRequires: git
|
2020-04-08 22:13:20 +02:00
|
|
|
BuildRequires: google-gson
|
|
|
|
BuildRequires: hamcrest-core
|
|
|
|
BuildRequires: javaewah
|
|
|
|
BuildRequires: jgit = %{version}
|
|
|
|
BuildRequires: junit
|
|
|
|
BuildRequires: jzlib
|
2020-07-01 13:57:40 +02:00
|
|
|
BuildRequires: maven-local
|
2020-04-08 22:13:20 +02:00
|
|
|
BuildRequires: slf4j
|
2019-11-11 13:10:41 +01:00
|
|
|
BuildRequires: tycho
|
2020-04-08 22:13:20 +02:00
|
|
|
BuildRequires: xml-commons-apis
|
2020-07-02 11:41:31 +02:00
|
|
|
BuildRequires: xmvn-subst
|
2022-03-29 09:16:13 +02:00
|
|
|
BuildConflicts: java >= 12
|
|
|
|
BuildConflicts: java-devel >= 12
|
|
|
|
BuildConflicts: java-headless >= 12
|
2019-11-11 13:10:41 +01:00
|
|
|
#!BuildIgnore: eclipse-platform
|
|
|
|
#!BuildIgnore: tycho-bootstrap
|
2020-07-01 13:57:40 +02:00
|
|
|
#!BuildRequires: eclipse-emf-core eclipse-ecf-core
|
2020-04-08 22:13:20 +02:00
|
|
|
Requires: apache-commons-compress
|
2021-07-30 12:15:11 +02:00
|
|
|
Requires: apache-sshd >= 2.7
|
2020-04-08 22:13:20 +02:00
|
|
|
Requires: args4j
|
2020-07-01 13:57:40 +02:00
|
|
|
Requires: bouncycastle
|
|
|
|
Requires: bouncycastle-pg
|
|
|
|
Requires: bouncycastle-pkix
|
|
|
|
Requires: ed25519-java
|
2020-04-08 22:13:20 +02:00
|
|
|
Requires: google-gson
|
|
|
|
Requires: hamcrest-core
|
|
|
|
Requires: javaewah
|
|
|
|
Requires: jgit = %{version}
|
|
|
|
Requires: junit
|
2019-11-11 13:10:41 +01:00
|
|
|
Requires: jzlib
|
2020-04-08 22:13:20 +02:00
|
|
|
Requires: slf4j
|
|
|
|
Requires: xml-commons-apis
|
|
|
|
BuildArch: noarch
|
2020-06-29 18:26:42 +02:00
|
|
|
# Upstream Eclipse no longer supports non-64bit arches
|
|
|
|
ExcludeArch: s390 %{arm} %{ix86}
|
2019-11-11 13:10:41 +01:00
|
|
|
|
|
|
|
%description
|
|
|
|
A pure Java implementation of the Git version control system.
|
|
|
|
|
|
|
|
%prep
|
|
|
|
%setup -q -n jgit-%{gittag}
|
|
|
|
|
2020-07-01 13:57:40 +02:00
|
|
|
%patch1 -p1
|
|
|
|
%patch2 -p1
|
|
|
|
%patch3 -p1
|
2020-07-16 23:25:07 +02:00
|
|
|
%patch4 -p1
|
2023-05-31 21:54:12 +02:00
|
|
|
%patch5 -p1
|
2019-11-11 13:10:41 +01:00
|
|
|
|
|
|
|
# Disable multithreaded build
|
|
|
|
rm .mvn/maven.config
|
|
|
|
|
|
|
|
# Don't try to get deps from local *maven* repo, use tycho resolved ones
|
|
|
|
for p in $(find org.eclipse.jgit.packaging -name pom.xml) ; do
|
|
|
|
grep -q dependencies $p && %pom_xpath_remove "pom:dependencies" $p
|
|
|
|
done
|
|
|
|
|
2020-07-01 13:57:40 +02:00
|
|
|
# Disable "errorprone" compiler
|
2021-07-30 12:15:11 +02:00
|
|
|
%pom_xpath_remove "pom:plugin[pom:artifactId='maven-compiler-plugin']/pom:configuration/pom:compilerArgs" pom.xml
|
|
|
|
%pom_xpath_remove "pom:plugin[pom:artifactId='maven-compiler-plugin']/pom:configuration/pom:annotationProcessorPaths" pom.xml
|
2020-07-01 13:57:40 +02:00
|
|
|
|
2019-11-11 13:10:41 +01:00
|
|
|
# Don't need target platform or repository modules with xmvn
|
|
|
|
%pom_disable_module org.eclipse.jgit.target org.eclipse.jgit.packaging
|
|
|
|
%pom_disable_module org.eclipse.jgit.repository org.eclipse.jgit.packaging
|
2020-07-01 13:57:40 +02:00
|
|
|
%pom_xpath_remove "pom:build/pom:pluginManagement/pom:plugins/pom:plugin/pom:configuration/pom:target" org.eclipse.jgit.packaging/pom.xml
|
2019-11-11 13:10:41 +01:00
|
|
|
|
|
|
|
# Don't build source features
|
|
|
|
%pom_disable_module org.eclipse.jgit.source.feature org.eclipse.jgit.packaging
|
2020-07-01 13:57:40 +02:00
|
|
|
|
|
|
|
# Don't build benchmark and coverage
|
|
|
|
%pom_disable_module org.eclipse.jgit.benchmarks
|
|
|
|
%pom_disable_module org.eclipse.jgit.coverage
|
|
|
|
|
|
|
|
# Use newer Felix dep
|
|
|
|
%pom_change_dep -r org.osgi:org.osgi.core org.osgi:osgi.core
|
2019-11-11 13:10:41 +01:00
|
|
|
|
|
|
|
# Remove unnecessary plugins for RPM builds
|
2020-07-01 13:57:40 +02:00
|
|
|
%pom_remove_plugin :jacoco-maven-plugin
|
|
|
|
%pom_remove_plugin :maven-javadoc-plugin
|
|
|
|
%pom_remove_plugin :maven-enforcer-plugin
|
2019-11-11 13:10:41 +01:00
|
|
|
%pom_remove_plugin :maven-enforcer-plugin org.eclipse.jgit.packaging
|
2020-07-01 13:57:40 +02:00
|
|
|
%pom_remove_plugin -r :japicmp-maven-plugin
|
|
|
|
|
|
|
|
# Don't attach shell script artifact
|
|
|
|
%pom_remove_plugin org.codehaus.mojo:build-helper-maven-plugin org.eclipse.jgit.pgm
|
2019-11-11 13:10:41 +01:00
|
|
|
|
2020-07-01 13:57:40 +02:00
|
|
|
# Remove org.apache.log4j
|
|
|
|
%pom_remove_dep log4j:log4j . org.eclipse.jgit.pgm
|
|
|
|
%pom_change_dep org.slf4j:slf4j-log4j12 org.slf4j:slf4j-simple . org.eclipse.jgit.pgm
|
2019-11-11 13:10:41 +01:00
|
|
|
|
|
|
|
pushd org.eclipse.jgit.packaging
|
|
|
|
%{mvn_package} "::pom::" __noinstall
|
|
|
|
popd
|
|
|
|
|
|
|
|
%build
|
|
|
|
pushd org.eclipse.jgit.packaging
|
2020-04-08 22:13:20 +02:00
|
|
|
%{mvn_build} -j -f
|
2019-11-11 13:10:41 +01:00
|
|
|
popd
|
|
|
|
|
|
|
|
%install
|
|
|
|
pushd org.eclipse.jgit.packaging
|
|
|
|
%mvn_install
|
|
|
|
popd
|
2020-07-02 11:41:31 +02:00
|
|
|
xmvn-subst -R %{buildroot} %{_datadir}/eclipse/droplets/jgit
|
|
|
|
#%fdupes -s %{buildroot}%{_datadir}
|
2019-11-11 13:10:41 +01:00
|
|
|
|
|
|
|
%files -f org.eclipse.jgit.packaging/.mfiles
|
|
|
|
%license LICENSE
|
|
|
|
%doc README.md
|
|
|
|
|
|
|
|
%changelog
|