1 .\" Copyright (c) 2011 Tim Kientzle
2 .\" All rights reserved.
4 .\" Redistribution and use in source and binary forms, with or without
5 .\" modification, are permitted provided that the following conditions
7 .\" 1. Redistributions of source code must retain the above copyright
8 .\" notice, this list of conditions and the following disclaimer.
9 .\" 2. Redistributions in binary form must reproduce the above copyright
10 .\" notice, this list of conditions and the following disclaimer in the
11 .\" documentation and/or other materials provided with the distribution.
13 .\" THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND
14 .\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
15 .\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
16 .\" ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE
17 .\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
18 .\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
19 .\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
20 .\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
21 .\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
22 .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
28 .Dt ARCHIVE_READ_OPTIONS 3
31 .Nm archive_read_set_filter_option ,
32 .Nm archive_read_set_format_option ,
33 .Nm archive_read_set_option ,
34 .Nm archive_read_set_options
35 .Nd functions controlling options for reading archives
38 Streaming Archive Library (libarchive, -larchive)
41 .Fo archive_read_set_filter_option
42 .Fa "struct archive *"
43 .Fa "const char *module"
44 .Fa "const char *option"
45 .Fa "const char *value"
48 .Fo archive_read_set_format_option
49 .Fa "struct archive *"
50 .Fa "const char *module"
51 .Fa "const char *option"
52 .Fa "const char *value"
55 .Fo archive_read_set_option
56 .Fa "struct archive *"
57 .Fa "const char *module"
58 .Fa "const char *option"
59 .Fa "const char *value"
62 .Fo archive_read_set_options
63 .Fa "struct archive *"
64 .Fa "const char *options"
67 These functions provide a way for libarchive clients to configure
68 specific read modules.
69 .Bl -tag -width indent
71 .Fn archive_read_set_filter_option ,
72 .Fn archive_read_set_format_option
74 Specifies an option that will be passed to currently-registered
75 filters (including decompression filters) or format readers.
83 these functions will do nothing and
92 is not, these functions will do nothing and
103 will be provided to the filter or reader named
105 The return value will be that of the module.
106 If there is no such module,
117 will be provided to every registered module.
118 If any module returns
120 this value will be returned immediately.
123 will be returned if any module accepts the option, and
128 .Fn archive_read_set_option
131 .Fn archive_read_set_format_option ,
133 .Fn archive_read_set_filter_option .
134 If either function returns
139 Otherwise, greater of the two values will be returned.
142 .Fn archive_read_set_options
145 is a comma-separated list of options.
152 will be returned immediately.
155 .Fn archive_read_set_option
156 with each option in turn.
158 .Fn archive_read_set_option
162 will be returned immediately.
164 Individual options have one of the following forms:
165 .Bl -tag -compact -width indent
167 The option/value pair will be provided to every module.
168 Modules that do not accept an option with this name will ignore it.
170 The option will be provided to every module with a value of
173 The option will be provided to every module with a NULL value.
174 .It Ar module:option=value , Ar module:option , Ar module:!option
175 As above, but the corresponding option and value will be provided
176 only to modules whose name matches
182 .Bl -tag -compact -width indent
184 .Bl -tag -compact -width indent
186 Support Joliet extensions.
187 Defaults to enabled, use
191 Support RockRidge extensions.
192 Defaults to enabled, use
197 .Bl -tag -compact -width indent
199 Libarchive 2.x incorrectly encoded Unicode filenames on
201 This option mimics the libarchive 2.x filename handling
202 so that such archives can be read correctly.
204 The value is used as a character set name that will be
205 used when translating filenames.
207 Support Mac OS metadata extension that records data in special
208 files beginning with a period and underscore.
209 Defaults to enabled on Mac OS, disabled on other platforms.
213 .It Cm read_concatenated_archives
214 Ignore zeroed blocks in the archive, which occurs when multiple tar archives
215 have been concatenated together. Without this option, only the contents of
216 the first concatenated archive would be read.
221 Detailed error codes and textual descriptions are available from the
224 .Fn archive_error_string
230 .Xr archive_write_set_options 3 ,