]>
Commit | Line | Data |
---|---|---|
1 | # | |
2 | # Conditional build: | |
3 | %bcond_without debug_asserts | |
4 | # | |
5 | Summary: Tools for the XFS filesystem | |
6 | Summary(pl.UTF-8): Narzędzia do systemu plików XFS | |
7 | Name: xfsprogs | |
8 | Version: 4.20.0 | |
9 | Release: 1 | |
10 | License: LGPL v2.1 (libhandle), GPL v2 (the rest) | |
11 | Group: Applications/System | |
12 | Source0: https://www.kernel.org/pub/linux/utils/fs/xfs/xfsprogs/%{name}-%{version}.tar.gz | |
13 | # Source0-md5: 449e475ff861a184606c7d1500de7fb6 | |
14 | Source1: xfs_lsprojid | |
15 | Patch0: %{name}-miscfix-v2.patch | |
16 | Patch1: %{name}-pl.po-update.patch | |
17 | # Patch1-md5: 5fa89df413162a272aadfb3bdfe2330d | |
18 | Patch2: xfsprogs-small_fixes.patch | |
19 | URL: http://www.xfs.org/ | |
20 | BuildRequires: autoconf >= 2.50 | |
21 | BuildRequires: automake | |
22 | BuildRequires: bash | |
23 | BuildRequires: device-mapper-devel | |
24 | BuildRequires: gettext-tools | |
25 | BuildRequires: glibc-static | |
26 | BuildRequires: libblkid-devel | |
27 | BuildRequires: libicu-devel | |
28 | BuildRequires: libtool | |
29 | BuildRequires: libuuid-devel | |
30 | BuildRequires: libuuid-static | |
31 | BuildRequires: readline-devel | |
32 | BuildRequires: rpm >= 4.4.9-56 | |
33 | BuildRequires: rpmbuild(macros) >= 1.402 | |
34 | BuildRequires: sed >= 4.0 | |
35 | Obsoletes: xfsprogs-initrd | |
36 | BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n) | |
37 | ||
38 | %if "%{pld_release}" == "ac" | |
39 | # libtool in ac doesn't do the reordering of args properly | |
40 | %define filterout_ld -Wl,--as-needed | |
41 | %endif | |
42 | ||
43 | %description | |
44 | A set of commands to use the XFS filesystem, including mkfs.xfs. | |
45 | ||
46 | XFS is a high performance journaling filesystem which originated on | |
47 | the SGI IRIX platform. It is completely multi-threaded, can support | |
48 | large files and large filesystems, extended attributes, variable block | |
49 | sizes, is extent based, and makes extensive use of Btrees | |
50 | (directories, extents, free space) to aid both performance and | |
51 | scalability. | |
52 | ||
53 | This implementation is on-disk compatible with the IRIX version of | |
54 | XFS. | |
55 | ||
56 | %description -l pl.UTF-8 | |
57 | Zbiór komend do użytku z systemem plików XFS, włączając w to mkfs.xfs. | |
58 | ||
59 | XFS jest wysoko wydajnym systemem plików z kroniką, który oryginalnie | |
60 | był używany na platformie SGI IRIX. Jest to w pełni wielowątkowy, | |
61 | obsługujący wielkie pliki oraz wielkie systemy, o rozszerzonych | |
62 | atrybutach, zmiennych wielkościach bloków, mocno wykorzystujący | |
63 | B-drzewa by uzyskać wysoką wydajność oraz skalowalność. | |
64 | ||
65 | %package scrub | |
66 | Summary: xfs_scrub - XFS online check and repair feature (EXPERIMENTAL!) | |
67 | Summary(pl.UTF-8): xfs_scrub - sprawdzanie i naprawianie zamontowanego systemu plików XFS (EKSPERYMENTALNE!) | |
68 | Group: Applications/System | |
69 | Requires: %{name} = %{version}-%{release} | |
70 | Requires: systemd-units >= 38 | |
71 | ||
72 | %description scrub | |
73 | xfs_scrub is an XFS online check and repair feature. | |
74 | ||
75 | WARNING: EXPERIMENTAL, use at your own risk! | |
76 | ||
77 | %description scrub -l pl.UTF-8 | |
78 | xfs_scrub służy do sprawdzania i naprawiania zamontowanego systmeu | |
79 | plików XFS w locie. | |
80 | ||
81 | UWAGA: EXPERIMENTALNE, użycie na własne ryzyko! | |
82 | ||
83 | %package devel | |
84 | Summary: Header files and libraries to develop XFS software | |
85 | Summary(pl.UTF-8): Pliki nagłówkowe i biblioteki | |
86 | Group: Development/Libraries | |
87 | Requires: %{name} = %{version}-%{release} | |
88 | Requires: libuuid-devel | |
89 | ||
90 | %description devel | |
91 | Header files and libraries to develop software which operates on XFS | |
92 | filesystems. | |
93 | ||
94 | %description devel -l pl.UTF-8 | |
95 | Pliki nagłówkowe i biblioteki potrzebne do rozwoju oprogramowania | |
96 | operującego na systemie plików XFS. | |
97 | ||
98 | %package static | |
99 | Summary: Static XFS software libraries | |
100 | Summary(pl.UTF-8): Biblioteki statyczne do XFS | |
101 | Group: Development/Libraries | |
102 | Requires: %{name}-devel = %{version}-%{release} | |
103 | ||
104 | %description static | |
105 | Static XFS software libraries. | |
106 | ||
107 | %description static -l pl.UTF-8 | |
108 | Biblioteki statyczne do XFS. | |
109 | ||
110 | %prep | |
111 | %setup -q | |
112 | %patch0 -p1 | |
113 | %patch1 -p1 | |
114 | %patch2 -p1 | |
115 | ||
116 | %{__sed} -i -e '1s,/usr/bin/env python3,%{__python3},' scrub/xfs_scrub_all.in tools/xfsbuflock.py | |
117 | ||
118 | %build | |
119 | %{__aclocal} -I m4 | |
120 | %{__autoconf} | |
121 | %configure \ | |
122 | DEBUG="%{?with_debug_asserts:-DDEBUG}%{!?with_debug_asserts:-DNDEBUG}" \ | |
123 | OPTIMIZER="%{rpmcflags}" \ | |
124 | --enable-libicu=yes \ | |
125 | --enable-lto=no \ | |
126 | --enable-blkid \ | |
127 | --enable-gettext \ | |
128 | --enable-readline \ | |
129 | --enable-scrub=yes | |
130 | ||
131 | %{__make} -j1 \ | |
132 | V=1 | |
133 | ||
134 | %install | |
135 | rm -rf $RPM_BUILD_ROOT | |
136 | install -d $RPM_BUILD_ROOT/etc/cron.d | |
137 | ||
138 | DIST_ROOT=$RPM_BUILD_ROOT | |
139 | DIST_INSTALL=$(pwd)/install.manifest | |
140 | DIST_INSTALL_DEV=$(pwd)/install-dev.manifest | |
141 | export DIST_ROOT DIST_INSTALL DIST_INSTALL_DEV | |
142 | ||
143 | %{__make} install \ | |
144 | DIST_MANIFEST="$DIST_INSTALL" | |
145 | %{__make} install-dev \ | |
146 | DIST_MANIFEST="$DIST_INSTALL_DEV" | |
147 | ||
148 | install -p %{SOURCE1} $RPM_BUILD_ROOT%{_sbindir}/xfs_lsprojid | |
149 | ||
150 | # adjust symlink to point to actual library, not libhandle.so symlink, which we remove afterwards | |
151 | ln -sf /%{_lib}/$(basename $RPM_BUILD_ROOT/%{_lib}/libhandle.so.*.*.*) \ | |
152 | $RPM_BUILD_ROOT%{_libdir}/libhandle.so | |
153 | # adjust library path used at link time | |
154 | %{__sed} -i -e "s|libdir='/%{_lib}'|libdir='%{_libdir}'|" \ | |
155 | $RPM_BUILD_ROOT%{_libdir}/libhandle.la | |
156 | # already in /usr | |
157 | %{__rm} $RPM_BUILD_ROOT/%{_lib}/libhandle.{so,la,a} | |
158 | ||
159 | # install cron file | |
160 | %{__mv} $RPM_BUILD_ROOT{%{_libdir}/%{name}/xfs_scrub_all.cron,/etc/cron.d/xfs_scrub_all} | |
161 | ||
162 | # (config file paths are specified in libfrog/projects.c) | |
163 | echo "#10:/mnt/ftp/roman" >> $RPM_BUILD_ROOT/etc/projects | |
164 | echo "#ftproman:10" >> $RPM_BUILD_ROOT/etc/projid | |
165 | ||
166 | %{__rm} -r $RPM_BUILD_ROOT%{_docdir}/%{name} | |
167 | ||
168 | %find_lang %{name} | |
169 | ||
170 | %clean | |
171 | rm -rf $RPM_BUILD_ROOT | |
172 | ||
173 | %post -p /sbin/ldconfig | |
174 | %postun -p /sbin/ldconfig | |
175 | ||
176 | %post scrub | |
177 | %systemd_reload | |
178 | ||
179 | %files -f %{name}.lang | |
180 | %defattr(644,root,root,755) | |
181 | %doc README doc/{CHANGES,CREDITS} | |
182 | %config(noreplace) %verify(not md5 mtime size) /etc/projects | |
183 | %config(noreplace) %verify(not md5 mtime size) /etc/projid | |
184 | %attr(755,root,root) /sbin/fsck.xfs | |
185 | %attr(755,root,root) /sbin/mkfs.xfs | |
186 | %attr(755,root,root) /sbin/xfs_repair | |
187 | %attr(755,root,root) %{_sbindir}/xfs_* | |
188 | %exclude %{_sbindir}/xfs_scrub* | |
189 | %attr(755,root,root) /%{_lib}/libhandle.so.*.* | |
190 | %attr(755,root,root) %ghost /%{_lib}/libhandle.so.1 | |
191 | %dir %{_libdir}/%{name} | |
192 | %attr(755,root,root) %{_libdir}/%{name}/xfs_scrub_fail | |
193 | %{_mandir}/man5/projects.5* | |
194 | %{_mandir}/man5/projid.5* | |
195 | %{_mandir}/man5/xfs.5* | |
196 | %{_mandir}/man8/fsck.xfs.8* | |
197 | %{_mandir}/man8/mkfs.xfs.8* | |
198 | %{_mandir}/man8/xfs_*.8* | |
199 | %exclude %{_mandir}/man8/xfs_scrub*.8* | |
200 | ||
201 | %files scrub | |
202 | %defattr(644,root,root,755) | |
203 | %attr(755,root,root) %{_sbindir}/xfs_scrub | |
204 | %attr(755,root,root) %{_sbindir}/xfs_scrub_all | |
205 | %{systemdunitdir}/xfs_scrub@.service | |
206 | %{systemdunitdir}/xfs_scrub_all.service | |
207 | %{systemdunitdir}/xfs_scrub_all.timer | |
208 | %{systemdunitdir}/xfs_scrub_fail@.service | |
209 | %config(noreplace) %verify(not md5 mtime size) /etc/cron.d/xfs_scrub_all | |
210 | %{_mandir}/man8/xfs_scrub.8* | |
211 | %{_mandir}/man8/xfs_scrub_all.8* | |
212 | ||
213 | %files devel | |
214 | %defattr(644,root,root,755) | |
215 | %attr(755,root,root) %{_libdir}/libhandle.so | |
216 | %{_libdir}/libhandle.la | |
217 | %{_includedir}/xfs | |
218 | %{_mandir}/man2/ioctl_xfs_scrub_metadata.2* | |
219 | %{_mandir}/man3/*handle.3* | |
220 | %{_mandir}/man3/xfsctl.3* | |
221 | ||
222 | %files static | |
223 | %defattr(644,root,root,755) | |
224 | %{_libdir}/libhandle.a |