2007-01-16 00:17:50 +01:00
|
|
|
#
|
2012-02-18 02:51:40 +01:00
|
|
|
# spec file for package iputils
|
2007-01-16 00:17:50 +01:00
|
|
|
#
|
2018-01-07 03:28:26 +01:00
|
|
|
# Copyright (c) 2018 SUSE LINUX GmbH, Nuernberg, Germany.
|
2007-01-16 00:17:50 +01:00
|
|
|
#
|
2008-09-05 02:54:56 +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.
|
|
|
|
|
2007-01-16 00:17:50 +01:00
|
|
|
# Please submit bugfixes or comments via http://bugs.opensuse.org/
|
|
|
|
#
|
|
|
|
|
2008-09-05 02:54:56 +02:00
|
|
|
|
2007-01-16 00:17:50 +01:00
|
|
|
Name: iputils
|
2017-09-12 15:53:00 +02:00
|
|
|
Version: s20161105
|
2012-02-18 02:51:40 +01:00
|
|
|
Release: 0
|
2017-11-13 19:09:26 +01:00
|
|
|
Summary: IPv4 and IPv6 Networking Utilities
|
|
|
|
License: BSD-3-Clause AND GPL-2.0+
|
|
|
|
Group: Productivity/Networking/Other
|
2015-12-03 02:18:20 +01:00
|
|
|
Url: https://github.com/iputils/iputils
|
2017-12-11 01:05:41 +01:00
|
|
|
Source0: https://github.com/iputils/iputils/archive/%{version}.tar.gz
|
|
|
|
Source1: rarpd.service
|
2015-12-03 02:18:20 +01:00
|
|
|
Patch8: iputils-sec-ping-unblock.diff
|
|
|
|
Patch9: iputils-ping-interrupt.diff
|
2015-04-21 11:53:13 +02:00
|
|
|
# PATCH-FIX-UPSTREAM iputils-remove-bogus-check-required-for-2.4.9-kernels.patch tiwai@suse.de - boo#927831
|
|
|
|
Patch10: iputils-remove-bogus-check-required-for-2.4.9-kernels.patch
|
2018-01-07 03:28:26 +01:00
|
|
|
Patch11: iputils-ping-fix-pmtu-for-ipv6.patch
|
2017-11-13 19:09:26 +01:00
|
|
|
BuildRequires: docbook_3
|
|
|
|
BuildRequires: iso_ent
|
|
|
|
BuildRequires: libcap-devel
|
|
|
|
BuildRequires: libopenssl-devel
|
|
|
|
BuildRequires: opensp
|
|
|
|
BuildRequires: perl-SGMLS
|
|
|
|
BuildRequires: pkgconfig
|
2017-12-11 01:05:41 +01:00
|
|
|
BuildRequires: systemd-rpm-macros
|
2017-11-13 19:09:26 +01:00
|
|
|
# For Makefile modifications
|
|
|
|
BuildRequires: sed
|
|
|
|
BuildRequires: pkgconfig(libidn)
|
|
|
|
Requires(pre): permissions
|
2016-05-23 17:21:37 +02:00
|
|
|
# I have spotted at least two packages (yast-printer and dhcp-client) that need
|
|
|
|
# /bin/ping and /sbin/arping but they do not seem to use them with absolute
|
|
|
|
# paths so we may be lukcy and no further changes are necessary.
|
|
|
|
Provides: /bin/ping
|
|
|
|
Provides: /sbin/arping
|
2007-01-16 00:17:50 +01:00
|
|
|
|
|
|
|
%description
|
|
|
|
This package contains some small network tools for IPv4 and IPv6 like
|
2017-09-12 15:53:00 +02:00
|
|
|
rdisc, ping, arping and tracepath.
|
2007-01-16 00:17:50 +01:00
|
|
|
|
2017-11-28 23:18:35 +01:00
|
|
|
%package -n rarpd
|
|
|
|
Summary: Reverse Address Resolution Protocol Daemon
|
|
|
|
Group: Productivity/Networking/System
|
2017-12-11 01:05:41 +01:00
|
|
|
%systemd_requires
|
2017-11-28 23:18:35 +01:00
|
|
|
|
|
|
|
%description -n rarpd
|
|
|
|
Rarpd listens on the Ethernet for broadcast packets asking for reverse
|
|
|
|
address resolution. These packets are sent by hosts at boot time to find
|
|
|
|
out their IP addresses.
|
|
|
|
|
2007-01-16 00:17:50 +01:00
|
|
|
%prep
|
2010-11-04 16:51:08 +01:00
|
|
|
%setup -q
|
2014-01-25 15:10:50 +01:00
|
|
|
%patch8 -p1
|
|
|
|
%patch9 -p1
|
2015-04-21 11:53:13 +02:00
|
|
|
%patch10 -p1
|
2018-01-07 03:28:26 +01:00
|
|
|
%patch11
|
2007-01-16 00:17:50 +01:00
|
|
|
|
|
|
|
%build
|
|
|
|
|
2016-05-23 17:21:37 +02:00
|
|
|
# Drop LASTTAG variable since it needs git and it's not used for regular
|
|
|
|
# building
|
|
|
|
sed -i '/^LASTTAG:=/d' Makefile
|
|
|
|
# Do not link against nettle
|
|
|
|
sed -i '/^USE_NETTLE/s/yes/no/' Makefile
|
|
|
|
|
|
|
|
# Export CFLAGS so we can also benefit from the ones the Makefile sets for us
|
|
|
|
# Instead of overriding all of them.
|
|
|
|
export CFLAGS='%{optflags} -fpie'
|
|
|
|
# Pulled-in by the LINK.o variable.
|
|
|
|
export LDFLAGS='-pie -Wl,-z,relro,-z,now'
|
|
|
|
|
|
|
|
# Build only selected apps
|
|
|
|
make %{?_smp_mflags} arping clockdiff ping rdisc tracepath \
|
2017-11-13 19:09:26 +01:00
|
|
|
rarpd man
|
2010-07-14 14:07:32 +02:00
|
|
|
|
2007-01-16 00:17:50 +01:00
|
|
|
%install
|
2017-11-13 19:09:26 +01:00
|
|
|
mkdir -p %{buildroot}/%{_sbindir}
|
|
|
|
mkdir -p %{buildroot}/%{_bindir}
|
|
|
|
install arping %{buildroot}/%{_sbindir}
|
|
|
|
install clockdiff %{buildroot}/%{_sbindir}
|
2017-11-28 23:18:35 +01:00
|
|
|
install rarpd %{buildroot}/%{_sbindir}
|
2017-12-11 09:46:34 +01:00
|
|
|
install rdisc %{buildroot}/%{_sbindir}
|
2016-05-23 17:21:37 +02:00
|
|
|
# boo#795788
|
2017-11-13 19:09:26 +01:00
|
|
|
install tracepath %{buildroot}/%{_bindir}
|
2017-11-28 23:18:35 +01:00
|
|
|
install ping %{buildroot}/%{_bindir}
|
2017-01-04 22:38:41 +01:00
|
|
|
# boo#1017616
|
2017-11-13 19:09:26 +01:00
|
|
|
ln -sf %{_bindir}/ping %{buildroot}/%{_bindir}/ping6
|
|
|
|
ln -sf %{_bindir}/tracepath %{buildroot}/%{_bindir}/tracepath6
|
2017-01-04 22:38:41 +01:00
|
|
|
|
2016-05-23 17:21:37 +02:00
|
|
|
#UsrMerge
|
|
|
|
# We still have reverse dependencies using /sbin/* or /bin/*
|
|
|
|
# so keep these symlinks for now. They are slowly being fixed
|
|
|
|
# but lets not just break them yet.
|
2017-11-13 19:09:26 +01:00
|
|
|
mkdir -p %{buildroot}/{bin,sbin}
|
|
|
|
ln -sf %{_sbindir}/arping %{buildroot}/sbin
|
|
|
|
ln -sf %{_sbindir}/clockdiff %{buildroot}/sbin
|
2017-11-28 23:18:35 +01:00
|
|
|
ln -sf %{_sbindir}/rarpd %{buildroot}/sbin
|
2017-12-11 09:46:34 +01:00
|
|
|
ln -sf %{_sbindir}/rdisc %{buildroot}/sbin
|
2017-11-13 19:09:26 +01:00
|
|
|
ln -sf %{_bindir}/tracepath %{buildroot}/bin
|
|
|
|
ln -sf %{_bindir}/ping %{buildroot}/bin
|
|
|
|
ln -sf %{_bindir}/ping6 %{buildroot}/bin
|
|
|
|
ln -sf %{_bindir}/tracepath6 %{buildroot}/bin
|
2016-05-23 17:21:37 +02:00
|
|
|
#EndUsrMerge
|
|
|
|
|
2017-11-13 19:09:26 +01:00
|
|
|
mkdir -p %{buildroot}/%{_mandir}/man8
|
2017-12-11 09:21:19 +01:00
|
|
|
# Remove conflicting / unused manpages
|
|
|
|
rm doc/ninfod* doc/pg3* doc/rdisc* doc/tftpd* doc/traceroute*
|
2016-05-23 17:21:37 +02:00
|
|
|
# Install the rest
|
2017-11-13 19:09:26 +01:00
|
|
|
install -m 644 doc/*.8 %{buildroot}%{_mandir}/man8/
|
2007-01-16 00:17:50 +01:00
|
|
|
|
2017-12-11 01:05:41 +01:00
|
|
|
# Install rarp service and create rc compat symling
|
|
|
|
install -Dpm 0644 %{SOURCE1} %{buildroot}/%{_unitdir}/rarpd.service
|
2017-12-11 09:46:34 +01:00
|
|
|
ln -s %{_sbindir}/service %{buildroot}%{_sbindir}/rcrarpd
|
2017-12-11 01:05:41 +01:00
|
|
|
|
2010-11-04 16:51:08 +01:00
|
|
|
%post
|
2016-05-23 17:21:37 +02:00
|
|
|
%set_permissions %{_bindir}/ping
|
2010-11-04 16:51:08 +01:00
|
|
|
|
|
|
|
%verifyscript
|
2016-05-23 17:21:37 +02:00
|
|
|
%verify_permissions -e %{_bindir}/ping
|
2010-11-04 16:51:08 +01:00
|
|
|
|
2017-12-11 01:05:41 +01:00
|
|
|
%pre -n rarpd
|
|
|
|
%service_add_pre rarpd.service
|
|
|
|
|
|
|
|
%post -n rarpd
|
|
|
|
%service_add_post rarpd.service
|
|
|
|
|
|
|
|
%preun -n rarpd
|
|
|
|
%service_del_preun rarpd.service
|
|
|
|
|
|
|
|
%postun -n rarpd
|
|
|
|
%service_del_postun rarpd.service
|
|
|
|
|
2007-01-16 00:17:50 +01:00
|
|
|
%files
|
|
|
|
%doc RELNOTES
|
2017-11-30 09:53:47 +01:00
|
|
|
%verify(not mode caps) %attr(0755,root,root) %{_bindir}/ping
|
2017-01-04 22:38:41 +01:00
|
|
|
%{_bindir}/ping6
|
2012-02-18 02:51:40 +01:00
|
|
|
%{_sbindir}/arping
|
|
|
|
%{_sbindir}/clockdiff
|
2016-05-23 17:21:37 +02:00
|
|
|
%{_bindir}/tracepath
|
|
|
|
%{_bindir}/tracepath6
|
2017-12-11 09:46:34 +01:00
|
|
|
%{_sbindir}/rdisc
|
2016-05-23 17:21:37 +02:00
|
|
|
#UsrMerge
|
2017-11-28 23:18:35 +01:00
|
|
|
/bin/ping
|
|
|
|
/bin/ping6
|
|
|
|
/bin/tracepath
|
|
|
|
/bin/tracepath6
|
|
|
|
/sbin/arping
|
|
|
|
/sbin/clockdiff
|
2017-12-11 09:46:34 +01:00
|
|
|
/sbin/rdisc
|
2017-11-28 23:18:35 +01:00
|
|
|
#EndUsrMerge
|
|
|
|
%{_mandir}/man8/arping.8%{ext_man}
|
|
|
|
%{_mandir}/man8/clockdiff.8%{ext_man}
|
|
|
|
%{_mandir}/man8/ping.8%{ext_man}
|
|
|
|
%{_mandir}/man8/tracepath.8%{ext_man}
|
|
|
|
#EndUsrMerge
|
|
|
|
|
|
|
|
%files -n rarpd
|
|
|
|
%{_sbindir}/rarpd
|
2017-12-11 01:05:41 +01:00
|
|
|
%{_sbindir}/rcrarpd
|
|
|
|
%{_unitdir}/rarpd.service
|
2017-11-28 23:18:35 +01:00
|
|
|
#UsrMerge
|
|
|
|
/sbin/rarpd
|
2016-05-23 17:21:37 +02:00
|
|
|
#EndUsrMerge
|
2017-11-28 23:18:35 +01:00
|
|
|
%{_mandir}/man8/rarpd.8%{ext_man}
|
2007-01-16 00:17:50 +01:00
|
|
|
|
2007-03-06 19:08:15 +01:00
|
|
|
%changelog
|