Summary: Regulatory Daemon for the Intel PRO/Wireless 3945ABG Network Connection
Name: ipw3945d
Version: 1.7.22
Release: 1%{?_dist_release}
License: distributable
Group: System Environment/Daemons
URL: http://bughost.org/ipw3945/
Source0: http://bughost.org/ipw3945/daemon/%{name}-%{version}.tgz
Source1: ipw3945d.init
BuildRoot: %{_tmppath}/%{name}-%{version}-root
ExclusiveArch: %{ix86} x86_64

Vendor: Project Vine
Distribution: Vine Linux
Packager: Daisuke SUZUKI <daisuke@linux.or.jp>

%description
The regulatory daemon is responsible for controlling and configuring
aspects of the hardware required to operate the device within
compliance of various regulatory agencies.  This includes controlling
which channels are allowed to do active/passive scanning, transmit
power levels, which channels are allowed to be transmitted on, and
support for IEEE 802.11h (DFS and TPC).

%prep
%setup -q

%install
rm -rf %{buildroot}
mkdir -p %{buildroot}/sbin
%ifarch %{ix86}
install -p x86/ipw3945d %{buildroot}/sbin/
%endif
%ifarch x86_64
install -p x86_64/ipw3945d %{buildroot}/sbin/
%endif
mkdir -p %{buildroot}%{_sysconfdir}/rc.d/init.d
install -p -m 0755 %{SOURCE1} \
   %{buildroot}%{_sysconfdir}/rc.d/init.d/ipw3945d

%post
/sbin/chkconfig --add ipw3945d

%preun
if [ $1 -eq 0 ]; then
    /sbin/service ipw3945d stop &>/dev/null || :
    /sbin/chkconfig --del ipw3945d
fi
	
%postun
if [ $1 -ge 1 ]; then
    /sbin/service ipw3945d condrestart &>/dev/null || :
fi
	    
%clean
rm -rf %{buildroot}


%files
%defattr(-,root,root,-)
%doc LICENSE* README*
%{_sysconfdir}/rc.d/init.d/ipw3945d
/sbin/ipw3945d


%changelog
* Sun Sep 28 2008 Shu KONNO <owa@bg.wakwak.com> 1.7.22-1vl5
- applied new versioning policy

* Sun Dec 16 2007 Daisuke SUZUKI <daisuke@linux.or.jp> 1.7.22-0vl3
- update initscript
  - do not start ipw3945d if 3945ABG device not found.
  - do not "killproc" if ipw3945d is not running.
    
* Mon Apr 02 2007 Daisuke SUZUKI <daisuke@linux.or.jp> 1.7.22-0vl2
- modify initscript to start ipw3945d before initializing network.

* Mon Apr 02 2007 Daisuke SUZUKI <daisuke@linux.or.jp> 1.7.22-0vl1
- initial build for Vine Linux based on ATrpms package

* Fri Sep 15 2006 Axel Thimm <Axel.Thimm@ATrpms.net> - 1.7.22-4
- Update to 1.7.22.

* Thu Jun 15 2006 Axel Thimm <Axel.Thimm@ATrpms.net>
- Update to 1.7.19.

* Fri Mar 24 2006 Axel Thimm <Axel.Thimm@ATrpms.net>
- Initial build.

