bump to 2.4.3, one spec for all branches
This commit is contained in:
parent
fb4e321c92
commit
8d9c87f80e
1
.gitignore
vendored
1
.gitignore
vendored
@ -4,3 +4,4 @@ scapy-2.0.0.10.tar.gz
|
||||
/scapy-2.3.3.tar.gz
|
||||
/scapy-2.4.0rc5.tar.gz
|
||||
/scapy-2.4.0.tar.gz
|
||||
/scapy-2.4.3.tar.gz
|
||||
|
||||
102
scapy.spec
102
scapy.spec
@ -1,58 +1,120 @@
|
||||
Name: scapy
|
||||
Version: 2.4.0
|
||||
Release: 8%{?dist}
|
||||
Version: 2.4.3
|
||||
Release: 1%{?dist}
|
||||
Summary: Interactive packet manipulation tool and network scanner
|
||||
|
||||
%global gituser secdev
|
||||
%global gitname scapy
|
||||
%global commit ae348f8611529fe20dcd703e2bd37f20322c4535
|
||||
%global commit 3047580162a9407ef05fe981983cacfa698f1159
|
||||
%global shortcommit %(c=%{commit}; echo ${c:0:7})
|
||||
|
||||
|
||||
License: GPLv2
|
||||
URL: http://www.secdev.org/projects/scapy/
|
||||
# https://github.com/secdev/scapy/releases
|
||||
# https://bitbucket.org/secdev/scapy/pull-request/80
|
||||
Source0: https://github.com/%{gituser}/%{gitname}/archive/v%{version}.tar.gz#/%{name}-%{version}.tar.gz
|
||||
Patch0: scapy-2.4.3-ethertypes.patch
|
||||
|
||||
%global common_desc \
|
||||
Scapy is a powerful interactive packet manipulation program built on top\
|
||||
of the Python interpreter. It can be used to forge or decode packets of\
|
||||
a wide number of protocols, send them over the wire, capture them, match\
|
||||
requests and replies, and much more.\
|
||||
|
||||
%bcond_with python2
|
||||
# Build also the python2 package
|
||||
%if %{with python2} || (0%{?fedora} && 0%{?fedora} <= 32 ) || ( 0%{?rhel} && 0%{?rhel} <= 8 )
|
||||
%global with_python2 1
|
||||
%endif
|
||||
|
||||
|
||||
BuildArch: noarch
|
||||
|
||||
BuildRequires: sed
|
||||
|
||||
%if 0%{?with_python2}
|
||||
BuildRequires: python2 >= 2.5
|
||||
BuildRequires: python2-devel >= 2.5
|
||||
%endif # if with_python2
|
||||
|
||||
BuildRequires: python%{python3_pkgversion}
|
||||
BuildRequires: python%{python3_pkgversion}-devel
|
||||
|
||||
#
|
||||
Recommends: tcpdump
|
||||
# Using database of manufactures /usr/share/wireshark/manuf
|
||||
Recommends: wireshark-cli
|
||||
|
||||
|
||||
%description
|
||||
Scapy is a powerful interactive packet manipulation program built on top
|
||||
of the Python interpreter. It can be used to forge or decode packets of
|
||||
a wide number of protocols, send them over the wire, capture them, match
|
||||
requests and replies, and much more.
|
||||
%{common_desc}
|
||||
|
||||
%if 0%{?with_python2}
|
||||
%package -n python2-%{name}
|
||||
Summary: Interactive packet manipulation tool and network scanner
|
||||
|
||||
%{?python_provide:%python_provide python2-%{name}}
|
||||
|
||||
%description -n python2-%{name}
|
||||
%{common_desc}
|
||||
|
||||
Recommends: python2-pyx
|
||||
Recommends: python2-matplotlib
|
||||
Recommends: ipython2
|
||||
%endif # if with_python2
|
||||
|
||||
|
||||
|
||||
%package -n python%{python3_pkgversion}-%{name}
|
||||
Summary: Interactive packet manipulation tool and network scanner
|
||||
|
||||
%{?python_provide:%python_provide python%{python3_pkgversion}-%{name}}
|
||||
Provides: %{name} = %{version}-%{release}
|
||||
|
||||
Recommends: PyX
|
||||
Recommends: python%{python3_pkgversion}-matplotlib
|
||||
Recommends: ipython3
|
||||
|
||||
%description -n python%{python3_pkgversion}-%{name}
|
||||
Scapy is a powerful interactive packet manipulation program built on top
|
||||
of the Python interpreter. It can be used to forge or decode packets of
|
||||
a wide number of protocols, send them over the wire, capture them, match
|
||||
requests and replies, and much more.
|
||||
%{common_desc}
|
||||
|
||||
|
||||
|
||||
%prep
|
||||
%autosetup -p 1 -n %{name}-%{version}
|
||||
|
||||
|
||||
|
||||
%build
|
||||
%if 0%{?with_python2}
|
||||
%py2_build
|
||||
%endif # if with_python2
|
||||
%py3_build
|
||||
|
||||
|
||||
|
||||
%install
|
||||
install -Dp -m0644 doc/scapy.1.gz %{buildroot}%{_mandir}/man1/scapy.1.gz
|
||||
install -dp -m0755 %{buildroot}%{_mandir}/man1
|
||||
install -Dp -m0644 doc/scapy.1* %{buildroot}%{_mandir}/man1/
|
||||
|
||||
%if 0%{?with_python2}
|
||||
%py2_install
|
||||
rm -f %{buildroot}%{python2_sitelib}/*egg-info/requires.txt
|
||||
|
||||
# Remove shebang
|
||||
for FILE in %{buildroot}%{python2_sitelib}/scapy/contrib/*.py \
|
||||
%{buildroot}%{python2_sitelib}/scapy/pipetool.py \
|
||||
%{buildroot}%{python2_sitelib}/scapy/layers/inet6.py \
|
||||
%{buildroot}%{python2_sitelib}/scapy/tools/check_asdis.py; do
|
||||
sed -i.orig -e 1d "${FILE}"
|
||||
touch -r "${FILE}.orig" "${FILE}"
|
||||
rm "${FILE}.orig"
|
||||
done
|
||||
|
||||
# Rename the executables
|
||||
mv -f %{buildroot}%{_bindir}/scapy %{buildroot}%{_bindir}/scapy2
|
||||
mv -f %{buildroot}%{_bindir}/UTscapy %{buildroot}%{_bindir}/UTscapy2
|
||||
%endif # if with_python2
|
||||
|
||||
%py3_install
|
||||
rm -f %{buildroot}%{python3_sitelib}/*egg-info/requires.txt
|
||||
@ -80,9 +142,19 @@ ln -s %{_bindir}/UTscapy3 %{buildroot}%{_bindir}/UTscapy
|
||||
# check
|
||||
# TODO: Need to fix/remove slow/failed test
|
||||
# cd test/
|
||||
# ./run_tests_py2 || true
|
||||
# ./run_tests_py3 || true
|
||||
|
||||
|
||||
%if 0%{?with_python2}
|
||||
%files -n python2-%{name}
|
||||
%doc %{_mandir}/man1/scapy.1*
|
||||
%{_bindir}/scapy2
|
||||
%{_bindir}/UTscapy2
|
||||
%{python2_sitelib}/scapy/
|
||||
%{python2_sitelib}/scapy-*.egg-info
|
||||
%endif # if with_python2
|
||||
|
||||
|
||||
%files -n python%{python3_pkgversion}-%{name}
|
||||
%doc %{_mandir}/man1/scapy.1*
|
||||
@ -96,6 +168,10 @@ ln -s %{_bindir}/UTscapy3 %{buildroot}%{_bindir}/UTscapy
|
||||
|
||||
|
||||
%changelog
|
||||
* Thu Sep 26 2019 Michal Ambroz <rebus _AT seznam.cz> - 2.4.3-1
|
||||
- bump to 2.4.3 release
|
||||
- change the python2 to conditional build to be able to keep one spec for all
|
||||
|
||||
* Fri Sep 20 2019 Miro Hrončok <mhroncok@redhat.com> - 2.4.0-8
|
||||
- Subpackage python2-scapy has been removed
|
||||
See https://fedoraproject.org/wiki/Changes/Mass_Python_2_Package_Removal
|
||||
|
||||
2
sources
2
sources
@ -1 +1 @@
|
||||
SHA512 (scapy-2.4.0.tar.gz) = 0fe80150cd83db7735c9d0b70ec832a4e68eb5160ad8559e9b1bd79c52a9950ef7c9555ea2a1ee1dc8df1f055a885c52552c29e304faf40250ce9c502a5f870a
|
||||
SHA512 (scapy-2.4.3.tar.gz) = 48bf86ed851f4b15d4f3b1e2668f1516fff712b67d709963cb986076cfeec0724e20b400a75368309f3d99a45d7b1082fd049fbb67edef0ab5d838e2ae141e44
|
||||
|
||||
Loading…
Reference in New Issue
Block a user