]>
Commit | Line | Data |
---|---|---|
5f5a8b21 | 1 | # |
2 | # Conditional build: | |
248dd4dd | 3 | %bcond_without ea # build without support for linux extented attributes |
12760b79 | 4 | %bcond_without static # build without dar_static |
9369df59 | 5 | %bcond_without static_libs # don't build static libraries |
097d504f | 6 | # |
a5f8478f | 7 | %if %{with static} |
8 | %define with_static_libs 1 | |
9 | %endif | |
10 | # | |
fbe89be6 | 11 | Summary: dar makes backup of a directory tree and files |
83798cfc | 12 | Summary(pl.UTF-8): dar - narzędzie do tworzenia kopii zapasowych drzew katalogów i plików |
fbe89be6 | 13 | Name: dar |
6c29cac9 | 14 | Version: 2.3.3 |
edcac7c2 | 15 | Release: 2 |
9f50fcb5 | 16 | License: GPL v2 |
0e3cdb42 | 17 | Group: Applications/Archiving |
845d862f | 18 | Source0: http://dl.sourceforge.net/%{name}/%{name}-%{version}.tar.gz |
6c29cac9 | 19 | # Source0-md5: 30b2e488f11e1ab60510fa198de23791 |
097d504f | 20 | Patch0: %{name}-opt.patch |
fbe89be6 | 21 | URL: http://dar.linux.free.fr/ |
248dd4dd | 22 | %{?with_ea:BuildRequires: attr-devel >= 2.4.16-3} |
8732677b | 23 | BuildRequires: autoconf >= 2.59 |
097d504f | 24 | BuildRequires: automake |
efc8da18 | 25 | BuildRequires: bzip2-devel |
e4cfcb7c | 26 | BuildRequires: doxygen >= 1:1.3 |
b9414f71 JB |
27 | %ifarch alpha |
28 | # ICE in 3.3.x up to 3.3.2 - require patched version | |
29 | BuildRequires: gcc-c++ >= 5:3.3.2-0.3 | |
30 | %endif | |
d900f495 | 31 | BuildRequires: gettext-devel |
853009b5 | 32 | BuildRequires: groff |
efc8da18 | 33 | BuildRequires: libstdc++-devel |
57d80953 | 34 | BuildRequires: libtool >= 2:1.4d |
0e3cdb42 | 35 | BuildRequires: openssl-devel >= 0.9.7k |
efc8da18 | 36 | BuildRequires: zlib-devel |
42343508 | 37 | %if %{with static} |
248dd4dd | 38 | %{?with_ea:BuildRequires: attr-static} |
efc8da18 | 39 | BuildRequires: bzip2-static |
5f5a8b21 | 40 | BuildRequires: glibc-static |
41 | BuildRequires: libstdc++-static | |
d900f495 | 42 | BuildRequires: openssl-static |
5f5a8b21 | 43 | BuildRequires: zlib-static |
44 | %endif | |
5a9f3364 | 45 | Requires: %{name}-libs = %{version}-%{release} |
fbe89be6 | 46 | BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n) |
47 | ||
a5f8478f | 48 | # don't generate `Requires' for sample scripts |
49 | %define _noautoreq bash perl | |
50 | ||
fbe89be6 | 51 | %description |
fbe89be6 | 52 | dar is a shell command, that makes backup of a directory tree and |
53 | files. | |
54 | ||
55 | FILTERS: dar is able to backup from total file system to a single | |
56 | file. Additionally a mechanism of filters permits, based on the | |
57 | filename, to exclude or include some files while backing up or | |
58 | restoring a directory tree. In the other side, a secondary filter | |
59 | mechanism permits to exclude some branches of a directory tree, or to | |
60 | only include some branches. | |
61 | ||
62 | DIFFERENTIAL BACKUP: When making a backup with dar, you have the | |
63 | possibility to make a full backup or a differential backup. A full | |
64 | backup, as expected makes backup of all files as specified on the | |
65 | command line (with or without filters). Instead, a differential | |
66 | backup, (over filter mechanism), saves only files that have changed | |
67 | since a given reference backup. Additionally, files that existed in | |
68 | the reference backup and which do no more exist at the time of the | |
69 | differential backup are recorded in the backup. At recovery time, | |
70 | (unless you deactivate it), restoring a differential backup will | |
71 | update changed files and new files, but also remove files that have | |
72 | been recorded as deleted. Note that the reference backup can be a full | |
73 | backup or another differential backup. This way you can make a first | |
74 | full backup, then many differential backup, each taking as reference | |
75 | the last backup made. | |
76 | ||
77 | SLICES: Dar stands for Disk ARchive. From the beginning it was | |
78 | designed to be able to split an archive over several removable media | |
79 | whatever their number is and whatever their size is. Thus dar is able | |
80 | to save over old floppy disk, CD-R, DVD-R, CD-RW, DVD-RW, Zip, Jazz, | |
81 | etc... Dar is not concerned by un/mounting a removable medium, instead | |
82 | it is independent of hardware. Given the size, it will split the | |
83 | archive in several files (called SLICES), eventually pausing before | |
84 | creating the next one, allowing this way, the user to un/mount a | |
85 | medium, burn the file on CD-R, send it by email (if your mail system | |
86 | does not allow huge file in emails, dar can help you here also). By | |
87 | default, (no size specified), dar will make one slice whatever its | |
88 | size is. Additionally, the size of the first slice can be specified | |
89 | separately, if for example you want first to fulfil a partially filled | |
90 | disk before starting using empty ones. Last, at restoration time, dar | |
91 | will just pause and prompt the user asking a slice only if it is | |
92 | missing. | |
93 | ||
94 | COMPRESSION: last, dar can use compression. By default no compression | |
95 | is used. Actually only gzip algorithm is implemented, but some room | |
96 | has been done for bzip2 and any other compression algorithm. Note | |
97 | that, compression is made before slices, which means that using | |
98 | compression with slices, will not make slices smaller, but will | |
99 | probably make less slices in the backup. | |
100 | ||
101 | DIRECT ACCESS: even using compression dar has not to read the whole | |
102 | backup to extract one file. This way if you just want to restore one | |
103 | file from a huge backup, the process will be much faster than using | |
104 | tar. Dar first reads the catalogue (i.e. the contents of the backup), | |
105 | then it goes directly to the location of the saved file(s) you want to | |
106 | restore and proceed to restoration. In particular using slices dar | |
107 | will ask only for the slice(s) containing the file(s) to restore. | |
108 | ||
109 | HARD LINK CONSIDERATION: hard links are now properly saved. They are | |
110 | properly restored if possible. If for example restoring across a | |
111 | mounted filesystem, hard linking will fail, but dar will then | |
112 | duplicate the inode and file content, issuing a warning. | |
113 | ||
114 | EXTENDED ATTRIBUTES: support for extended attributes have to be | |
115 | activated at compilation time (see INSTALL). Dar is able to save and | |
116 | restore EA, all or just those of a given namespace (system or user). | |
117 | If no EA have been saved and restoration occurs over a file that has | |
118 | EA, they will be preserved. But if they have been saved empty for a | |
119 | given file, any existing EA for that file will be removed at | |
120 | restoration time, unless -u and/or -U is given on command-line. | |
121 | ||
122 | ARCHIVE TESTING thanks to CRC (cyclic redundancy checks), dar is able | |
123 | to detect data corruption in the archive. Only the file where data | |
124 | corruption occurred will not be possible to restore, but dar will | |
125 | restore the other even when compression is used. | |
126 | ||
127 | USING PIPES dar is now able to produce an archive to its standard | |
128 | output or named pipe. it is also able to read an archive through a | |
129 | pair of pipes, to take a remote archive as reference, or even to | |
130 | restore data from a remote archive. This way it is now possible to | |
131 | store an archive remotely and in total security (if using encrypted | |
132 | means) | |
133 | ||
134 | ISOLATION the catalogue (i.e.: the contents of an archive), can be | |
135 | extracted (this operation is called isolation) to a small file, that | |
136 | can in turn be used as reference for differential archive. There is no | |
137 | more need to provide an archive to be able to create a differential | |
138 | backup over it, just its catalogue is necessary. | |
139 | ||
140 | RE-SHAPE SLICES OF AN EXISTING ARCHIVE the external program named | |
141 | "dar_xform" is able to change the size of slices of a given archive. | |
142 | The resulting archive is totally identical to archives directly | |
143 | created by dar. Source archive can be taken from a set of slice, from | |
144 | standard input or even a named pipe. | |
145 | ||
9b828d75 JR |
146 | %description -l pl.UTF-8 |
147 | dar jest poleceniem powłoki, które tworzy kopie zapasowe drzew | |
148 | katalogów i plików. Możliwości: | |
149 | - Filtry: dar może tworzyć kopię zapasową całego systemu plików do | |
150 | pojedynczego pliku; mechanizm filtrów pozwala wyłączać lub dołączać | |
b0d714a3 | 151 | pliki przy tworzeniu kopii lub odtwarzaniu z niej. |
9b828d75 JR |
152 | - Backup różnicowy: dar może tworzyć kopie pełne lub różnicowe |
153 | (zawierające tylko te pliki, które zmieniły się od innego backupu) | |
154 | - Części (slices): dar oznacza "Disk ARchive". Od początku ma | |
155 | możliwość dzielenia archiwów na różne nośniki wymienialne, | |
156 | niezależnie od ich liczby i rozmiaru (można tworzyć kopie na CD-R, | |
b0d714a3 | 157 | DVD-R, CD-RW, Zip, Jazz...). |
9b828d75 | 158 | - Kompresja: domyślnie dar nie kompresuje danych; ma zaimplementowany |
b0d714a3 | 159 | algorytm gzip, jest przygotowywany do bzip2 i innych. Kompresja jest |
9b828d75 JR |
160 | wykonywana przed podziałem na części. |
161 | - Bezpośredni dostęp: nawet w przypadku użycia kompresji, dar nie musi | |
162 | czytać całej kopii aby odtworzyć jeden plik. Najpierw odczytuje | |
163 | katalog, następnie skacze od razu do właściwego miejsca. | |
164 | - Obsługa twardych dowiązań: dar zachowuje i odtwarza je w miarę | |
165 | możliwości; w przypadku niemożliwości wykonania dowiązania, powiela | |
166 | plik i wypisuje ostrzeżenie. | |
167 | - Obsługa rozszerzonych atrybutów (zależnie od opcji kompilacji): dar | |
168 | potrafi zachowywać i odtwarzać rozszerzone atrybuty - wszystkie lub | |
169 | tylko dotyczące danej przestrzeni nazw (systemowej lub użytkownika). | |
170 | - Testowanie archiwów: dzięki użyciu CRC dar wykrywa uszkodzone dane; | |
171 | tylko uszkodzone pliki nie zostaną odtworzone, reszta tak - nawet w | |
172 | przypadku użycia kompresji. | |
173 | - Użycie rurek - dar może wyprodukować archiwum na standardowe wyjście | |
174 | lub do nazwanej rurki. Może także czytać archiwum z pary rurek, a | |
175 | nawet odtwarzać ze zdalnego archiwum. | |
176 | - Rozdzielenie: katalog (zawartość archiwum) może być wyciągnięty do | |
177 | małego pliku, który może być używany jako odniesienie dla | |
178 | różnicowego backupu. | |
179 | - Przekształcanie części istniejącego archiwum: zewnętrzny program o | |
180 | nazwie dar_xform jest w stanie zmieniać rozmiary części podanego | |
181 | archiwum. Może czytać z zestawu kawałków, standardowego wejścia lub | |
b0d714a3 JB |
182 | nazwanej rurki. |
183 | ||
5f5a8b21 | 184 | %package static |
b67216c8 | 185 | Summary: Static version of dar backup tool |
83798cfc | 186 | Summary(pl.UTF-8): Statyczna wersja archiwizatora dar |
5f5a8b21 | 187 | Group: Applications |
188 | ||
189 | %description static | |
190 | Static version of dar backup tool. | |
191 | ||
9b828d75 | 192 | %description static -l pl.UTF-8 |
5f5a8b21 | 193 | Statyczna wersja archiwizatora dar. |
194 | ||
5a9f3364 JB |
195 | %package libs |
196 | Summary: Shared version of dar library | |
83798cfc | 197 | Summary(pl.UTF-8): Współdzielona wersja biblioteki dar |
c8a764ad | 198 | Group: Libraries |
5a9f3364 JB |
199 | |
200 | %description libs | |
201 | Shared version of dar library. | |
202 | ||
9b828d75 JR |
203 | %description libs -l pl.UTF-8 |
204 | Współdzielona wersja biblioteki dar. | |
5a9f3364 | 205 | |
09a398d2 | 206 | %package devel |
c8a764ad | 207 | Summary: Header files to develop dar software |
83798cfc | 208 | Summary(pl.UTF-8): Pliki nagłówkowe biblioteki dar |
c8a764ad | 209 | Group: Development/Libraries |
210 | Requires: %{name}-libs = %{version}-%{release} | |
b7684ca4 JB |
211 | %{?with_ea:Requires: attr-devel >= 2.4.16-3} |
212 | Requires: bzip2-devel | |
213 | Requires: libstdc++-devel | |
c33a8d55 | 214 | Requires: openssl-devel |
3cc31188 | 215 | Requires: zlib-devel |
09a398d2 | 216 | |
217 | %description devel | |
097d504f | 218 | Header files to develop software which operates on dar. |
09a398d2 | 219 | |
9b828d75 JR |
220 | %description devel -l pl.UTF-8 |
221 | Pliki nagłówkowe potrzebne do rozwoju oprogramowania korzystającego z | |
097d504f JB |
222 | dara. |
223 | ||
224 | %package libs-static | |
225 | Summary: Static version of dar library | |
83798cfc | 226 | Summary(pl.UTF-8): Statyczna wersja biblioteki dar |
c8a764ad | 227 | Group: Development/Libraries |
228 | Requires: %{name}-devel = %{version}-%{release} | |
097d504f JB |
229 | |
230 | %description libs-static | |
231 | Static version of dar library. | |
232 | ||
9b828d75 | 233 | %description libs-static -l pl.UTF-8 |
097d504f | 234 | Statyczna wersja biblioteki dar. |
09a398d2 | 235 | |
bca9e56e | 236 | %package doc |
237 | Summary: dar - documentation | |
83798cfc | 238 | Summary(pl.UTF-8): dar - dokumentacja |
bca9e56e | 239 | Group: Documentation |
240 | Requires: %{name} = %{version}-%{release} | |
241 | ||
242 | %description doc | |
243 | Dar ducumentation. | |
244 | ||
9b828d75 | 245 | %description -l pl.UTF-8 |
bca9e56e | 246 | Dokumentacja dla dar. |
247 | ||
fbe89be6 | 248 | %prep |
249 | %setup -q | |
e42712d8 | 250 | %patch0 -p1 |
fbe89be6 | 251 | |
252 | %build | |
a5f8478f | 253 | %{__gettextize} |
09a398d2 | 254 | %{__libtoolize} |
255 | %{__aclocal} | |
256 | %{__autoconf} | |
257 | %{__autoheader} | |
258 | %{__automake} | |
259 | %configure \ | |
bac87f6c | 260 | %{!?with_ea:--disable-ea-support} \ |
248dd4dd | 261 | %{!?with_static:--disable-dar-static} \ |
a5f8478f | 262 | --enable-static=%{?with_static_libs:yes}%{!?with_static_libs:no} \ |
12760b79 | 263 | --enable-mode=64 \ |
09a398d2 | 264 | --disable-upx |
265 | %{__make} | |
fbe89be6 | 266 | |
267 | %install | |
268 | rm -rf $RPM_BUILD_ROOT | |
42343508 | 269 | %{?with_static:install -d $RPM_BUILD_ROOT/bin} |
5f5a8b21 | 270 | |
097d504f JB |
271 | %{__make} install \ |
272 | DESTDIR=$RPM_BUILD_ROOT | |
fbe89be6 | 273 | |
42343508 | 274 | %{?with_static:mv -f $RPM_BUILD_ROOT{%{_bindir},/bin}/dar_static} |
5f5a8b21 | 275 | |
bca9e56e | 276 | ln -sf %{_datadir}/%{name} misc/doc |
a9720b1c | 277 | |
bac87f6c KK |
278 | %find_lang %{name} |
279 | ||
fbe89be6 | 280 | %clean |
281 | rm -rf $RPM_BUILD_ROOT | |
282 | ||
5a9f3364 JB |
283 | %post libs -p /sbin/ldconfig |
284 | %postun libs -p /sbin/ldconfig | |
09a398d2 | 285 | |
bac87f6c | 286 | %files -f %{name}.lang |
fbe89be6 | 287 | %defattr(644,root,root,755) |
bca9e56e | 288 | %doc ChangeLog NEWS README THANKS TODO misc/doc |
edcac7c2 | 289 | %dir %{_datadir}/%{name} |
d428284d | 290 | %attr(755,root,root) %{_bindir}/* |
f0835823 | 291 | %{_mandir}/man1/*.1* |
5f5a8b21 | 292 | |
97597b5c | 293 | %files libs |
5a9f3364 | 294 | %defattr(644,root,root,755) |
12760b79 | 295 | %attr(755,root,root) %{_libdir}/libdar64.so.*.*.* |
97597b5c | 296 | |
09a398d2 | 297 | %files devel |
298 | %defattr(644,root,root,755) | |
12760b79 KK |
299 | %attr(755,root,root) %{_libdir}/libdar64.so |
300 | %{_libdir}/libdar64.la | |
09a398d2 | 301 | %{_includedir}/dar |
853009b5 | 302 | %{_pkgconfigdir}/libdar64.pc |
09a398d2 | 303 | |
42343508 | 304 | %if %{with static} |
5f5a8b21 | 305 | %files static |
306 | %defattr(644,root,root,755) | |
307 | %attr(755,root,root) /bin/* | |
308 | %endif | |
097d504f | 309 | |
9369df59 | 310 | %if %{with static_libs} |
097d504f JB |
311 | %files libs-static |
312 | %defattr(644,root,root,755) | |
12760b79 | 313 | %{_libdir}/libdar64.a |
9369df59 | 314 | %endif |
bca9e56e | 315 | |
316 | %files doc | |
317 | %defattr(644,root,root,755) | |
edcac7c2 | 318 | %{_datadir}/%{name}/* |