%kmdl bristuff %if %{kmdl_userland} %lib_package gsmat 1 %endif Summary: Asterisk drivers for BRI Name: bristuff Version: 0.3.0 Release: 2_PRE1w%{?dist} License: GPL2 Group: Applications/Internet URL: http://www.junghanns.net/de/opensource.html Source0: http://www.junghanns.net/downloads/%{name}-%{version}-PRE-1w.tar.gz Source1: http://ftp.digium.com/pub/zaptel/zaptel-1.2.12.tar.gz Patch0: zaptel-bri.patch BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root %kmdl_parentdependencies %description Asterisk drivers for - quadBRI / octoBRI - singleE1 /doubleE1 - hfc-pci (zaphfc) %package -n %kmdl_name %kmdl_dependencies Summary: kernel modules for %{name} Group: System Environment/Kernel %description -n %kmdl_name kernel modules for %{name}. See description for %{name} for further information. %kmdl_desc %prep %setup -q -n %{name}-%{version}-PRE-1w chmod -R +w . ln -s libgsmat-* libgsmat tar -zpxf %{SOURCE1} mv zaptel-* zaptel cd zaptel %patch0 -p1 cd .. perl -pi -e's,/sbin/ldconfig,:,' */Makefile perl -pi -e's,/lib/modules/\`uname -r\`/misc,%{kmdl_moduledir},' */Makefile perl -pi -e's,/usr/src/linux-2.6,%{kmdl_kernelsrcdir},g' */Makefile perl -pi -e's,/usr/src/linux,%{kmdl_kernelsrcdir},g' */Makefile if grep 'PATCHLEVEL = 4' %{kmdl_kernelsrcdir}/Makefile; then perl -pi -e's,^BUILDVER=.*,BUILDVER=linux24,' */Makefile else perl -pi -e's,^BUILDVER=.*,BUILDVER=linux26,' */Makefile fi %build %if %{kmdl_userland} export CFLAGS="%{optflags}" make -C libgsmat cd ISDNguard make cd .. %else %kmdl_config for project in ztgsm qozap cwain zaphfc; do make -C $project # ZAP=-I%{_includedir}/linux cp -a $project/LICENSE LICENSE.$project done %endif %install rm -rf %{buildroot} %if %{kmdl_userland} make -C libgsmat INSTALL_PREFIX=%{buildroot} install mkdir -p %{buildroot}%{_sbindir} install -m 0755 -p ISDNguard/ISDNguard %{buildroot}%{_sbindir}/ %else for project in ztgsm qozap cwain zaphfc; do make -C $project install INSTALL_PREFIX=%{buildroot} done %endif %clean rm -rf %{buildroot} %post -n %kmdl_name %kmdl_install %postun -n %kmdl_name %kmdl_remove %if %{kmdl_userland} %files %defattr(-,root,root,-) %doc CHANGES SAMPLES %{_sbindir}/ISDNguard %else %files -n %kmdl_name %defattr(-,root,root,-) %doc LICENSE.* %{kmdl_moduledir}/* %endif %changelog * Mon Dec 18 2006 Axel Thimm - 0.3.0-1_PRE1w - Update to 0.3.0-PRE-1w. * Sun Mar 12 2006 Axel Thimm - Initial build.