File python-adns.spec of Package python-adns

# vim: set sw=4 ts=4 et:

# Copyright (c) 2011-2012 Pascal Bleser <pascal.bleser@opensuse.org>
#
# 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-adns
Version:        1.2.1+ipv6+20110629
Release:        0
Summary:        Python asynchronous resolver library
## https://github.com/lizter/adns-python-1.2.1-IPv6.git
Source:         adns-python-1.2.1-IPv6-20110629-6f067233b0e69937e1c8caf6ef71abc23f26367c.tar.bz2
URL:            http://code.google.com/p/adns-python/
Group:          Development/Libraries/Python
License:        GPL-2.0+
BuildRoot:      %{_tmppath}/build-%{name}-%{version}
BuildRequires:  python python-devel
BuildRequires:  libadns-devel >= 1.2
BuildRequires:  gcc make glibc-devel pkgconfig
BuildRequires:  perl
%py_requires

%description
Python interface to GNU adns asynchronous resolver library.

%prep
%setup -q -n "adns-python-1.2.1-IPv6"

find . -type f -name '*.py' | while read py; do
    %__perl -i -n -e 'print unless /^\#/ and $.==1' "$py"
done

%build
%__python ./setup.py build

%install
%__python ./setup.py install \
    --prefix="%{_prefix}" \
    --root="%{buildroot}" \
    --record-rpm=files.lst

%clean
%{?buildroot:%__rm -rf "%{buildroot}"}

%files -f files.lst
%defattr(-,root,root)
%doc GPL README ChangeLog

openSUSE Build Service is sponsored by