]>
Commit | Line | Data |
---|---|---|
4734e1ff ER |
1 | # Conditional build: |
2 | %bcond_without dist_kernel # allow non-distribution kernel | |
3 | %bcond_without kernel # don't build kernel modules | |
4 | %bcond_without up # don't build UP module | |
5 | %bcond_without smp # don't build SMP module | |
6 | %bcond_without userspace # don't build userspace programs | |
7 | %bcond_with verbose # verbose build (V=1) | |
8 | ||
9 | %if %{without kernel} | |
10 | %undefine with_dist_kernel | |
11 | %endif | |
12 | ||
13 | %define _rel 0.1 | |
14 | Summary: Aufs - Another Unionfs | |
15 | Name: aufs | |
16 | Version: 0 | |
17 | Release: %{_rel} | |
18 | License: GPL v2 | |
19 | Group: Base/Kernel | |
20 | Source0: %{name}-20070220.tar.bz2 | |
21 | # Source0-md5: 81bc264f83a3cdd579e0bffcbf5f0d74 | |
22 | URL: http://aufs.sourceforge.net/ | |
23 | %if %{with kernel} | |
24 | %{?with_dist_kernel:BuildRequires: kernel%{_alt_kernel}-module-build >= 3:2.6.14} | |
25 | BuildRequires: rpmbuild(macros) >= 1.330 | |
26 | %endif | |
27 | BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n) | |
28 | ||
29 | %description | |
30 | In the early days, aufs was entirely re-designed and re-implemented | |
31 | Unionfs. After many original ideas, approaches, improvements and | |
32 | implementations, it becomes totally different from Unionfs while | |
33 | keeping the basic features. Unionfs is being developed by Professor | |
34 | Erez Zadok at Stony Brook University and his team. If you don't know | |
35 | Unionfs, I recommend you to try and know it before using aufs. Some | |
36 | terminology in aufs follows Unionfs's. | |
37 | ||
38 | %package -n kernel%{_alt_kernel}-fs-aufs | |
39 | Summary: Linux driver for aufs | |
40 | Summary(pl.UTF-8): Sterownik dla Linuksa do aufs | |
41 | Release: %{_rel}@%{_kernel_ver_str} | |
42 | Group: Base/Kernel | |
43 | Requires(post,postun): /sbin/depmod | |
44 | %if %{with dist_kernel} | |
45 | %requires_releq_kernel_up | |
46 | Requires(postun): %releq_kernel_up | |
47 | %endif | |
48 | ||
49 | %description -n kernel%{_alt_kernel}-fs-aufs | |
50 | This is driver for aufs for Linux. | |
51 | ||
52 | This package contains Linux module. | |
53 | ||
54 | %description -n kernel%{_alt_kernel}-fs-aufs -l pl.UTF-8 | |
55 | Sterownik dla Linuksa do aufs. | |
56 | ||
57 | Ten pakiet zawiera moduł jądra Linuksa. | |
58 | ||
59 | %package -n kernel%{_alt_kernel}-smp-fs-aufs | |
60 | Summary: Linux SMP driver for aufs | |
61 | Summary(pl.UTF-8): Sterownik dla Linuksa SMP do aufs | |
62 | Release: %{_rel}@%{_kernel_ver_str} | |
63 | Group: Base/Kernel | |
64 | Requires(post,postun): /sbin/depmod | |
65 | %if %{with dist_kernel} | |
66 | %requires_releq_kernel_smp | |
67 | Requires(postun): %releq_kernel_smp | |
68 | %endif | |
69 | ||
70 | %description -n kernel%{_alt_kernel}-smp-fs-aufs | |
71 | This is driver for aufs for Linux. | |
72 | ||
73 | This package contains Linux SMP module. | |
74 | ||
75 | %description -n kernel%{_alt_kernel}-smp-fs-aufs -l pl.UTF-8 | |
76 | Sterownik dla Linuksa do aufs. | |
77 | ||
78 | Ten pakiet zawiera moduł jądra Linuksa SMP. | |
79 | ||
80 | %prep | |
81 | %setup -qn %{name} | |
82 | ||
83 | %build | |
84 | %if %{with kernel} | |
85 | %build_kernel_modules -m aufs | |
86 | %endif | |
87 | ||
88 | %install | |
89 | rm -rf $RPM_BUILD_ROOT | |
90 | ||
91 | %if %{with kernel} | |
92 | %install_kernel_modules -m aufs -d fs | |
93 | %endif | |
94 | ||
95 | %clean | |
96 | rm -rf $RPM_BUILD_ROOT | |
97 | ||
98 | %post -n kernel%{_alt_kernel}-fs-aufs | |
99 | %depmod %{_kernel_ver} | |
100 | ||
101 | %postun -n kernel%{_alt_kernel}-fs-aufs | |
102 | %depmod %{_kernel_ver} | |
103 | ||
104 | %post -n kernel%{_alt_kernel}-smp-fs-aufs | |
105 | %depmod %{_kernel_ver}smp | |
106 | ||
107 | %postun -n kernel%{_alt_kernel}-smp-fs-aufs | |
108 | %depmod %{_kernel_ver}smp | |
109 | ||
110 | %if %{with kernel} | |
111 | %if %{with up} || %{without dist_kernel} | |
112 | %files -n kernel%{_alt_kernel}-fs-aufs | |
113 | %defattr(644,root,root,755) | |
114 | /lib/modules/%{_kernel_ver}/fs/*.ko* | |
115 | %endif | |
116 | ||
117 | %if %{with smp} && %{with dist_kernel} | |
118 | %files -n kernel%{_alt_kernel}-smp-fs-aufs | |
119 | %defattr(644,root,root,755) | |
120 | /lib/modules/%{_kernel_ver}smp/fs/*.ko* | |
121 | %endif | |
122 | %endif | |
123 | ||
124 | %if %{with userspace} | |
125 | %files | |
126 | %defattr(644,root,root,755) | |
127 | %doc README History | |
128 | %endif |