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