15
0
forked from pool/python-ipy
Files
python-ipy/python-ipy.spec

59 lines
2.0 KiB
RPMSpec
Raw Normal View History

#
# spec file for package python-ipy
#
Accepting request 209871 from home:posophe:branches:devel:languages:python - Update to version 0.81 * Correct reverseName() for IPv6 addresses, so IP('::1').reverseName() returns correct. * Add network mask awareness to v46map() * Fix Python 3 errors in IPSet class * Make IPSet base class be object when MutableSet isn't available, fixing errors in Python 2.5 - Changes from 0.80 * Drop support of Python older than 2.4 * Python 3 does not need 2to3 conversion anymore (same code base) * Fix adding of non-adjacent networks: 192.168.0.0/24 + 192.168.255.0/24 made 192.168.0.0/23 * Fix adding networks that don't create a valid subnet: 192.168.1.0/24 + 192.168.2.0/24 made 192.168.1.0/23 * Fix adding with an IPv6 address where .int() was < 32 bits made IPy believe it was an IPv4 address: ::ffff:0/112 + ::1:0:0/112 made 255.255.0.0/111 * Add support of IPSets * Add support for subtracting a network range * Prevent IPv4 and IPv6 ranges from saying they contain each other * Add a .v46map() method to convert mapped address ranges such as IP('::ffff:192.168.1.1'); RFC 4291 * Change sort order to more natural: IPv4 before IPv6; less-specific prefixes first (/0 before /32) - Changes from 0.76 * ip == other and ip != other doesn't fail with an exception anymore if other is not a IP object * Add IP.get_mac() method: get the 802.3 MAC address from IPv6 RFC 2464 address. * Fix IP('::/0')[0]: return an IPv6 instead of an IPv4 address - Changes from 0.75 * IP('::/0').netmask() gives IP('::') instead of IP('0.0.0.0') - Changes from 0.74 * Fix tests for Python 3.1 and 3.2 * ip.__nonzero__() and (ipa in ipb) return a bool instead of 0 or 1 * IP('0.0.0.0/0') + IP('0.0.0.0/0') raises an error - Changes from 0.73 * Support Python 3: setup.py runs 2to3 * Update the ranges for IPv6 IPs * Fix reverseName() and reverseNames() for IPv4 in IPv6 addresses * Drop support of Python < 2.5 - Changes from 0.72 * Include examples and MANIFEST.in in source build (add them to MANIFEST.in) * Remove __rcsid__ constant from IPy module - Changes from 0.71 * Use xrange() instead of range() * Use isinstance(x, int) instead of type(x) == types.IntType * Prepare support of Python3 (use integer division: x // y) * Fix IP(long) constructor: ensure that the address is not too large * Constructor raise a TypeError if the type is not int, long, str or unicode * 223.0.0.0/8 is now public (belongs to APNIC) - Change Group for standard devel/languages/python - Remove AUTHOR section - Remove redundant %clean section - Remove --record=INSTALLED_FILES option and replace it with %{python_sitelib} in %files - Use download Url as source OBS-URL: https://build.opensuse.org/request/show/209871 OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-ipy?expand=0&rev=8
2013-12-08 21:18:55 +00:00
# Copyright (c) 2013 SUSE LINUX Products GmbH, Nuernberg, Germany.
#
# 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 http://bugs.opensuse.org/
#
%define modname IPy
Name: python-ipy
Accepting request 209871 from home:posophe:branches:devel:languages:python - Update to version 0.81 * Correct reverseName() for IPv6 addresses, so IP('::1').reverseName() returns correct. * Add network mask awareness to v46map() * Fix Python 3 errors in IPSet class * Make IPSet base class be object when MutableSet isn't available, fixing errors in Python 2.5 - Changes from 0.80 * Drop support of Python older than 2.4 * Python 3 does not need 2to3 conversion anymore (same code base) * Fix adding of non-adjacent networks: 192.168.0.0/24 + 192.168.255.0/24 made 192.168.0.0/23 * Fix adding networks that don't create a valid subnet: 192.168.1.0/24 + 192.168.2.0/24 made 192.168.1.0/23 * Fix adding with an IPv6 address where .int() was < 32 bits made IPy believe it was an IPv4 address: ::ffff:0/112 + ::1:0:0/112 made 255.255.0.0/111 * Add support of IPSets * Add support for subtracting a network range * Prevent IPv4 and IPv6 ranges from saying they contain each other * Add a .v46map() method to convert mapped address ranges such as IP('::ffff:192.168.1.1'); RFC 4291 * Change sort order to more natural: IPv4 before IPv6; less-specific prefixes first (/0 before /32) - Changes from 0.76 * ip == other and ip != other doesn't fail with an exception anymore if other is not a IP object * Add IP.get_mac() method: get the 802.3 MAC address from IPv6 RFC 2464 address. * Fix IP('::/0')[0]: return an IPv6 instead of an IPv4 address - Changes from 0.75 * IP('::/0').netmask() gives IP('::') instead of IP('0.0.0.0') - Changes from 0.74 * Fix tests for Python 3.1 and 3.2 * ip.__nonzero__() and (ipa in ipb) return a bool instead of 0 or 1 * IP('0.0.0.0/0') + IP('0.0.0.0/0') raises an error - Changes from 0.73 * Support Python 3: setup.py runs 2to3 * Update the ranges for IPv6 IPs * Fix reverseName() and reverseNames() for IPv4 in IPv6 addresses * Drop support of Python < 2.5 - Changes from 0.72 * Include examples and MANIFEST.in in source build (add them to MANIFEST.in) * Remove __rcsid__ constant from IPy module - Changes from 0.71 * Use xrange() instead of range() * Use isinstance(x, int) instead of type(x) == types.IntType * Prepare support of Python3 (use integer division: x // y) * Fix IP(long) constructor: ensure that the address is not too large * Constructor raise a TypeError if the type is not int, long, str or unicode * 223.0.0.0/8 is now public (belongs to APNIC) - Change Group for standard devel/languages/python - Remove AUTHOR section - Remove redundant %clean section - Remove --record=INSTALLED_FILES option and replace it with %{python_sitelib} in %files - Use download Url as source OBS-URL: https://build.opensuse.org/request/show/209871 OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-ipy?expand=0&rev=8
2013-12-08 21:18:55 +00:00
Version: 0.81
Release: 0
License: BSD-3-Clause
Summary: Class and Tools for Handling of IPv4 and IPv6 Addresses and Networks
Url: http://software.inl.fr/trac/wiki/IPy
Accepting request 209871 from home:posophe:branches:devel:languages:python - Update to version 0.81 * Correct reverseName() for IPv6 addresses, so IP('::1').reverseName() returns correct. * Add network mask awareness to v46map() * Fix Python 3 errors in IPSet class * Make IPSet base class be object when MutableSet isn't available, fixing errors in Python 2.5 - Changes from 0.80 * Drop support of Python older than 2.4 * Python 3 does not need 2to3 conversion anymore (same code base) * Fix adding of non-adjacent networks: 192.168.0.0/24 + 192.168.255.0/24 made 192.168.0.0/23 * Fix adding networks that don't create a valid subnet: 192.168.1.0/24 + 192.168.2.0/24 made 192.168.1.0/23 * Fix adding with an IPv6 address where .int() was < 32 bits made IPy believe it was an IPv4 address: ::ffff:0/112 + ::1:0:0/112 made 255.255.0.0/111 * Add support of IPSets * Add support for subtracting a network range * Prevent IPv4 and IPv6 ranges from saying they contain each other * Add a .v46map() method to convert mapped address ranges such as IP('::ffff:192.168.1.1'); RFC 4291 * Change sort order to more natural: IPv4 before IPv6; less-specific prefixes first (/0 before /32) - Changes from 0.76 * ip == other and ip != other doesn't fail with an exception anymore if other is not a IP object * Add IP.get_mac() method: get the 802.3 MAC address from IPv6 RFC 2464 address. * Fix IP('::/0')[0]: return an IPv6 instead of an IPv4 address - Changes from 0.75 * IP('::/0').netmask() gives IP('::') instead of IP('0.0.0.0') - Changes from 0.74 * Fix tests for Python 3.1 and 3.2 * ip.__nonzero__() and (ipa in ipb) return a bool instead of 0 or 1 * IP('0.0.0.0/0') + IP('0.0.0.0/0') raises an error - Changes from 0.73 * Support Python 3: setup.py runs 2to3 * Update the ranges for IPv6 IPs * Fix reverseName() and reverseNames() for IPv4 in IPv6 addresses * Drop support of Python < 2.5 - Changes from 0.72 * Include examples and MANIFEST.in in source build (add them to MANIFEST.in) * Remove __rcsid__ constant from IPy module - Changes from 0.71 * Use xrange() instead of range() * Use isinstance(x, int) instead of type(x) == types.IntType * Prepare support of Python3 (use integer division: x // y) * Fix IP(long) constructor: ensure that the address is not too large * Constructor raise a TypeError if the type is not int, long, str or unicode * 223.0.0.0/8 is now public (belongs to APNIC) - Change Group for standard devel/languages/python - Remove AUTHOR section - Remove redundant %clean section - Remove --record=INSTALLED_FILES option and replace it with %{python_sitelib} in %files - Use download Url as source OBS-URL: https://build.opensuse.org/request/show/209871 OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-ipy?expand=0&rev=8
2013-12-08 21:18:55 +00:00
Group: Development/Languages/Python
Source: https://pypi.python.org/packages/source/I/IPy/IPy-%{version}.tar.gz
BuildRequires: python-devel
BuildRoot: %{_tmppath}/%{name}-%{version}-build
Accepting request 209871 from home:posophe:branches:devel:languages:python - Update to version 0.81 * Correct reverseName() for IPv6 addresses, so IP('::1').reverseName() returns correct. * Add network mask awareness to v46map() * Fix Python 3 errors in IPSet class * Make IPSet base class be object when MutableSet isn't available, fixing errors in Python 2.5 - Changes from 0.80 * Drop support of Python older than 2.4 * Python 3 does not need 2to3 conversion anymore (same code base) * Fix adding of non-adjacent networks: 192.168.0.0/24 + 192.168.255.0/24 made 192.168.0.0/23 * Fix adding networks that don't create a valid subnet: 192.168.1.0/24 + 192.168.2.0/24 made 192.168.1.0/23 * Fix adding with an IPv6 address where .int() was < 32 bits made IPy believe it was an IPv4 address: ::ffff:0/112 + ::1:0:0/112 made 255.255.0.0/111 * Add support of IPSets * Add support for subtracting a network range * Prevent IPv4 and IPv6 ranges from saying they contain each other * Add a .v46map() method to convert mapped address ranges such as IP('::ffff:192.168.1.1'); RFC 4291 * Change sort order to more natural: IPv4 before IPv6; less-specific prefixes first (/0 before /32) - Changes from 0.76 * ip == other and ip != other doesn't fail with an exception anymore if other is not a IP object * Add IP.get_mac() method: get the 802.3 MAC address from IPv6 RFC 2464 address. * Fix IP('::/0')[0]: return an IPv6 instead of an IPv4 address - Changes from 0.75 * IP('::/0').netmask() gives IP('::') instead of IP('0.0.0.0') - Changes from 0.74 * Fix tests for Python 3.1 and 3.2 * ip.__nonzero__() and (ipa in ipb) return a bool instead of 0 or 1 * IP('0.0.0.0/0') + IP('0.0.0.0/0') raises an error - Changes from 0.73 * Support Python 3: setup.py runs 2to3 * Update the ranges for IPv6 IPs * Fix reverseName() and reverseNames() for IPv4 in IPv6 addresses * Drop support of Python < 2.5 - Changes from 0.72 * Include examples and MANIFEST.in in source build (add them to MANIFEST.in) * Remove __rcsid__ constant from IPy module - Changes from 0.71 * Use xrange() instead of range() * Use isinstance(x, int) instead of type(x) == types.IntType * Prepare support of Python3 (use integer division: x // y) * Fix IP(long) constructor: ensure that the address is not too large * Constructor raise a TypeError if the type is not int, long, str or unicode * 223.0.0.0/8 is now public (belongs to APNIC) - Change Group for standard devel/languages/python - Remove AUTHOR section - Remove redundant %clean section - Remove --record=INSTALLED_FILES option and replace it with %{python_sitelib} in %files - Use download Url as source OBS-URL: https://build.opensuse.org/request/show/209871 OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-ipy?expand=0&rev=8
2013-12-08 21:18:55 +00:00
%if 0%{?suse_version} && 0%{?suse_version} <= 1110
%{!?python_sitelib: %global python_sitelib %(python -c "from distutils.sysconfig import get_python_lib; print get_python_lib()")}
%else
BuildArch: noarch
%endif
%description
The IP class allows a comfortable parsing and handling for most
notations in use for IPv4 and IPv6 addresses and networks. It was
greatly inspired by RIPE's Perl module NET::IP's interface but
doesn't share the implementation. It doesn't share non-CIDR netmasks,
so funky stuff like a netmask of 0xffffff0f can't be done here.
%prep
%setup -q -n %{modname}-%{version}
%build
python setup.py build
%install
Accepting request 209871 from home:posophe:branches:devel:languages:python - Update to version 0.81 * Correct reverseName() for IPv6 addresses, so IP('::1').reverseName() returns correct. * Add network mask awareness to v46map() * Fix Python 3 errors in IPSet class * Make IPSet base class be object when MutableSet isn't available, fixing errors in Python 2.5 - Changes from 0.80 * Drop support of Python older than 2.4 * Python 3 does not need 2to3 conversion anymore (same code base) * Fix adding of non-adjacent networks: 192.168.0.0/24 + 192.168.255.0/24 made 192.168.0.0/23 * Fix adding networks that don't create a valid subnet: 192.168.1.0/24 + 192.168.2.0/24 made 192.168.1.0/23 * Fix adding with an IPv6 address where .int() was < 32 bits made IPy believe it was an IPv4 address: ::ffff:0/112 + ::1:0:0/112 made 255.255.0.0/111 * Add support of IPSets * Add support for subtracting a network range * Prevent IPv4 and IPv6 ranges from saying they contain each other * Add a .v46map() method to convert mapped address ranges such as IP('::ffff:192.168.1.1'); RFC 4291 * Change sort order to more natural: IPv4 before IPv6; less-specific prefixes first (/0 before /32) - Changes from 0.76 * ip == other and ip != other doesn't fail with an exception anymore if other is not a IP object * Add IP.get_mac() method: get the 802.3 MAC address from IPv6 RFC 2464 address. * Fix IP('::/0')[0]: return an IPv6 instead of an IPv4 address - Changes from 0.75 * IP('::/0').netmask() gives IP('::') instead of IP('0.0.0.0') - Changes from 0.74 * Fix tests for Python 3.1 and 3.2 * ip.__nonzero__() and (ipa in ipb) return a bool instead of 0 or 1 * IP('0.0.0.0/0') + IP('0.0.0.0/0') raises an error - Changes from 0.73 * Support Python 3: setup.py runs 2to3 * Update the ranges for IPv6 IPs * Fix reverseName() and reverseNames() for IPv4 in IPv6 addresses * Drop support of Python < 2.5 - Changes from 0.72 * Include examples and MANIFEST.in in source build (add them to MANIFEST.in) * Remove __rcsid__ constant from IPy module - Changes from 0.71 * Use xrange() instead of range() * Use isinstance(x, int) instead of type(x) == types.IntType * Prepare support of Python3 (use integer division: x // y) * Fix IP(long) constructor: ensure that the address is not too large * Constructor raise a TypeError if the type is not int, long, str or unicode * 223.0.0.0/8 is now public (belongs to APNIC) - Change Group for standard devel/languages/python - Remove AUTHOR section - Remove redundant %clean section - Remove --record=INSTALLED_FILES option and replace it with %{python_sitelib} in %files - Use download Url as source OBS-URL: https://build.opensuse.org/request/show/209871 OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-ipy?expand=0&rev=8
2013-12-08 21:18:55 +00:00
python setup.py install --prefix=%{_prefix} --root=%{buildroot}
Accepting request 209871 from home:posophe:branches:devel:languages:python - Update to version 0.81 * Correct reverseName() for IPv6 addresses, so IP('::1').reverseName() returns correct. * Add network mask awareness to v46map() * Fix Python 3 errors in IPSet class * Make IPSet base class be object when MutableSet isn't available, fixing errors in Python 2.5 - Changes from 0.80 * Drop support of Python older than 2.4 * Python 3 does not need 2to3 conversion anymore (same code base) * Fix adding of non-adjacent networks: 192.168.0.0/24 + 192.168.255.0/24 made 192.168.0.0/23 * Fix adding networks that don't create a valid subnet: 192.168.1.0/24 + 192.168.2.0/24 made 192.168.1.0/23 * Fix adding with an IPv6 address where .int() was < 32 bits made IPy believe it was an IPv4 address: ::ffff:0/112 + ::1:0:0/112 made 255.255.0.0/111 * Add support of IPSets * Add support for subtracting a network range * Prevent IPv4 and IPv6 ranges from saying they contain each other * Add a .v46map() method to convert mapped address ranges such as IP('::ffff:192.168.1.1'); RFC 4291 * Change sort order to more natural: IPv4 before IPv6; less-specific prefixes first (/0 before /32) - Changes from 0.76 * ip == other and ip != other doesn't fail with an exception anymore if other is not a IP object * Add IP.get_mac() method: get the 802.3 MAC address from IPv6 RFC 2464 address. * Fix IP('::/0')[0]: return an IPv6 instead of an IPv4 address - Changes from 0.75 * IP('::/0').netmask() gives IP('::') instead of IP('0.0.0.0') - Changes from 0.74 * Fix tests for Python 3.1 and 3.2 * ip.__nonzero__() and (ipa in ipb) return a bool instead of 0 or 1 * IP('0.0.0.0/0') + IP('0.0.0.0/0') raises an error - Changes from 0.73 * Support Python 3: setup.py runs 2to3 * Update the ranges for IPv6 IPs * Fix reverseName() and reverseNames() for IPv4 in IPv6 addresses * Drop support of Python < 2.5 - Changes from 0.72 * Include examples and MANIFEST.in in source build (add them to MANIFEST.in) * Remove __rcsid__ constant from IPy module - Changes from 0.71 * Use xrange() instead of range() * Use isinstance(x, int) instead of type(x) == types.IntType * Prepare support of Python3 (use integer division: x // y) * Fix IP(long) constructor: ensure that the address is not too large * Constructor raise a TypeError if the type is not int, long, str or unicode * 223.0.0.0/8 is now public (belongs to APNIC) - Change Group for standard devel/languages/python - Remove AUTHOR section - Remove redundant %clean section - Remove --record=INSTALLED_FILES option and replace it with %{python_sitelib} in %files - Use download Url as source OBS-URL: https://build.opensuse.org/request/show/209871 OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-ipy?expand=0&rev=8
2013-12-08 21:18:55 +00:00
%files
%defattr(-,root,root)
%doc AUTHORS COPYING ChangeLog README
Accepting request 209871 from home:posophe:branches:devel:languages:python - Update to version 0.81 * Correct reverseName() for IPv6 addresses, so IP('::1').reverseName() returns correct. * Add network mask awareness to v46map() * Fix Python 3 errors in IPSet class * Make IPSet base class be object when MutableSet isn't available, fixing errors in Python 2.5 - Changes from 0.80 * Drop support of Python older than 2.4 * Python 3 does not need 2to3 conversion anymore (same code base) * Fix adding of non-adjacent networks: 192.168.0.0/24 + 192.168.255.0/24 made 192.168.0.0/23 * Fix adding networks that don't create a valid subnet: 192.168.1.0/24 + 192.168.2.0/24 made 192.168.1.0/23 * Fix adding with an IPv6 address where .int() was < 32 bits made IPy believe it was an IPv4 address: ::ffff:0/112 + ::1:0:0/112 made 255.255.0.0/111 * Add support of IPSets * Add support for subtracting a network range * Prevent IPv4 and IPv6 ranges from saying they contain each other * Add a .v46map() method to convert mapped address ranges such as IP('::ffff:192.168.1.1'); RFC 4291 * Change sort order to more natural: IPv4 before IPv6; less-specific prefixes first (/0 before /32) - Changes from 0.76 * ip == other and ip != other doesn't fail with an exception anymore if other is not a IP object * Add IP.get_mac() method: get the 802.3 MAC address from IPv6 RFC 2464 address. * Fix IP('::/0')[0]: return an IPv6 instead of an IPv4 address - Changes from 0.75 * IP('::/0').netmask() gives IP('::') instead of IP('0.0.0.0') - Changes from 0.74 * Fix tests for Python 3.1 and 3.2 * ip.__nonzero__() and (ipa in ipb) return a bool instead of 0 or 1 * IP('0.0.0.0/0') + IP('0.0.0.0/0') raises an error - Changes from 0.73 * Support Python 3: setup.py runs 2to3 * Update the ranges for IPv6 IPs * Fix reverseName() and reverseNames() for IPv4 in IPv6 addresses * Drop support of Python < 2.5 - Changes from 0.72 * Include examples and MANIFEST.in in source build (add them to MANIFEST.in) * Remove __rcsid__ constant from IPy module - Changes from 0.71 * Use xrange() instead of range() * Use isinstance(x, int) instead of type(x) == types.IntType * Prepare support of Python3 (use integer division: x // y) * Fix IP(long) constructor: ensure that the address is not too large * Constructor raise a TypeError if the type is not int, long, str or unicode * 223.0.0.0/8 is now public (belongs to APNIC) - Change Group for standard devel/languages/python - Remove AUTHOR section - Remove redundant %clean section - Remove --record=INSTALLED_FILES option and replace it with %{python_sitelib} in %files - Use download Url as source OBS-URL: https://build.opensuse.org/request/show/209871 OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-ipy?expand=0&rev=8
2013-12-08 21:18:55 +00:00
%{python_sitelib}
%changelog