2009-05-01 14:01:21 +02:00
|
|
|
#
|
2012-10-17 07:13:45 +02:00
|
|
|
# spec file for package jsch
|
2009-05-01 14:01:21 +02:00
|
|
|
#
|
2024-01-12 10:37:12 +01:00
|
|
|
# Copyright (c) 2024 SUSE LLC
|
2009-05-01 14:01: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.
|
|
|
|
|
2019-09-20 14:18:40 +02:00
|
|
|
# Please submit bugfixes or comments via https://bugs.opensuse.org/
|
2009-05-01 14:01:21 +02:00
|
|
|
#
|
|
|
|
|
|
|
|
|
|
|
|
Name: jsch
|
2024-01-12 10:37:12 +01:00
|
|
|
Version: 0.2.15
|
2012-10-17 07:13:45 +02:00
|
|
|
Release: 0
|
2009-05-01 14:01:21 +02:00
|
|
|
Summary: Pure Java implementation of SSH2
|
2011-12-06 18:20:52 +01:00
|
|
|
License: BSD-3-Clause
|
2012-10-17 07:13:45 +02:00
|
|
|
Group: Development/Libraries/Java
|
2023-06-02 12:16:48 +02:00
|
|
|
URL: https://github.com/mwiede/jsch/
|
2023-05-30 18:09:21 +02:00
|
|
|
Source0: https://github.com/mwiede/%{name}/archive/refs/tags/%{name}-%{version}.tar.gz
|
|
|
|
Source1: %{name}-build.xml
|
|
|
|
Patch0: jsch-junixsocket.patch
|
2023-05-30 18:16:48 +02:00
|
|
|
Patch1: jsch-log4j.patch
|
2012-10-17 07:13:45 +02:00
|
|
|
BuildRequires: ant
|
2024-01-12 10:37:12 +01:00
|
|
|
BuildRequires: bouncycastle >= 1.77
|
2020-04-07 15:53:37 +02:00
|
|
|
BuildRequires: fdupes
|
2023-06-02 12:20:13 +02:00
|
|
|
# We need this for module-info.class
|
2023-06-02 12:16:48 +02:00
|
|
|
BuildRequires: java-devel >= 9
|
2023-05-30 18:09:21 +02:00
|
|
|
BuildRequires: javapackages-local >= 6
|
|
|
|
BuildRequires: jna
|
|
|
|
BuildRequires: jna-contrib
|
|
|
|
BuildRequires: slf4j
|
|
|
|
# The jar still works with Java 8
|
|
|
|
Requires: java >= 1.8
|
2014-06-17 17:50:49 +02:00
|
|
|
BuildArch: noarch
|
2009-05-01 14:01:21 +02:00
|
|
|
|
|
|
|
%description
|
|
|
|
JSch allows you to connect to an sshd server and use port forwarding,
|
|
|
|
X11 forwarding, file transfer, etc., and you can integrate its
|
|
|
|
functionality into your own Java programs.
|
|
|
|
|
|
|
|
%package javadoc
|
|
|
|
Summary: Pure Java implementation of SSH2
|
|
|
|
Group: Development/Libraries/Java
|
|
|
|
|
|
|
|
%description javadoc
|
|
|
|
JSch allows you to connect to an sshd server and use port forwarding,
|
|
|
|
X11 forwarding, file transfer, etc., and you can integrate its
|
|
|
|
functionality into your own Java programs.
|
|
|
|
|
|
|
|
%package demo
|
|
|
|
Summary: Pure Java implementation of SSH2
|
|
|
|
Group: Development/Libraries/Java
|
|
|
|
|
|
|
|
%description demo
|
|
|
|
JSch allows you to connect to an sshd server and use port forwarding,
|
|
|
|
X11 forwarding, file transfer, etc., and you can integrate its
|
|
|
|
functionality into your own Java programs.
|
|
|
|
|
|
|
|
%prep
|
2023-05-30 18:09:21 +02:00
|
|
|
%setup -q -n %{name}-%{name}-%{version}
|
|
|
|
cp %{SOURCE1} build.xml
|
|
|
|
|
|
|
|
# We don't have junixsocket
|
|
|
|
%pom_remove_dep com.kohlschutter.junixsocket:
|
2023-05-30 18:16:48 +02:00
|
|
|
rm -f \
|
|
|
|
src/main/java/com/jcraft/jsch/JUnixSocketFactory.java
|
2017-09-08 10:30:48 +02:00
|
|
|
%patch0 -p1
|
2009-05-01 14:01:21 +02:00
|
|
|
|
2023-05-30 18:16:48 +02:00
|
|
|
# Do not depend on log4j
|
|
|
|
%pom_remove_dep org.apache.logging.log4j:
|
|
|
|
rm -f \
|
|
|
|
src/main/java/com/jcraft/jsch/Log4j2Logger.java \
|
|
|
|
src/test/java/com/jcraft/jsch/Log4j2LoggerTest.java
|
|
|
|
%patch1 -p1
|
|
|
|
|
2009-05-01 14:01:21 +02:00
|
|
|
%build
|
2023-05-30 18:09:21 +02:00
|
|
|
mkdir -p lib
|
2023-05-30 18:16:48 +02:00
|
|
|
build-jar-repository -s lib jna jna-platform slf4j/api bcprov
|
2023-06-02 14:07:13 +02:00
|
|
|
%{ant} jar javadoc
|
2009-05-01 14:01:21 +02:00
|
|
|
|
|
|
|
%install
|
|
|
|
# jars
|
2023-05-30 18:09:21 +02:00
|
|
|
install -Dpm 644 target/%{name}-*.jar %{buildroot}%{_javadir}/%{name}.jar
|
2020-04-07 15:53:37 +02:00
|
|
|
|
|
|
|
# pom
|
|
|
|
install -d -m 755 %{buildroot}%{_mavenpomdir}
|
2023-05-30 18:09:21 +02:00
|
|
|
%{mvn_install_pom} pom.xml %{buildroot}%{_mavenpomdir}/%{name}.pom
|
|
|
|
%add_maven_depmap %{name}.pom %{name}.jar -a com.jcraft:jsch
|
2014-06-17 17:50:49 +02:00
|
|
|
|
2009-05-01 14:01:21 +02:00
|
|
|
# javadoc
|
2020-04-07 15:53:37 +02:00
|
|
|
install -dm 755 %{buildroot}%{_javadocdir}/%{name}
|
2023-05-30 18:09:21 +02:00
|
|
|
cp -pr target/site/apidocs/* %{buildroot}%{_javadocdir}/%{name}
|
2020-04-07 15:53:37 +02:00
|
|
|
%fdupes -s %{buildroot}%{_javadocdir}/%{name}
|
2014-06-17 17:50:49 +02:00
|
|
|
|
2009-05-01 14:01:21 +02:00
|
|
|
# examples
|
|
|
|
install -dm 755 %{buildroot}%{_datadir}/%{name}
|
|
|
|
cp -pr examples/* %{buildroot}%{_datadir}/%{name}
|
2020-04-07 15:53:37 +02:00
|
|
|
%fdupes -s %{buildroot}%{_datadir}/%{name}
|
2009-05-01 14:01:21 +02:00
|
|
|
|
2020-04-07 15:53:37 +02:00
|
|
|
%files -f .mfiles
|
|
|
|
%license LICENSE.txt
|
2009-05-01 14:01:21 +02:00
|
|
|
|
|
|
|
%files javadoc
|
|
|
|
%{_javadocdir}/%{name}
|
|
|
|
|
|
|
|
%files demo
|
|
|
|
%{_datadir}/%{name}
|
|
|
|
|
|
|
|
%changelog
|