1 %define _kernel_ver %(grep UTS_RELEASE %{_kernelsrcdir}/include/linux/version.h 2>/dev/null | cut -d'"' -f2)
2 %define _kernel_ver_str %(echo %{_kernel_ver} | sed s/-/_/g)
3 %define smpstr %{?_with_smp:-smp}
4 %define smp %{?_with_smp:1}%{!?_with_smp:0}
12 Group: Networking/Daemons
13 Group(de): Netzwerkwesen/Server
14 Group(pl): Sieciowe/Serwery
15 Source0: ftp://prdownloads.sourceforge.net/%{name}/%{name}-%{version}.zip
16 Patch0: %{name}-config.patch
17 BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
19 %define _sysconfdir /etc
25 %package -n kernel%{smpstr}-cvsfs
26 Summary: CVSFS kernel module
27 Summary(pl): Modu³ j±dra CVSFS
28 Release: %{release}@%{_kernel_ver_str}
30 Group(de): Grundsätzlich/Kern
31 Group(pl): Podstawowe/J±dro
34 %description -n kernel%{smpstr}-cvsfs
36 %description -n kernel%{smpstr}-cvsfs -l pl
45 KDEFS+=" -D__KERNEL_SMP=1"
49 rm -rf $RPM_BUILD_ROOT
51 install -d $RPM_BUILD_ROOT{%{_bindir},%{_sbindir}} \
52 $RPM_BUILD_ROOT/lib/modules/%{_kernel_ver}/fs
54 install cvsmnt/cvsmnt $RPM_BUILD_ROOT%{_bindir}
55 install cvsmount/cvsmount $RPM_BUILD_ROOT%{_bindir}
56 install cvsmount/mount.cvsfs $RPM_BUILD_ROOT%{_bindir}
57 install cvsfs/cvsfs.o $RPM_BUILD_ROOT/lib/modules/%{_kernel_ver}/fs
58 gzip -9nf ChangeLog README INSTALL
61 rm -rf $RPM_BUILD_ROOT
66 %post -n kernel%{smpstr}-cvsfs
69 %postun -n kernel%{smpstr}-cvsfs
73 %defattr(644,root,root,755)
75 %attr(755,root,root) %{_bindir}/*
77 %files -n kernel%{smpstr}-cvsfs
78 %defattr(644,root,root,755)
79 %attr(600,root,root) /lib/modules/*/fs/cvsfs.o