18a72f9
%define         crda_version    1.1.0
18a72f9
%define         regdb_version   2009.04.17
a674751
a674751
Name:           crda
0549edf
Version:        %{crda_version}_%{regdb_version}
18a72f9
Release:        11%{?dist}
a674751
Summary:        Regulatory compliance daemon for 802.11 wireless networking
a674751
a674751
Group:          System Environment/Base
a674751
License:        BSD
a674751
URL:            http://www.linuxwireless.org/en/developers/Regulatory/CRDA
a674751
BuildRoot:      %{_tmppath}/%{name}-%{crda_version}-%{release}-root-%(%{__id_u} -n)
a674751
a674751
BuildRequires:  kernel-devel >= 2.6.27
a674751
BuildRequires:  libnl-devel >= 1.1
a674751
BuildRequires:  libgcrypt-devel
a674751
BuildRequires:  pkgconfig python m2crypto
a674751
f2d5862
Requires:       udev, iw
a674751
a674751
Source0:        http://wireless.kernel.org/download/crda/crda-%{crda_version}.tar.bz2
a674751
Source1:        http://wireless.kernel.org/download/wireless-regdb/wireless-regdb-%{regdb_version}.tar.bz2
af489f7
Source2:        setregdomain
af489f7
af489f7
Patch0:         regulatory-rules-setregdomain.patch
a674751
a674751
%description
a674751
CRDA acts as the udev helper for communication between the kernel
a674751
and userspace for regulatory compliance. It relies on nl80211
a674751
for communication. CRDA is intended to be run only through udev
a674751
communication from the kernel.
a674751
a674751
%prep
a674751
%setup -q -c
a674751
%setup -q -T -D -a 1
a674751
af489f7
%patch0 -p1 -b .setregdomain
a674751
a674751
%build
a674751
a674751
# Use our own signing key to generate regulatory.bin
a674751
cd wireless-regdb-%{regdb_version}
a674751
a674751
make %{?_smp_mflags} CFLAGS="$RPM_OPT_FLAGS" maintainer-clean
f1e5a5d
make %{?_smp_mflags} CFLAGS="$RPM_OPT_FLAGS" REGDB_PRIVKEY=key.priv.pem REGDB_PUBKEY=key.pub.pem
a674751
a674751
# Build CRDA using the new key and regulatory.bin from above
a674751
cd ../crda-%{crda_version}
a674751
cp ../wireless-regdb-%{regdb_version}/key.pub.pem pubkeys
a674751
a674751
make %{?_smp_mflags} CFLAGS="$RPM_OPT_FLAGS" REG_BIN=../wireless-regdb-%{regdb_version}/regulatory.bin
a674751
a674751
a674751
%install
a674751
rm -rf $RPM_BUILD_ROOT
a674751
a674751
cd crda-%{crda_version}
a674751
cp README README.crda
a674751
make install DESTDIR=$RPM_BUILD_ROOT
a674751
a674751
cd ../wireless-regdb-%{regdb_version}
a674751
cp README README.wireless-regdb
a674751
make install PREFIX=${RPM_BUILD_ROOT}/usr
a674751
af489f7
install -D -m0755 %SOURCE2 ${RPM_BUILD_ROOT}/sbin
a674751
a674751
%clean
a674751
rm -rf $RPM_BUILD_ROOT
a674751
a674751
a674751
%files
a674751
%defattr(-,root,root,-)
a674751
/sbin/%{name}
a674751
/sbin/regdbdump
af489f7
/sbin/setregdomain
8eda8cc
/lib/udev/rules.d/85-regulatory.rules
101c5d5
/usr/lib/%{name}
0549edf
%{_mandir}/man5/regulatory.bin.5.gz
0549edf
%{_mandir}/man8/crda.8.gz
0549edf
%{_mandir}/man8/regdbdump.8.gz
a674751
%doc crda-%{crda_version}/LICENSE crda-%{crda_version}/README.crda
a674751
%doc wireless-regdb-%{regdb_version}/README.wireless-regdb
a674751
a674751
%changelog
18a72f9
* Wed May 13 2009 John W. Linville <linville@redhat.com> 1.1.0_2009.04.17-11
18a72f9
- Update crda version to version 1.1.0
18a72f9
- Update wireless-regdb to version 2009.04.17 
18a72f9
f1e5a5d
* Fri Apr 17 2009 John W. Linville <linville@redhat.com> 1.0.1_2009.04.16-10
f1e5a5d
- Update wireless-regdb version to pick-up recent updates and fixes (#496392)
f1e5a5d
f2d5862
* Tue Mar 31 2009 John W. Linville <linville@redhat.com> 1.0.1_2009.03.09-9
f2d5862
- Add Requires line for iw package (#492762)
f2d5862
- Update setregdomain script to correctly check if COUNTRY is set
f2d5862
af489f7
* Thu Mar 19 2009 John W. Linville <linville@redhat.com> 1.0.1_2009.03.09-8
af489f7
- Add setregdomain script to set regulatory domain based on timezone
af489f7
- Expand 85-regulatory.rules to invoke setregdomain script on device add
af489f7
64ae53c
* Tue Mar 10 2009 John W. Linville <linville@redhat.com> 1.0.1_2009.03.09-7
64ae53c
- Update wireless-regdb version to pick-up recent updates and fixes (#489560)
64ae53c
64f0433
* Tue Feb 24 2009 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1.0.1_2009.01.30-6
64f0433
- Rebuilt for https://fedoraproject.org/wiki/Fedora_11_Mass_Rebuild
64f0433
58e4125
* Mon Feb 16 2009 John W. Linville <linville@redhat.com> 1.0.1_2009.01.30-5
58e4125
- Recognize regulatory.bin files signed with the upstream key (#484982)
58e4125
58e4125
* Tue Feb 03 2009 John W. Linville <linville@redhat.com> 1.0.1_2009.01.30-4
0549edf
- Change version to reflect new wireless-regdb upstream release practices
0549edf
- Update wireless-regdb version to pick-up recent updates and fixes (#483816)
0549edf
58e4125
* Tue Jan 27 2009 John W. Linville <linville@redhat.com> 1.0.1_2009_01_15-3
a0c189a
- Update for CRDA verion 1.0.1
a0c189a
- Account for lack of "v" in upstream release tarball naming
d8627df
- Add patch to let wireless-regdb install w/o being root
a0c189a
58e4125
* Thu Jan 22 2009 John W. Linville <linville@redhat.com> v0.9.5_2009_01_15-2
a674751
- Revamp based on package review comments
a674751
58e4125
* Tue Jan 20 2009 John W. Linville <linville@redhat.com> v0.9.5_2009_01_15-1
a674751
- Initial build