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