]> git.pld-linux.org Git - packages/aufs.git/blame - aufs.spec
- release 3
[packages/aufs.git] / aufs.spec
CommitLineData
bf531407 1#
a36ba58b 2# TODO:
3# - define CONFIG_ option directly
4#
4734e1ff
ER
5# Conditional build:
6%bcond_without dist_kernel # allow non-distribution kernel
7%bcond_without kernel # don't build kernel modules
4734e1ff
ER
8%bcond_without userspace # don't build userspace programs
9%bcond_with verbose # verbose build (V=1)
10
11%if %{without kernel}
12%undefine with_dist_kernel
13%endif
14
a36ba58b 15%define subver 20080527
46de4e94
ER
16%define prel 0.%{subver}.%{rel}
17
584608ee 18%define rel 3
509b678e 19Summary: aufs - Another Unionfs
bf531407 20Summary(pl.UTF-8): aufs (Another Unionfs) - inny unionfs
4734e1ff
ER
21Name: aufs
22Version: 0
46de4e94 23Release: %{prel}
4734e1ff
ER
24License: GPL v2
25Group: Base/Kernel
46de4e94 26Source0: %{name}-%{subver}.tar.bz2
789a4d93 27# Source0-md5: aeb6880930a8abcb60947e96b310d3df
509b678e 28Patch0: %{name}-vserver.patch
a36ba58b 29Patch1: %{name}-disable-security_inode_permission.patch
30Patch2: %{name}-fixes.patch
31Patch3: %{name}-spin_lock.patch
4734e1ff
ER
32URL: http://aufs.sourceforge.net/
33%if %{with kernel}
069b6c5a 34%{?with_dist_kernel:BuildRequires: kernel%{_alt_kernel}-module-build >= 3:2.6.25.2}
509b678e 35BuildRequires: rpmbuild(macros) >= 1.379
4734e1ff 36%endif
518cfd38 37BuildRequires: sed >= 4.0
4734e1ff
ER
38BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
39
40%description
41In the early days, aufs was entirely re-designed and re-implemented
42Unionfs. After many original ideas, approaches, improvements and
43implementations, it becomes totally different from Unionfs while
44keeping the basic features. Unionfs is being developed by Professor
45Erez Zadok at Stony Brook University and his team. If you don't know
46Unionfs, I recommend you to try and know it before using aufs. Some
47terminology in aufs follows Unionfs's.
48
bf531407
JB
49%description -l pl.UTF-8
50Początkowo aufs był całkowicie przeprojektowanym i od nowa
51zaimplementowanym unionfs-em. Po wielu oryginalnych pomysłach,
52podejściach, poprawkach i implementacjach stał sie całkowicie innym
53niż unionfs zachowując podstawowe możliwości. unionfs jest rozwijany
54przez profesora Ereza Zadoka w Stony Brook University i jego zespół.
55Nie znający unionfs-a powinni spróbować go i poznać przed używaniem
56aufs-a. Część terminologii wywodzi się z unionfs-a.
57
4734e1ff
ER
58%package -n kernel%{_alt_kernel}-fs-aufs
59Summary: Linux driver for aufs
60Summary(pl.UTF-8): Sterownik dla Linuksa do aufs
46de4e94 61Release: %{prel}@%{_kernel_ver_str}
4734e1ff
ER
62Group: Base/Kernel
63Requires(post,postun): /sbin/depmod
64%if %{with dist_kernel}
509b678e 65%requires_releq_kernel
66Requires(postun): %releq_kernel
4734e1ff
ER
67%endif
68
69%description -n kernel%{_alt_kernel}-fs-aufs
70This is driver for aufs for Linux.
71
72This package contains Linux module.
73
74%description -n kernel%{_alt_kernel}-fs-aufs -l pl.UTF-8
75Sterownik dla Linuksa do aufs.
76
77Ten pakiet zawiera moduł jądra Linuksa.
78
4734e1ff
ER
79%prep
80%setup -qn %{name}
509b678e 81%patch0 -p1
a36ba58b 82%patch1 -p1
83%patch2 -p1
84%patch3 -p1
509b678e 85
32f7b99c 86# we should make it better
509b678e 87sed '
88 s/$(CONFIG_AUFS)/m/;
89 %{!?debug:s/$(CONFIG_AUFS_DEBUG.*)/n/};
90 s/$(CONFIG_AUFS_HINOTIFY)/n/;
91 s/$(CONFIG_AUFS_EXPORT)/y/;
92 s/$(CONFIG_AUFS_SYSAUFS)/n/
93' -i fs/aufs/Makefile
a36ba58b 94cp -a include/linux fs/aufs25
4734e1ff
ER
95
96%build
97%if %{with kernel}
dd9fb61b 98if [ -f %{_kernelsrcdir}/include/linux/vs_base.h ]; then
99 isvserver="-DVSERVER"
100fi
32f7b99c 101export CONFIG_AUFS=m
a36ba58b 102export CONFIG_AUFS_BR_XFS=y
103%build_kernel_modules -C fs/aufs25 -m aufs \
104 EXTRA_CFLAGS+=" \
509b678e 105 -DCONFIG_AUFS_BRANCH_MAX_127 \
106 -DCONFIG_AUFS_BRANCH_MAX_CHAR \
107 -DCONFIG_AUFS_FAKE_DM \
108 -DCONFIG_AUFS_MODULE \
109 -UCONFIG_AUFS_KSIZE_PATCH \
3b805c44 110 -UCONFIG_AUFS_DLGT \
509b678e 111 %{?debug:-DCONFIG_AUFS_DEBUG} \
dd9fb61b 112 $isvserver"
4734e1ff
ER
113%endif
114
7d59a9cf 115%if %{with userspace}
116%{__make} -C util \
117 CC="%{__cc}" \
118 CFLAGS="%{rpmcflags} -DCONFIG_AUFS_BRANCH_MAX_127"
119%endif
120
4734e1ff
ER
121%install
122rm -rf $RPM_BUILD_ROOT
123
7d59a9cf 124%if %{with userspace}
125install -d $RPM_BUILD_ROOT{%{_mandir}/man5,%{_sbindir}}
126install util/{mount.aufs,umount.aufs,auplink,aulchown} $RPM_BUILD_ROOT%{_sbindir}
127install util/aufs.5 $RPM_BUILD_ROOT%{_mandir}/man5/
128%endif
129
4734e1ff 130%if %{with kernel}
a36ba58b 131%install_kernel_modules -m fs/aufs25/aufs -d kernel/fs/aufs
4734e1ff
ER
132%endif
133
134%clean
135rm -rf $RPM_BUILD_ROOT
136
137%post -n kernel%{_alt_kernel}-fs-aufs
138%depmod %{_kernel_ver}
139
140%postun -n kernel%{_alt_kernel}-fs-aufs
141%depmod %{_kernel_ver}
142
4734e1ff 143%if %{with kernel}
4734e1ff
ER
144%files -n kernel%{_alt_kernel}-fs-aufs
145%defattr(644,root,root,755)
0f3a7497 146%dir /lib/modules/%{_kernel_ver}/kernel/fs/aufs
147/lib/modules/%{_kernel_ver}/kernel/fs/aufs/*.ko*
4734e1ff
ER
148%endif
149
4734e1ff
ER
150%if %{with userspace}
151%files
152%defattr(644,root,root,755)
153%doc README History
7d59a9cf 154%attr(755,root,root) %{_sbindir}/*
155%{_mandir}/man5/*
4734e1ff 156%endif
This page took 0.069956 seconds and 4 git commands to generate.