152a1a8
%{!?python_sitelib: %global python_sitelib %(%{__python} -c "from distutils.sysconfig import get_python_lib; print get_python_lib()")}
1985a70
1985a70
Name:           python-wifi
152a1a8
Version:        0.5.0
b192a75
Release:        3%{?dist}
1985a70
Summary:        Python binding for the wireless extensions
1985a70
1985a70
Group:          Development/Libraries
1985a70
License:        LGPLv2+
1985a70
URL:            https://developer.berlios.de/projects/pythonwifi/
152a1a8
Source0:        http://prdownload.berlios.de/pythonwifi/%{name}-%{version}.tar.bz2
1985a70
BuildRoot:      %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
1985a70
BuildArch:      noarch
1985a70
152a1a8
BuildRequires:  python-devel
152a1a8
BuildRequires:  python-setuptools
1985a70
1985a70
1985a70
%description
1985a70
Python-Wifi is a Python library that provides access to information about a
1985a70
W-LAN card's capabilities, like the wireless extensions written in C.
1985a70
1985a70
1985a70
%prep
1985a70
%setup -q
1985a70
1985a70
1985a70
%build
152a1a8
%{__python} setup.py build
1985a70
1985a70
1985a70
%install
1985a70
rm -rf %{buildroot}
152a1a8
%{__python} setup.py install -O1 --skip-build --root="%{buildroot}"
1985a70
# Fix permissions on examples
1985a70
chmod -x examples/*.py
1985a70
# Convert to utf-8
1985a70
for file in docs/AUTHORS docs/pywifi_english.tpp docs/pywifi.tpp; do
1985a70
    mv $file timestamp
1985a70
    iconv -f ISO-8859-1 -t UTF-8 -o $file timestamp
1985a70
    touch -r timestamp $file
1985a70
done
1985a70
1985a70
1985a70
%clean
1985a70
rm -rf %{buildroot}
1985a70
1985a70
1985a70
%files
1985a70
%defattr(-,root,root,-)
152a1a8
%doc README docs/AUTHORS docs/BUGS docs/ChangeLog
152a1a8
%doc docs/LICENSE* docs/NEWS docs/ROADMAP docs/TODO docs/VERSION 
152a1a8
%doc examples/ tests/
1985a70
%{python_sitelib}/pythonwifi/
1985a70
%{python_sitelib}/python_wifi*.egg-info
1985a70
1985a70
1985a70
%changelog
152a1a8
* Wed Dec 23 2009 Fabian Affolter <fabian@bernewireless.net> - 0.5.0-1
152a1a8
- Updated docs
152a1a8
- Updated BR
152a1a8
- Updated to new upstream version 0.5.0
152a1a8
b192a75
* Sun Jul 26 2009 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.3.1-3
b192a75
- Rebuilt for https://fedoraproject.org/wiki/Fedora_12_Mass_Rebuild
b192a75
1985a70
* Wed Feb 18 2009 Fabian Affolter <fabian@bernewireless.net> - 0.3.1-2
1985a70
- Changes acc. to bug #478300
1985a70
1985a70
* Sat Dec 27 2008 Fabian Affolter <fabian@bernewireless.net> - 0.3.1-1
1985a70
- Initial spec for Fedora