Package kernel-modules-bcmwl-el-smp: Specfile

%define module_name	bcmwl
%define module_version	5.100.82.112
%define module_release	alt4

%define kversion	2.6.32
%define krelease	alt48.M60C.1
%define flavour		el-smp

%define norm_version	%kversion

%define module_dir /lib/modules/%kversion-%flavour-%krelease/net

Summary: Modules for Broadcom-based WiFi .11a/b/g adapters
Name: kernel-modules-%module_name-%flavour
Version: %module_version
Release: %module_release.132640.48.M60C.1
License: Proprietary
Group: System/Kernel and hardware

Packager: Kernel Maintainer Team <kernel@packages.altlinux.org>

ExclusiveOS: Linux
Url: http://www.broadcom.com/support/802.11/linux_sta.php
Patch1: %module_name-%module_version-3.2.patch
Patch2: %module_name-%module_version-3.4.patch
Patch3: %module_name-%module_version-el6.3.patch
Patch4: %module_name-%module_version-3.8.patch
Patch5: %module_name-%module_version-3.9.patch
Patch6: %module_name-%module_version-3.15.patch
Patch7: %module_name-%module_version-el6.7.patch
Patch8: %module_name-%module_version-el6.8.patch
BuildRequires: perl sharutils
BuildRequires(pre): rpm-build-kernel
BuildRequires: kernel-source-%module_name = %module_version
BuildRequires: kernel-headers-modules-%flavour = %kversion-%krelease

Provides:  kernel-modules-%module_name-%kversion-%flavour-%krelease = %version-%release
Conflicts: kernel-modules-%module_name-%kversion-%flavour-%krelease < %version-%release
Conflicts: kernel-modules-%module_name-%kversion-%flavour-%krelease > %version-%release

PreReq: coreutils
PreReq: kernel-image-%flavour = %kversion-%krelease
Requires(postun): kernel-image-%flavour = %kversion-%krelease
ExclusiveArch: %ix86 x86_64

%description
These packages contain Broadcom's IEEE 802.11a/b/g/n hybrid Linux device
driver for use with Broadcom's BCM4311-, BCM431i2-,
BCM4321-, and BCM4322-based hardware.

NOTE: You must read the LICENSE.TXT file in the lib directory before
using this software.
%prep
rm -rf kernel-source-%module_name-%module_version

tar -jxvf %kernel_src/kernel-source-%module_name-%module_version.tar.bz2

%setup -D -T -n kernel-source-%module_name-%module_version
%patch1 -p1
%patch2 -p1
%patch3 -p1
%patch4 -p1
%patch5 -p1
%patch6 -p1
%patch7 -p1
%patch8 -p1

%build
. %_usrsrc/linux-%kversion-%flavour/gcc_version.inc
make -C %_usrsrc/linux-%kversion-%flavour SUBDIRS=`pwd` modules

%install
mkdir -p $RPM_BUILD_ROOT%module_dir/

. %_usrsrc/linux-%kversion-%flavour/gcc_version.inc
make -C %_usrsrc/linux-%kversion-%flavour INSTALL_MOD_PATH=%buildroot INSTALL_MOD_DIR=net SUBDIRS=`pwd`  modules_install 
%post
%post_kernel_modules %kversion-%flavour-%krelease

%postun
%postun_kernel_modules %kversion-%flavour-%krelease

%files
%module_dir

%changelog
* Tue Mar 28 2017 Gleb F-Malinovskiy <glebfm@altlinux.org> 5.100.82.112-alt4.132640.48.M60C.1
- Build for kernel-image-el-smp-2.6.32-alt48.M60C.1.

* Thu Feb 16 2017 Gleb F-Malinovskiy <glebfm@altlinux.org> 5.100.82.112-alt4
- Fixed build of kernel EL 6.8.

* Wed Dec 23 2015 Gleb F-Malinovskiy <glebfm@altlinux.org> 5.100.82.112-alt3
- Fixed build of kernels 3.8, 3.9, 3.15, EL 6.7.

* Thu Jun 20 2013 Led <led@altlinux.ru> 5.100.82.112-alt2
- fixed build for kernels 3.2, 3.4, EL 6.3

* Thu Jan 12 2012 Anton V. Boyarshinov <boyarsh@altlinux.ru> 5.100.82.112-alt1
- 5.100.82.112

* Thu Feb 17 2011 Anton V. Boyarshinov <boyarsh@altlinux.ru> 5.60.48.36-alt4
- 2.6.35 patch extended to infinity 

* Sun Dec 19 2010 Anton V. Boyarshinov <boyarsh@altlinux.ru> 5.60.48.36-alt3
- 2.6.35 patch extended to 2.6.36

* Thu Sep 02 2010 Anton V. Boyarshinov <boyarsh@altlinux.ru> 5.60.48.36-alt2
- patch for 2.6.35 added

* Mon Jun 21 2010 Vitaly Kuznetsov <vitty@altlinux.ru> 5.60.48.36-alt1
- 5.60.48.36

* Thu Dec 31 2009 Anton V. Boyarshinov <boyarsh@altlinux.ru> 5.10.91.9.3-alt1
- 5.10.91.9.3

* Thu Jul 16 2009 Valery Inozemtsev <shrek@altlinux.ru> 5.10.91.9-alt3
- merged patches from debian

* Sat Jul 04 2009 Valery Inozemtsev <shrek@altlinux.ru> 5.10.91.9-alt2
- fixed build for kernel 2.6.30

* Tue May 26 2009 Michail Yakushin <silicium@altlinux.ru> 5.10.91.9-alt1
- 5.10.91.9 

* Tue Apr 21 2009 Michail Yakushin <silicium@altlinux.ru> 5.10.79.10-alt2
- Fix module position (closes: 19603) 

* Wed Mar 25 2009 Michail Yakushin <silicium@altlinux.ru> 5.10.79.10-alt1
- initial build