parent
6377a6ac57
commit
a967f062b9
@ -4,7 +4,7 @@
|
|||||||
|
|
||||||
Name: python-netaddr
|
Name: python-netaddr
|
||||||
Version: 0.7.18
|
Version: 0.7.18
|
||||||
Release: 8%{?dist}
|
Release: 9%{?dist}
|
||||||
Summary: A pure Python network address representation and manipulation library
|
Summary: A pure Python network address representation and manipulation library
|
||||||
|
|
||||||
License: BSD
|
License: BSD
|
||||||
@ -18,33 +18,30 @@ BuildRequires: python-sphinx
|
|||||||
BuildRequires: pytest
|
BuildRequires: pytest
|
||||||
Provides: python2-netaddr = %{version}-%{release}
|
Provides: python2-netaddr = %{version}-%{release}
|
||||||
|
|
||||||
|
%global desc A network address manipulation library for Python\
|
||||||
|
\
|
||||||
|
Provides support for:\
|
||||||
|
\
|
||||||
|
Layer 3 addresses\
|
||||||
|
\
|
||||||
|
* IPv4 and IPv6 addresses, subnets, masks, prefixes\
|
||||||
|
* iterating, slicing, sorting, summarizing and classifying IP networks\
|
||||||
|
* dealing with various ranges formats (CIDR, arbitrary ranges and globs, nmap)\
|
||||||
|
* set based operations (unions, intersections etc) over IP addresses and subnets\
|
||||||
|
* parsing a large variety of different formats and notations\
|
||||||
|
* looking up IANA IP block information\
|
||||||
|
* generating DNS reverse lookups\
|
||||||
|
* supernetting and subnetting\
|
||||||
|
\
|
||||||
|
Layer 2 addresses\
|
||||||
|
\
|
||||||
|
* representation and manipulation MAC addresses and EUI-64 identifiers\
|
||||||
|
* looking up IEEE organisational information (OUI, IAB)\
|
||||||
|
* generating derived IPv6 addresses
|
||||||
|
|
||||||
|
|
||||||
%description
|
%description
|
||||||
A pure Python network address representation and manipulation library.
|
%{desc}
|
||||||
|
|
||||||
netaddr provides a Pythonic way of working with :-
|
|
||||||
|
|
||||||
- IPv4 and IPv6 addresses and subnets
|
|
||||||
- MAC addresses, OUI and IAB identifiers, IEEE EUI-64 identifiers
|
|
||||||
- arbitrary (non-aligned) IP address ranges and IP address sets
|
|
||||||
- various non-CIDR IP range formats such as nmap and glob-style formats
|
|
||||||
|
|
||||||
Included are routines for :-
|
|
||||||
|
|
||||||
- generating, sorting and summarizing IP addresses and networks
|
|
||||||
- performing easy conversions between address notations and formats
|
|
||||||
- detecting, parsing and formatting network address representations
|
|
||||||
- performing set-based operations on groups of IP addresses and subnets
|
|
||||||
- working with arbitrary IP address ranges and formats
|
|
||||||
- accessing OUI and IAB organisational information published by IEEE
|
|
||||||
- accessing IP address and block information published by IANA
|
|
||||||
|
|
||||||
For details on the latest updates and changes, see :-
|
|
||||||
|
|
||||||
http://github.com/drkjam/netaddr/blob/rel-0.7.x/CHANGELOG
|
|
||||||
|
|
||||||
API documentation for the latest release is available here :-
|
|
||||||
|
|
||||||
http://packages.python.org/netaddr/
|
|
||||||
|
|
||||||
%if 0%{?with_python3}
|
%if 0%{?with_python3}
|
||||||
%package -n python3-netaddr
|
%package -n python3-netaddr
|
||||||
@ -55,50 +52,25 @@ BuildRequires: python3-sphinx
|
|||||||
BuildRequires: python3-pytest
|
BuildRequires: python3-pytest
|
||||||
|
|
||||||
%description -n python3-netaddr
|
%description -n python3-netaddr
|
||||||
A pure Python network address representation and manipulation library.
|
%{desc}
|
||||||
|
|
||||||
netaddr provides a Pythonic way of working with :-
|
|
||||||
|
|
||||||
- IPv4 and IPv6 addresses and subnets
|
|
||||||
- MAC addresses, OUI and IAB identifiers, IEEE EUI-64 identifiers
|
|
||||||
- arbitrary (non-aligned) IP address ranges and IP address sets
|
|
||||||
- various non-CIDR IP range formats such as nmap and glob-style formats
|
|
||||||
|
|
||||||
Included are routines for :-
|
|
||||||
|
|
||||||
- generating, sorting and summarizing IP addresses and networks
|
|
||||||
- performing easy conversions between address notations and formats
|
|
||||||
- detecting, parsing and formatting network address representations
|
|
||||||
- performing set-based operations on groups of IP addresses and subnets
|
|
||||||
- working with arbitrary IP address ranges and formats
|
|
||||||
- accessing OUI and IAB organisational information published by IEEE
|
|
||||||
- accessing IP address and block information published by IANA
|
|
||||||
|
|
||||||
For details on the latest updates and changes, see :-
|
|
||||||
|
|
||||||
http://github.com/drkjam/netaddr/blob/rel-0.7.x/CHANGELOG
|
|
||||||
|
|
||||||
API documentation for the latest release is available here :-
|
|
||||||
|
|
||||||
http://packages.python.org/netaddr/
|
|
||||||
%endif
|
%endif
|
||||||
|
|
||||||
%prep
|
%prep
|
||||||
%setup -q -n netaddr-%{version}
|
%setup -q -n netaddr-%{version}
|
||||||
|
|
||||||
# Make rpmlint happy, get rid of DOS line endings
|
# Make rpmlint happy, get rid of DOS line endings
|
||||||
%{__sed} -i 's/\r//' netaddr/*.py
|
sed -i 's/\r//' netaddr/*.py netaddr/ip/*.py netaddr/eui/*.idx
|
||||||
%{__sed} -i 's/\r//' netaddr/ip/*.py
|
rm runtests.py
|
||||||
%{__sed} -i 's/\r//' netaddr/eui/*.idx
|
|
||||||
rm -rf runtests.py
|
|
||||||
|
|
||||||
# Make rpmlint happy, rip out python shebang lines from most python
|
# Make rpmlint happy, rip out python shebang lines from most python
|
||||||
# modules
|
# modules
|
||||||
find netaddr -name "*.py" | \
|
find netaddr -name "*.py" | \
|
||||||
xargs sed -i -e '1 {/^#!\//d}'
|
xargs sed -i -e '1 {/^#!\//d}'
|
||||||
|
# Fix python executable
|
||||||
|
sed -i -e '1s,/usr/bin/env python,%{__python2} %{?py_shbang_opts},' netaddr/tools/netaddr
|
||||||
|
|
||||||
# Make rpmlint happy, fix permissions on documentation files
|
# Make rpmlint happy, fix permissions on documentation files
|
||||||
chmod 0644 README.md AUTHORS CHANGELOG COPYRIGHT INSTALL LICENSE PKG-INFO
|
chmod 0644 README.md AUTHORS CHANGELOG COPYRIGHT LICENSE PKG-INFO
|
||||||
|
|
||||||
%build
|
%build
|
||||||
%py2_build
|
%py2_build
|
||||||
@ -132,8 +104,8 @@ LANG=en_US.UTF-8 py.test-%{python3_version}
|
|||||||
%endif
|
%endif
|
||||||
|
|
||||||
%files
|
%files
|
||||||
%license COPYRIGHT
|
%license COPYRIGHT LICENSE
|
||||||
%doc AUTHORS CHANGELOG INSTALL LICENSE PKG-INFO
|
%doc AUTHORS CHANGELOG
|
||||||
%doc README.md docs/html
|
%doc README.md docs/html
|
||||||
%{python2_sitelib}/*
|
%{python2_sitelib}/*
|
||||||
%{_bindir}/netaddr
|
%{_bindir}/netaddr
|
||||||
@ -141,13 +113,17 @@ LANG=en_US.UTF-8 py.test-%{python3_version}
|
|||||||
%if 0%{?with_python3}
|
%if 0%{?with_python3}
|
||||||
%files -n python3-netaddr
|
%files -n python3-netaddr
|
||||||
%license COPYRIGHT
|
%license COPYRIGHT
|
||||||
%doc AUTHORS CHANGELOG INSTALL LICENSE PKG-INFO
|
%doc AUTHORS CHANGELOG
|
||||||
%doc README.md docs/python3/html
|
%doc README.md docs/python3/html
|
||||||
%{python3_sitelib}/*
|
%{python3_sitelib}/*
|
||||||
%{_bindir}/netaddr3
|
%{_bindir}/netaddr3
|
||||||
%endif
|
%endif
|
||||||
|
|
||||||
%changelog
|
%changelog
|
||||||
|
* Sun Nov 13 2016 Orion Poplawski <orion@cora.nwra.com> - 0.7.18-9
|
||||||
|
- Update description
|
||||||
|
- Fix netaddr shebang (bug #1394046)
|
||||||
|
|
||||||
* Thu Nov 10 2016 Orion Poplawski <orion@cora.nwra.com> - 0.7.18-8
|
* Thu Nov 10 2016 Orion Poplawski <orion@cora.nwra.com> - 0.7.18-8
|
||||||
- Use updated python macros
|
- Use updated python macros
|
||||||
- Use %%license
|
- Use %%license
|
||||||
|
Loading…
Reference in New Issue
Block a user