libtar-1.2.11 tarball sources, taken from Debian's orig tar
[libtar.git] / doc / tar_extract_all.3
blob61759a712f6c0665b4a2b46f315cc61845bf8ea5
1 .TH tar_extract_all 3 "Jan 2001" "University of Illinois" "C Library Calls"
2 .SH NAME
3 tar_extract_all, tar_extract_glob, tar_append_tree \- high-level tar
4 archive manipulation functions
5 .SH SYNOPSIS
6 .B #include <libtar.h>
7 .P
8 .BI "int tar_extract_all(TAR *" t ", char *" prefix ");"
10 .BI "int tar_extract_glob(TAR *" t ", char *" globname ","
11 .BI "char *" prefix ");"
13 .BI "int tar_append_tree(TAR *" t ", char *" realdir ","
14 .BI "char *" savedir ");"
15 .SH VERSION
16 This man page documents version 1.2 of \fBlibtar\fP.
17 .SH DESCRIPTION
18 The \fBtar_extract_all\fP() function extracts all files from the tar
19 archive associated with the \fITAR\fP handle \fIt\fP into the path
20 named by the \fIprefix\fP argument.
22 The \fBtar_extract_glob\fP() function extracts all files matching
23 the given \fIglob\fP pattern from the tar archive associated with the
24 \fITAR\fP handle \fIt\fP into the path named by the \fIprefix\fP argument.
26 The \fBtar_append_tree\fP() function appends all files from the
27 directory tree named by \fIrealdir\fP to the tar archive associated with
28 the \fITAR\fP handle \fIt\fP.  The pathnames stored in the tar archive
29 are modified by replacing \fIrealdir\fP with \fIsavedir\fP, so that the
30 files will be extracted into \fIsavedir\fP.
31 .SH RETURN VALUES
32 On successful completion, these functions will return 0.  On failure,
33 they will return -1 and set \fIerrno\fP to an appropriate value.
34 .SH ERRORS
35 These functions will fail under the same conditions that the
36 \fBtar_skip_regfile\fP(), \fBtar_extract_regfile\fP(), \fBopendir\fP(),
37 \fBlstat\fP(), or \fBtar_append_file\fP() functions fail.
38 .SH SEE ALSO
39 .BR opendir (2),
40 .BR lstat (2),
41 .BR tar_skip_regfile (3),
42 .BR tar_extract_regfile (3),
43 .BR tar_append_file (3)