File python-pyip.spec of Package python-pyip

#
# spec file for package python-pyip
#
# 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/


Name:           python-pyip
Version:        0.7
Release:        0
License:        Python-2.0
Summary:        Assemble/disassemble raw ip packet
Url:            https://sourceforge.net/projects/pyip
Group:          Development/Languages/Python
Source:         https://pypi.python.org/packages/source/p/pyip/pyip-%{version}.tar.gz
Patch:          zenoss.patch
BuildRequires:  python-devel
BuildRoot:      %{_tmppath}/%{name}-%{version}-build
%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
pyip is a Python package offering assembling/disassembling of raw ip packet,
including ip, udp, and icmp. Also it includes 2 utilities based on raw ip, 
traceroute and ping.

The primary motivation for this project is to fill the blank in Python,
i.e., handling raw ip packet. Meanwhile, the utility 'traceroute' is intended 
to be port of Unix 'traceroute' to Windows platform, as Windows' tracert has 
only very limited command line options compared with Unix 'traceroute'.

%prep
%setup -q -n pyip-%{version}
%patch

%build
python setup.py build

%install
python setup.py install --prefix=%{_prefix} --root=%{buildroot}

%files
%defattr(-,root,root,-)
%doc LICENSE
%{python_sitelib}/*

%changelog
openSUSE Build Service is sponsored by