File redir.spec of Package redir

#
# spec file for package redir
#
# Copyright (c) 2020 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/
#


Name:           redir
Version:        3.3
Release:        0
Summary:        TCP port redirector
License:        GPL-2.0-or-later
# FIXME: use correct group or remove it, see "https://en.opensuse.org/openSUSE:Package_group_guidelines"
Group:          Applications/Internet
URL:            https://github.com/troglobit/redir
Source:         https://github.com/troglobit/redir/releases/download/v%{version}/redir-%{version}.tar.xz
BuildRequires:  autoconf
BuildRequires:  automake
BuildRequires:  libtool
BuildRequires:  tcpd-devel
%if 0%{?suse_version} >= 1230
BuildRequires:  libwrap0
BuildRequires:  tcpd
%endif

%description
This is a TCP port redirector for UNIX. It can be run under inetd or
as standalone (in which case it handles multiple connections). It is 8 bit clean,
not limited to line mode, is small and lightweight. If you want access control,
run it under xinetd, or inetd with TCP wrappers.

Redir listens for TCP connections on a given port, and, when it recieves a
connection, then connects to a given destination address:port, and pass
data between them. It finds most of its applications in traversing firewalls,
but, of course, there are other uses.

%prep
%setup -q

%build
%configure
make %{?_smp_mflags}

%install
%make_install
rm -rf %{buildroot}%{_datadir}/doc/%{name}

%files
%defattr(-, root, root, 0755)
%doc *.md *.txt
%{_mandir}/man?/*
%{_bindir}/*

%changelog
openSUSE Build Service is sponsored by