]> git.pld-linux.org Git - packages/zfs.git/blame_incremental - zfs.spec
- dracut files always land in /usr/lib
[packages/zfs.git] / zfs.spec
... / ...
CommitLineData
1# TODO: PLDify init script
2#
3# Conditional build:
4%bcond_without dist_kernel # allow non-distribution kernel
5%bcond_without kernel # don't build kernel modules
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%if "%{_alt_kernel}" != "%{nil}"
13%undefine with_userspace
14%endif
15%if %{without userspace}
16# nothing to be placed to debuginfo package
17%define _enable_debug_packages 0
18%endif
19Summary: Native Linux port of the ZFS filesystem
20Summary(pl.UTF-8): Natywny linuksowy port systemu plików ZFS
21%define pname zfs
22Name: %{pname}%{_alt_kernel}
23Version: 0.6.3
24%define rel 1
25Release: %{rel}
26License: CDDL (ZFS), GPL v2+ (ZPIOS)
27Group: Applications/System
28Source0: http://archive.zfsonlinux.org/downloads/zfsonlinux/zfs/%{pname}-%{version}.tar.gz
29# Source0-md5: 5bcc32c122934d421eba68e16826637d
30Patch0: %{name}-link.patch
31URL: http://zfsonlinux.org/
32BuildRequires: autoconf >= 2.50
33BuildRequires: automake
34BuildRequires: libtool
35%if %{with kernel}
36%{?with_dist_kernel:BuildRequires: kernel%{_alt_kernel}-module-build >= 3:2.6.26}
37BuildRequires: kernel%{_alt_kernel}-spl-devel >= 0.6.3
38BuildRequires: rpmbuild(macros) >= 1.379
39%endif
40%if %{with userspace}
41BuildRequires: libblkid-devel
42BuildRequires: libselinux-devel
43BuildRequires: libuuid-devel
44BuildRequires: zlib-devel
45%endif
46Requires: %{pname}-libs = %{version}-%{release}
47BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
48
49%define dracutlibdir %{_prefix}/lib/dracut
50
51%description
52ZFS is an advanced file system and volume manager which was originally
53developed for Solaris and is now maintained by the Illumos community.
54
55ZFS on Linux, which is also known as ZoL, is currently feature
56complete. It includes fully functional and stable SPA, DMU, ZVOL, and
57ZPL layers.
58
59%description -l pl.UTF-8
60ZFS to zaawansowany system plików i zarządca wolumenów, oryginalnie
61stworzony dla Solarisa, obecnie utrzymywany przez społeczność Illumos.
62
63ZFS dla Linuksa, znany takża jako ZoL (ZFS on Linux), jest obecnie w
64pełni funkcjonalny. Zawiera w pełni funkcjonalne i stabilne warstwy
65SPA, DMU, ZVOL i ZPL.
66
67%package libs
68Summary: ZFS on Linux libraries
69Summary(pl.UTF-8): Biblioteki ZFS-a dla Linuksa
70License: CDDL
71Group: Libraries
72Requires(post,postun): /sbin/ldconfig
73
74%description libs
75ZFS on Linux libraries.
76
77%description libs -l pl.UTF-8
78Biblioteki ZFS-a dla Linuksa.
79
80%package devel
81Summary: Header files for ZFS libraries
82Summary(pl.UTF-8): Pliki nagłówkowe bibliotek ZFS-a
83License: CDDL
84Group: Development/Libraries
85Requires: %{pname}-libs = %{version}-%{release}
86Requires: libselinux-devel
87Requires: libuuid-devel
88Requires: zlib-devel
89
90%description devel
91Header files for ZFS libraries.
92
93%description devel -l pl.UTF-8
94Pliki nagłówkowe bibliotek ZFS-a.
95
96%package static
97Summary: Static ZFS libraries
98Summary(pl.UTF-8): Statyczne biblioteki ZFS-a
99License: CDDL
100Group: Development/Libraries
101Requires: %{pname}-devel = %{version}-%{release}
102
103%description static
104Static ZFS libraries.
105
106%description static -l pl.UTF-8
107Statyczne biblioteki ZFS-a.
108
109%package -n dracut-zfs
110Summary: ZFS support for Dracut
111Summary(pl.UTF-8): Obsługa ZFS-a dla Dracuta
112Group: Applications/System
113Requires: %{pname} = %{version}-%{release}
114Requires: dracut
115
116%description -n dracut-zfs
117ZFS support for Dracut.
118
119%description -n dracut-zfs -l pl.UTF-8
120Obsługa ZFS-a dla Dracuta.
121
122%package -n kernel%{_alt_kernel}-zfs
123Summary: ZFS Linux kernel modules
124Summary(pl.UTF-8): ZFS - moduły jądra Linuksa
125Release: %{rel}@%{_kernel_ver_str}
126Group: Base/Kernel
127Requires(post,postun): /sbin/depmod
128%if %{with dist_kernel}
129%requires_releq_kernel
130Requires(postun): %releq_kernel
131%endif
132
133%description -n kernel%{_alt_kernel}-zfs
134ZFS Linux kernel modules.
135
136%description -n kernel%{_alt_kernel}-zfs -l pl.UTF-8
137ZFS - moduły jądra Linuksa.
138
139%package -n kernel%{_alt_kernel}-zfs-devel
140Summary: ZFS Linux kernel headers
141Summary(pl.UTF-8): ZFS - pliki nagłówkowe jądra Linuksa
142Release: %{rel}@%{_kernel_ver_str}
143Group: Development/Building
144%{?with_dist_kernel:Requires: kernel%{_alt_kernel}-headers}
145
146%description -n kernel%{_alt_kernel}-zfs-devel
147ZFS Linux kernel headers configured for PLD kernel%{_alt_kernel},
148version %{_kernel_ver}.
149
150%description -n kernel%{_alt_kernel}-zfs-devel -l pl.UTF-8
151ZFS - pliki nagłówkowe jądra Linuksa skonfigurowane dla jądra PLD z
152pakietu kernel%{_alt_kernel} w wersji %{_kernel_ver}.
153
154%prep
155%setup -q
156%patch0 -p1
157
158%build
159%{__libtoolize}
160%{__aclocal} -I config
161%{__autoconf}
162%{__autoheader}
163%{__automake}
164%configure \
165 --disable-silent-rules \
166 --with-config="%{?with_kernel:%{?with_userspace:all}}%{!?with_kernel:user}%{!?with_userspace:kernel}" \
167 --with-linux=%{_kernelsrcdir} \
168 --with-systemdunitdir=%{systemdunitdir} \
169 --with-systemdpresetdir=/etc/systemd/system-preset \
170 --with-udevdir=/lib/udev
171
172%{__make} \
173 %{?with_verbose:V=1}
174
175%install
176rm -rf $RPM_BUILD_ROOT
177
178%{__make} install \
179 DESTDIR=$RPM_BUILD_ROOT \
180 DEFAULT_INIT_DIR=/etc/rc.d/init.d \
181 INSTALL_MOD_DIR=misc
182
183%clean
184rm -rf $RPM_BUILD_ROOT
185
186%post -n kernel%{_alt_kernel}-zfs
187%depmod %{_kernel_ver}
188
189%postun -n kernel%{_alt_kernel}-zfs
190%depmod %{_kernel_ver}
191
192%post libs -p /sbin/ldconfig
193%postun libs -p /sbin/ldconfig
194
195%if %{with userspace}
196%files
197%defattr(644,root,root,755)
198%doc AUTHORS COPYRIGHT DISCLAIMER OPENSOLARIS.LICENSE README.markdown
199%attr(755,root,root) /sbin/mount.zfs
200%attr(755,root,root) %{_bindir}/arcstat.py
201%attr(755,root,root) %{_bindir}/dbufstat.py
202%attr(755,root,root) %{_sbindir}/fsck.zfs
203%attr(755,root,root) %{_sbindir}/zdb
204%attr(755,root,root) %{_sbindir}/zed
205%attr(755,root,root) %{_sbindir}/zfs
206%attr(755,root,root) %{_sbindir}/zhack
207%attr(755,root,root) %{_sbindir}/zinject
208%attr(755,root,root) %{_sbindir}/zpios
209%attr(755,root,root) %{_sbindir}/zpool
210%attr(755,root,root) %{_sbindir}/zstreamdump
211%attr(755,root,root) %{_sbindir}/ztest
212%dir %{_sysconfdir}/zfs
213# package *.example as %doc? (they cannot act as default configuration)
214%{_sysconfdir}/zfs/vdev_id.conf.*.example
215%dir %{_sysconfdir}/zfs/zed.d
216%attr(755,root,root) %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/zfs/zed.d/*.sh
217%config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/zfs/zed.d/zed.rc
218%attr(754,root,root) /etc/rc.d/init.d/zfs
219/usr/lib/modules-load.d/zfs.conf
220/etc/systemd/system-preset/50-zfs.preset
221%{systemdunitdir}/zed.service
222%{systemdunitdir}/zfs.target
223%{systemdunitdir}/zfs-import-cache.service
224%{systemdunitdir}/zfs-import-scan.service
225%{systemdunitdir}/zfs-mount.service
226%{systemdunitdir}/zfs-share.service
227%attr(755,root,root) /lib/udev/vdev_id
228%attr(755,root,root) /lib/udev/zvol_id
229/lib/udev/rules.d/60-zvol.rules
230/lib/udev/rules.d/69-vdev.rules
231/lib/udev/rules.d/90-zfs.rules
232%dir %{_libdir}/zfs
233%dir %{_libdir}/zfs/zed.d
234%attr(755,root,root) %{_libdir}/zfs/zed.d/*.sh
235%dir %{_datadir}/zfs
236%attr(755,root,root) %{_datadir}/zfs/*.sh
237%dir %{_datadir}/zfs/zpios-profile
238%attr(755,root,root) %{_datadir}/zfs/zpios-profile/*.sh
239%dir %{_datadir}/zfs/zpios-test
240%attr(755,root,root) %{_datadir}/zfs/zpios-test/*.sh
241%dir %{_datadir}/zfs/zpool-config
242%attr(755,root,root) %{_datadir}/zfs/zpool-config/*.sh
243%{_mandir}/man1/zhack.1*
244%{_mandir}/man1/zpios.1*
245%{_mandir}/man1/ztest.1*
246%{_mandir}/man5/vdev_id.conf.5*
247%{_mandir}/man5/zfs-module-parameters.5*
248%{_mandir}/man5/zpool-features.5*
249%{_mandir}/man8/fsck.zfs.8*
250%{_mandir}/man8/mount.zfs.8*
251%{_mandir}/man8/vdev_id.8*
252%{_mandir}/man8/zdb.8*
253%{_mandir}/man8/zed.8*
254%{_mandir}/man8/zfs.8*
255%{_mandir}/man8/zinject.8*
256%{_mandir}/man8/zpool.8*
257%{_mandir}/man8/zstreamdump.8*
258
259%files libs
260%defattr(644,root,root,755)
261%attr(755,root,root) %{_libdir}/libnvpair.so.*.*.*
262%attr(755,root,root) %ghost %{_libdir}/libnvpair.so.1
263%attr(755,root,root) %{_libdir}/libuutil.so.*.*.*
264%attr(755,root,root) %ghost %{_libdir}/libuutil.so.1
265%attr(755,root,root) %{_libdir}/libzfs.so.*.*.*
266%attr(755,root,root) %ghost %{_libdir}/libzfs.so.2
267%attr(755,root,root) %{_libdir}/libzfs_core.so.*.*.*
268%attr(755,root,root) %ghost %{_libdir}/libzfs_core.so.1
269%attr(755,root,root) %{_libdir}/libzpool.so.*.*.*
270%attr(755,root,root) %ghost %{_libdir}/libzpool.so.2
271
272%files devel
273%defattr(644,root,root,755)
274%attr(755,root,root) %{_libdir}/libnvpair.so
275%attr(755,root,root) %{_libdir}/libuutil.so
276%attr(755,root,root) %{_libdir}/libzfs.so
277%attr(755,root,root) %{_libdir}/libzfs_core.so
278%attr(755,root,root) %{_libdir}/libzpool.so
279%{_libdir}/libnvpair.la
280%{_libdir}/libuutil.la
281%{_libdir}/libzfs.la
282%{_libdir}/libzfs_core.la
283%{_libdir}/libzpool.la
284%{_includedir}/libspl
285%{_includedir}/libzfs
286
287%files static
288%defattr(644,root,root,755)
289%{_libdir}/libnvpair.a
290%{_libdir}/libuutil.a
291%{_libdir}/libzfs.a
292%{_libdir}/libzfs_core.a
293%{_libdir}/libzpool.a
294
295%files -n dracut-zfs
296%defattr(644,root,root,755)
297%doc dracut/README.dracut.markdown
298%dir %{dracutlibdir}/modules.d/90zfs
299%attr(755,root,root) %{dracutlibdir}/modules.d/90zfs/module-setup.sh
300%attr(755,root,root) %{dracutlibdir}/modules.d/90zfs/mount-zfs.sh
301%attr(755,root,root) %{dracutlibdir}/modules.d/90zfs/parse-zfs.sh
302%endif
303
304%if %{with kernel}
305%files -n kernel%{_alt_kernel}-zfs
306%defattr(644,root,root,755)
307%dir /lib/modules/%{_kernel_ver}/misc/avl
308/lib/modules/%{_kernel_ver}/misc/avl/zavl.ko*
309%dir /lib/modules/%{_kernel_ver}/misc/nvpair
310/lib/modules/%{_kernel_ver}/misc/nvpair/znvpair.ko*
311%dir /lib/modules/%{_kernel_ver}/misc/unicode
312/lib/modules/%{_kernel_ver}/misc/unicode/zunicode.ko*
313%dir /lib/modules/%{_kernel_ver}/misc/zcommon
314/lib/modules/%{_kernel_ver}/misc/zcommon/zcommon.ko*
315%dir /lib/modules/%{_kernel_ver}/misc/zfs
316/lib/modules/%{_kernel_ver}/misc/zfs/zfs.ko*
317%dir /lib/modules/%{_kernel_ver}/misc/zpios
318/lib/modules/%{_kernel_ver}/misc/zpios/zpios.ko*
319
320%files -n kernel%{_alt_kernel}-zfs-devel
321%defattr(644,root,root,755)
322/usr/src/zfs-%{version}
323%endif
This page took 0.081505 seconds and 4 git commands to generate.