]>
Commit | Line | Data |
---|---|---|
21d472d1 JB |
1 | # |
2 | # Conditional build: | |
696084fd | 3 | %bcond_without dist_kernel # allow non-distribution kernel |
4 | %bcond_without kernel # don't build 'any' kernel module | |
21d472d1 JB |
5 | %bcond_without userspace # don't build userspace utilities |
6 | # | |
c939ee5d | 7 | %define _rel 1 |
9ae21f85 | 8 | Summary: anyfs-tools - a unix-like toolset for recovering and converting filesystems |
1ffc5fef | 9 | Summary(pl.UTF-8): anyfs-tools - uniksowy zestaw narzędzi do odzyskiwania i konwersji systemów plików |
430df31f | 10 | Name: anyfs-tools |
c939ee5d | 11 | Version: 0.84.12 |
12 | Release: %{_rel} | |
430df31f | 13 | License: GPL v2 |
9ae21f85 | 14 | Group: Applications/System |
430df31f | 15 | Source0: http://dl.sourceforge.net/anyfs-tools/%{name}-%{version}.tar.bz2 |
c939ee5d | 16 | # Source0-md5: 548126cb199da13c632805ef3fcca26c |
da6ae5d5 | 17 | Patch0: %{name}-DFL_RTEXTSIZE.patch |
50652117 | 18 | URL: http://anyfs-tools.sourceforge.net/ |
c939ee5d | 19 | %{?with_userspace:BuildRequires: e2fsprogs-devel >= 1.38} |
696084fd | 20 | %if %{with kernel} |
58f1fe78 | 21 | %{?with_dist_kernel:BuildRequires: kernel%{_alt_kernel}-module-build >= 3:2.6.20.2} |
696084fd | 22 | BuildRequires: rpmbuild(macros) >= 1.379 |
23 | %endif | |
c939ee5d | 24 | %if %{with userspace} |
bdadd437 | 25 | BuildRequires: bzip2-devel |
da6ae5d5 | 26 | BuildRequires: libfuse-devel >= 2.5 |
99129efa | 27 | BuildRequires: mpeg2dec-devel |
bdadd437 | 28 | BuildRequires: pkgconfig |
d0fae6b5 | 29 | BuildRequires: xfsprogs-devel >= 2.8.11 |
c939ee5d | 30 | %endif |
430df31f | 31 | BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n) |
32 | ||
33 | %description | |
34 | anyfs-tools provides a unix-like toolset for recovering and converting | |
35 | filesystems. The following utils are included in the toolset: | |
36 | ||
9ae21f85 | 37 | build_it uses Linux OS filesystem drivers to recursively read |
430df31f | 38 | directory entries in order to obtain information about all of the |
39 | filesystem inodes. The information is then saved to an external inode | |
40 | table. | |
41 | ||
42 | anysurrect searches block devices for specific file types, based on | |
43 | their file structure. Information about each found file type is also | |
44 | saved to an external inode table. | |
45 | ||
46 | reblock changes the filesystem block size. reblock uses information | |
47 | from the filesystems inode table to change each files' fragments | |
48 | placing so that it will align with block boundaries but with a new | |
49 | block size. | |
50 | ||
51 | build_e2fs proceeds from external inode table information for building | |
52 | ext2fs filesystems on device. | |
53 | ||
54 | build_xfs proceeds from external inode table information for building | |
55 | xfs filesystems on device. | |
56 | ||
57 | anyconvertfs converts device filesystem with applying other | |
58 | anyfs-tools utilities. | |
59 | ||
60 | The anyfs filesystem driver for Linux allows a user to mount a device | |
61 | using the external inode table information created by the build_it or | |
62 | anysurrect commands. Once the filesystem is mounted with the inode | |
63 | table information the user can perform file operations such as | |
64 | deleting, moving files, making symbolic and hard links, special files | |
65 | and changing file access permissions. All changes are applied to the | |
66 | external inode table on unmounting the filesystem, leaving the data on | |
67 | the block device unchanged. | |
68 | ||
05a3c9e0 JR |
69 | %description -l pl.UTF-8 |
70 | anyfs-tools dostarczają działającego w uniksowym stylu zestawu | |
71 | narzędzi do odzyskiwania i konwersji systemów plików. W pakiecie | |
72 | zawarte są następujące narzędzia: | |
9ae21f85 | 73 | |
05a3c9e0 JR |
74 | build_it wykorzystuje linuksowe sterowniki systemów plików do |
75 | rekurencyjnego odczytu wpisów katalogów w celu uzyskania informacji o | |
76 | wszystkich i-węzłach systemu plików. Informacje te są następnie | |
77 | zapisywane do zewnętrznej tabeli i-węzłów. | |
9ae21f85 | 78 | |
05a3c9e0 JR |
79 | anysurrect przeszukuje urządzenia blokowe pod kątem określonych |
80 | rodzajów plików w oparciu o ich strukturę plików. Inforamcje o każdym | |
81 | znalezionym rodzaju pliku są także zapisywane do zewnętrznej tabeli | |
82 | i-węzłów. | |
9ae21f85 | 83 | |
05a3c9e0 JR |
84 | reblock zmienia rozmiar bloku systemu plików. Wykorzystuje informacje |
85 | o tabeli i-węzłów systemu plików, aby zmienić rozmieszczenie | |
86 | fragmentów każdego pliku w taki sposób, by były wyrównane do granic | |
87 | bloków przy nowym ich rozmiarze. | |
9ae21f85 | 88 | |
05a3c9e0 JR |
89 | build_e2fs na podstawie zewnętrznej informacji o tabeli i-węzłów |
90 | przystępuje do tworzenia systemu plików ext2fs na urządzeniu. | |
9ae21f85 | 91 | |
05a3c9e0 JR |
92 | build_xfs na podstawie zewnętrznej informacji o tabeli i-węzłów |
93 | przystępuje do tworzenia systemu plików xfs na urządzeniu. | |
9ae21f85 | 94 | |
05a3c9e0 | 95 | anyconvertfs konwertuje system plików stosując inne narzędzia |
9ae21f85 JB |
96 | anyfs-tools. |
97 | ||
05a3c9e0 JR |
98 | Sterownik systemu plików anyfs dla Linuksa pozwala użytkownikowi |
99 | podmontować urządzenie przy użyciu zewnętrznych informacji o tabeli | |
100 | i-węzłów stworzonej przy użyciu polecenia build_it lub anysurrect. Po | |
101 | podmontowaniu systemu plików użytkownik może wykonywać operacje na | |
102 | plikach, takie jak usuwanie, przenoszenie, tworzenie dowiązań | |
103 | symbolicznych i zwykłych czy urządzeń specjalnych oraz zmiana | |
104 | uprawnień do plików. Wszystkie zmiany są wykonywane na zewnętrznej | |
105 | tabeli i-węzłów przy odmontowywaniu systemu plików, bez zmiany danych | |
106 | na urządzeniu blokowym. | |
9ae21f85 | 107 | |
21d472d1 JB |
108 | %package devel |
109 | Summary: Header files for anyfs-tools | |
110 | Summary(pl.UTF-8): Pliki nagłówkowe anyfs-tools | |
111 | Group: Development/Libraries | |
112 | Requires: %{name} = %{version}-%{release} | |
113 | ||
114 | %description devel | |
115 | Header files for anyfs-tools. | |
116 | ||
117 | %description devel -l pl.UTF-8 | |
118 | Pliki nagłówkowe anyfs-tools. | |
119 | ||
696084fd | 120 | %package -n kernel%{_alt_kernel}-misc-any |
0d83f2e3 | 121 | Summary: AnyFS Linux kernel module |
122 | Summary(pl.UTF-8): Moduł jądra Linuksa AnyFS | |
123 | Release: %{_rel}@%{_kernel_ver_str} | |
124 | License: GPL v2 | |
125 | Group: Base/Kernel | |
126 | Requires(post,postun): /sbin/depmod | |
696084fd | 127 | %if %{with dist_kernel} |
128 | %requires_releq_kernel | |
0d83f2e3 | 129 | Requires(postun): %releq_kernel |
696084fd | 130 | %endif |
131 | %if "%{_alt_kernel}" != "%{nil}" | |
0d83f2e3 | 132 | Provides: kernel-misc-any |
696084fd | 133 | %endif |
134 | ||
135 | %description -n kernel%{_alt_kernel}-misc-any | |
21d472d1 | 136 | This package contains the AnyFS Linux kernel module. |
696084fd | 137 | |
21d472d1 JB |
138 | %description -n kernel%{_alt_kernel}-misc-any -l pl.UTF-8 |
139 | Ten pakiet zawiera moduł jądra Linuksa AnyFS. | |
430df31f | 140 | |
141 | %prep | |
142 | %setup -q | |
da6ae5d5 | 143 | %patch0 -p0 |
21d472d1 JB |
144 | |
145 | %if %{with kernel} | |
696084fd | 146 | cat > anyfs/Makefile <<'EOF' |
147 | obj-m += any.o | |
148 | any-objs := inode.o file.o dir.o namei.o symlink.o | |
149 | EOF | |
21d472d1 | 150 | %endif |
430df31f | 151 | |
152 | %build | |
21d472d1 | 153 | %if %{with userspace} |
430df31f | 154 | %configure |
da6ae5d5 | 155 | %{__make} libany |
156 | %{__make} progs | |
21d472d1 | 157 | %endif |
31cfd24d | 158 | |
696084fd | 159 | %if %{with kernel} |
160 | %build_kernel_modules -C anyfs -m any | |
161 | %endif | |
430df31f | 162 | |
163 | %install | |
164 | rm -rf $RPM_BUILD_ROOT | |
165 | ||
21d472d1 | 166 | %if %{with userspace} |
430df31f | 167 | %{__make} install \ |
168 | DESTDIR=$RPM_BUILD_ROOT | |
c939ee5d | 169 | |
bdadd437 JB |
170 | %if "%{_lib}" != "lib" |
171 | mv -f $RPM_BUILD_ROOT%{_prefix}/lib $RPM_BUILD_ROOT%{_libdir} | |
172 | %endif | |
173 | ||
c939ee5d | 174 | %find_lang %{name} |
21d472d1 | 175 | %endif |
430df31f | 176 | |
696084fd | 177 | %if %{with kernel} |
9294e6ef | 178 | %install_kernel_modules -m anyfs/any -d kernel/fs -n any -s current |
696084fd | 179 | %endif |
180 | ||
430df31f | 181 | %clean |
182 | rm -rf $RPM_BUILD_ROOT | |
183 | ||
7c9ee309 | 184 | %post -n kernel%{_alt_kernel}-misc-any |
185 | %depmod %{_kernel_ver} | |
186 | ||
187 | %postun -n kernel%{_alt_kernel}-misc-any | |
188 | %depmod %{_kernel_ver} | |
189 | ||
21d472d1 | 190 | %if %{with userspace} |
430df31f | 191 | %files -f %{name}.lang |
192 | %defattr(644,root,root,755) | |
9ae21f85 JB |
193 | %doc README THANKS |
194 | %lang(ru) %doc README.ru | |
da6ae5d5 | 195 | %attr(755,root,root) %{_bindir}/anyfuse |
bdadd437 | 196 | %attr(755,root,root) %{_sbindir}/* |
430df31f | 197 | %{_mandir}/man5/* |
198 | %{_mandir}/man8/* | |
9ae21f85 | 199 | %lang(ru) %{_mandir}/ru/man5/* |
da6ae5d5 | 200 | %lang(ru) %{_mandir}/ru/man8/* |
430df31f | 201 | |
21d472d1 JB |
202 | %files devel |
203 | %defattr(644,root,root,755) | |
bdadd437 | 204 | %{_libdir}/libany.a |
21d472d1 | 205 | %{_includedir}/anyfs-tools |
bdadd437 JB |
206 | %{_mandir}/man3/* |
207 | %lang(ru) %{_mandir}/ru/man3/* | |
21d472d1 JB |
208 | %endif |
209 | ||
696084fd | 210 | %if %{with kernel} |
211 | %files -n kernel%{_alt_kernel}-misc-any | |
212 | %defattr(644,root,root,755) | |
31cfd24d | 213 | /etc/modprobe.d/%{_kernel_ver}/any.conf |
214 | /lib/modules/%{_kernel_ver}/kernel/fs/any-current.ko* | |
696084fd | 215 | %endif |