]> git.pld-linux.org Git - packages/aufs.git/blob - aufs.spec
1d0681a56f27459e94b3f94391da0d25bf1efdf7
[packages/aufs.git] / aufs.spec
1 #
2 # Conditional build:
3 %bcond_without  dist_kernel     # allow non-distribution kernel
4 %bcond_without  kernel          # don't build kernel modules
5 %bcond_without  userspace       # don't build userspace programs
6 %bcond_with     verbose         # verbose build (V=1)
7 %bcond_without  vserver         # kernel build without vserver & grsecurity
8
9 %if %{without kernel}
10 %undefine       with_dist_kernel
11 %endif
12
13 %define         _cvsdate        20070424
14 %define         _rel            0.%{_cvsdate}.1
15 Summary:        aufs - Another Unionfs
16 Summary(pl.UTF-8):      aufs (Another Unionfs) - inny unionfs
17 Name:           aufs
18 Version:        0
19 Release:        %{_rel}
20 License:        GPL v2
21 Group:          Base/Kernel
22 Source0:        http://www.pers.pl/%{name}-%{_cvsdate}.tar.bz2
23 # Source0-md5:  526264eaac467144032e66a680fa03bf
24 Patch0:         %{name}-vserver.patch
25 URL:            http://aufs.sourceforge.net/
26 %if %{with kernel}
27 %{?with_dist_kernel:BuildRequires:      kernel%{_alt_kernel}-module-build >= 3:2.6.14}
28 BuildRequires:  rpmbuild(macros) >= 1.379
29 %endif
30 BuildRequires:  sed >= 4.0
31 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
32
33 %description
34 In the early days, aufs was entirely re-designed and re-implemented
35 Unionfs. After many original ideas, approaches, improvements and
36 implementations, it becomes totally different from Unionfs while
37 keeping the basic features. Unionfs is being developed by Professor
38 Erez Zadok at Stony Brook University and his team. If you don't know
39 Unionfs, I recommend you to try and know it before using aufs. Some
40 terminology in aufs follows Unionfs's.
41
42 %description -l pl.UTF-8
43 Początkowo aufs był całkowicie przeprojektowanym i od nowa
44 zaimplementowanym unionfs-em. Po wielu oryginalnych pomysłach,
45 podejściach, poprawkach i implementacjach stał sie całkowicie innym
46 niż unionfs zachowując podstawowe możliwości. unionfs jest rozwijany
47 przez profesora Ereza Zadoka w Stony Brook University i jego zespół.
48 Nie znający unionfs-a powinni spróbować go i poznać przed używaniem
49 aufs-a. Część terminologii wywodzi się z unionfs-a.
50
51 %package -n kernel%{_alt_kernel}-fs-aufs
52 Summary:        Linux driver for aufs
53 Summary(pl.UTF-8):      Sterownik dla Linuksa do aufs
54 Release:        %{_rel}@%{_kernel_ver_str}
55 Group:          Base/Kernel
56 Requires(post,postun):  /sbin/depmod
57 %if %{with dist_kernel}
58 %requires_releq_kernel
59 Requires(postun):       %releq_kernel
60 %endif
61
62 %description -n kernel%{_alt_kernel}-fs-aufs
63 This is driver for aufs for Linux.
64
65 This package contains Linux module.
66
67 %description -n kernel%{_alt_kernel}-fs-aufs -l pl.UTF-8
68 Sterownik dla Linuksa do aufs.
69
70 Ten pakiet zawiera moduł jądra Linuksa.
71
72 %prep
73 %setup -qn %{name}
74 %if %{with vserver}
75 %patch0 -p1
76 %endif
77
78 sed '
79         s/$(CONFIG_AUFS)/m/; 
80         %{!?debug:s/$(CONFIG_AUFS_DEBUG.*)/n/}; 
81         s/$(CONFIG_AUFS_HINOTIFY)/n/;
82         s/$(CONFIG_AUFS_EXPORT)/y/;
83         s/$(CONFIG_AUFS_SYSAUFS)/n/
84 ' -i fs/aufs/Makefile
85 cp -a include/linux fs/aufs
86
87 %build
88 %if %{with kernel}
89 %build_kernel_modules -C fs/aufs -m aufs \
90         EXTRA_CFLAGS=" \
91                 -DCONFIG_AUFS_BRANCH_MAX_127 \
92                 -DCONFIG_AUFS_BRANCH_MAX_CHAR \
93                 -DCONFIG_AUFS_FAKE_DM \
94                 -DCONFIG_AUFS_MODULE \
95                 -UCONFIG_AUFS_KSIZE_PATCH \
96                 %{?debug:-DCONFIG_AUFS_DEBUG} \
97                 %{?with_vserver:-DVSERVER} \
98         "
99 %endif
100
101 %install
102 rm -rf $RPM_BUILD_ROOT
103
104 %if %{with kernel}
105 %install_kernel_modules -m fs/aufs/aufs -d kernel/fs/aufs
106 %endif
107
108 %clean
109 rm -rf $RPM_BUILD_ROOT
110
111 %post   -n kernel%{_alt_kernel}-fs-aufs
112 %depmod %{_kernel_ver}
113
114 %postun -n kernel%{_alt_kernel}-fs-aufs
115 %depmod %{_kernel_ver}
116
117 %if %{with kernel}
118 %files -n kernel%{_alt_kernel}-fs-aufs
119 %defattr(644,root,root,755)
120 %dir /lib/modules/%{_kernel_ver}/kernel/fs/aufs
121 /lib/modules/%{_kernel_ver}/kernel/fs/aufs/*.ko*
122 %endif
123
124 %if %{with userspace}
125 %files
126 %defattr(644,root,root,755)
127 %doc README History
128 %endif
This page took 0.268524 seconds and 3 git commands to generate.