2011-11-29 09:17:14 +00:00
|
|
|
#
|
|
|
|
# spec file for package python-netifaces (Version 0.5)
|
|
|
|
#
|
|
|
|
# Copyright (c) 2011 Novell
|
|
|
|
# This file and all modifications and additions to the pristine
|
|
|
|
# package are under the same license as the package itself.
|
|
|
|
#
|
|
|
|
# Please submit bugfixes or comments via http://www.suse.de/feedback/
|
|
|
|
#
|
|
|
|
|
|
|
|
|
2011-11-29 09:21:43 +00:00
|
|
|
Name: python-netifaces
|
|
|
|
Version: 0.5
|
|
|
|
Release: 0
|
|
|
|
License: MIT
|
|
|
|
Summary: Portable network interface information
|
|
|
|
Url: http://alastairs-place.net/netifaces/
|
|
|
|
Group: Development/Languages/Python
|
|
|
|
Source: netifaces-%{version}.tar.bz2
|
|
|
|
BuildRequires: python-devel
|
|
|
|
BuildRequires: python-distribute
|
|
|
|
Provides: netifaces
|
|
|
|
BuildRoot: %{_tmppath}/%{name}-%{version}-build
|
|
|
|
%if 0%{?suse_version}
|
|
|
|
%py_requires
|
|
|
|
%endif
|
|
|
|
%{!?python_sitearch: %global python_sitearch %(python -c "from distutils.sysconfig import get_python_lib; print get_python_lib(1)")}
|
2011-11-29 09:17:14 +00:00
|
|
|
|
|
|
|
%description
|
|
|
|
netifaces provides a (hopefully portable-ish) way for Python programmers to
|
|
|
|
get access to a list of the network interfaces on the local machine, and to
|
|
|
|
obtain the addresses of those network interfaces.
|
|
|
|
|
|
|
|
The package has been tested on Mac OS X, Windows XP, Windows Vista, Linux and
|
|
|
|
Solaris. On Windows, it is currently not able to retrieve IPv6 addresses,
|
|
|
|
owing to shortcomings of the Windows API.
|
|
|
|
|
2011-11-29 09:21:43 +00:00
|
|
|
It should work on other UNIX-like systems provided they implement either
|
2011-11-29 09:17:14 +00:00
|
|
|
getifaddrs() or support the SIOCGIFxxx socket options, although the data
|
|
|
|
provided by the socket options is normally less complete.
|
|
|
|
|
|
|
|
%prep
|
2011-11-29 09:21:43 +00:00
|
|
|
%setup -q -n netifaces-%{version}
|
2011-11-29 09:17:14 +00:00
|
|
|
|
|
|
|
%build
|
2011-11-29 09:21:43 +00:00
|
|
|
python setup.py build
|
2011-11-29 09:17:14 +00:00
|
|
|
|
|
|
|
%install
|
2011-11-29 09:21:43 +00:00
|
|
|
python setup.py install --prefix=%{_prefix} --root=%{buildroot}
|
2011-11-29 09:17:14 +00:00
|
|
|
|
2011-11-29 09:21:43 +00:00
|
|
|
%files
|
2011-11-29 09:17:14 +00:00
|
|
|
%defattr(-,root,root,-)
|
|
|
|
%doc README
|
2011-11-29 09:21:43 +00:00
|
|
|
%{python_sitearch}/*
|
2011-11-29 09:17:14 +00:00
|
|
|
|
|
|
|
%changelog
|