Blob Blame Raw
%{!?python_sitelib: %define python_sitelib %(%{__python} -c "from distutils.sysconfig import get_python_lib; print get_python_lib()")}

Name:           python-wifi
Version:        0.3.1
Release:        2%{?dist}
Summary:        Python binding for the wireless extensions

Group:          Development/Libraries
License:        LGPLv2+
BuildRoot:      %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
BuildArch:      noarch

BuildRequires:  python
BuildRequires:  python-setuptools-devel

Python-Wifi is a Python library that provides access to information about a
W-LAN card's capabilities, like the wireless extensions written in C.

%setup -q

python ./ build

rm -rf %{buildroot}
python install -O1 --skip-build --root="%{buildroot}"
# Fix permissions on examples
chmod -x examples/*.py
# Convert to utf-8
for file in docs/AUTHORS docs/pywifi_english.tpp docs/pywifi.tpp; do
    mv $file timestamp
    iconv -f ISO-8859-1 -t UTF-8 -o $file timestamp
    touch -r timestamp $file

rm -rf %{buildroot}

%doc ChangeLog LICENSE NEWS README docs/ examples/ tests/

* Wed Feb 18 2009 Fabian Affolter <> - 0.3.1-2
- Changes acc. to bug #478300

* Sat Dec 27 2008 Fabian Affolter <> - 0.3.1-1
- Initial spec for Fedora