%!PS-Adobe-3.0 %%Creator: groff version 1.19.2 %%CreationDate: Wed Jun 30 11:55:53 2010 %%DocumentNeededResources: font Times-Roman %%DocumentSuppliedResources: procset grops 1.19 2 %%Pages: 58 %%PageOrder: Ascend %%DocumentMedia: Default 612 792 0 () () %%Orientation: Portrait %%EndComments %%BeginDefaults %%PageMedia: Default %%EndDefaults %%BeginProlog %%BeginResource: procset grops 1.19 2 %!PS-Adobe-3.0 Resource-ProcSet /setpacking where{ pop currentpacking true setpacking }if /grops 120 dict dup begin /SC 32 def /A/show load def /B{0 SC 3 -1 roll widthshow}bind def /C{0 exch ashow}bind def /D{0 exch 0 SC 5 2 roll awidthshow}bind def /E{0 rmoveto show}bind def /F{0 rmoveto 0 SC 3 -1 roll widthshow}bind def /G{0 rmoveto 0 exch ashow}bind def /H{0 rmoveto 0 exch 0 SC 5 2 roll awidthshow}bind def /I{0 exch rmoveto show}bind def /J{0 exch rmoveto 0 SC 3 -1 roll widthshow}bind def /K{0 exch rmoveto 0 exch ashow}bind def /L{0 exch rmoveto 0 exch 0 SC 5 2 roll awidthshow}bind def /M{rmoveto show}bind def /N{rmoveto 0 SC 3 -1 roll widthshow}bind def /O{rmoveto 0 exch ashow}bind def /P{rmoveto 0 exch 0 SC 5 2 roll awidthshow}bind def /Q{moveto show}bind def /R{moveto 0 SC 3 -1 roll widthshow}bind def /S{moveto 0 exch ashow}bind def /T{moveto 0 exch 0 SC 5 2 roll awidthshow}bind def /SF{ findfont exch [exch dup 0 exch 0 exch neg 0 0]makefont dup setfont [exch/setfont cvx]cvx bind def }bind def /MF{ findfont [5 2 roll 0 3 1 roll neg 0 0]makefont dup setfont [exch/setfont cvx]cvx bind def }bind def /level0 0 def /RES 0 def /PL 0 def /LS 0 def /MANUAL{ statusdict begin/manualfeed true store end }bind def /PLG{ gsave newpath clippath pathbbox grestore exch pop add exch pop }bind def /BP{ /level0 save def 1 setlinecap 1 setlinejoin 72 RES div dup scale LS{ 90 rotate }{ 0 PL translate }ifelse 1 -1 scale }bind def /EP{ level0 restore showpage }def /DA{ newpath arcn stroke }bind def /SN{ transform .25 sub exch .25 sub exch round .25 add exch round .25 add exch itransform }bind def /DL{ SN moveto SN lineto stroke }bind def /DC{ newpath 0 360 arc closepath }bind def /TM matrix def /DE{ TM currentmatrix pop translate scale newpath 0 0 .5 0 360 arc closepath TM setmatrix }bind def /RC/rcurveto load def /RL/rlineto load def /ST/stroke load def /MT/moveto load def /CL/closepath load def /Fr{ setrgbcolor fill }bind def /setcmykcolor where{ pop /Fk{ setcmykcolor fill }bind def }if /Fg{ setgray fill }bind def /FL/fill load def /LW/setlinewidth load def /Cr/setrgbcolor load def /setcmykcolor where{ pop /Ck/setcmykcolor load def }if /Cg/setgray load def /RE{ findfont dup maxlength 1 index/FontName known not{1 add}if dict begin { 1 index/FID ne{def}{pop pop}ifelse }forall /Encoding exch def dup/FontName exch def currentdict end definefont pop }bind def /DEFS 0 def /EBEGIN{ moveto DEFS begin }bind def /EEND/end load def /CNT 0 def /level1 0 def /PBEGIN{ /level1 save def translate div 3 1 roll div exch scale neg exch neg exch translate 0 setgray 0 setlinecap 1 setlinewidth 0 setlinejoin 10 setmiterlimit []0 setdash /setstrokeadjust where{ pop false setstrokeadjust }if /setoverprint where{ pop false setoverprint }if newpath /CNT countdictstack def userdict begin /showpage{}def /setpagedevice{}def }bind def /PEND{ countdictstack CNT sub{end}repeat level1 restore }bind def end def /setpacking where{ pop setpacking }if %%EndResource %%EndProlog %%BeginSetup %%BeginFeature: *PageSize Default << /PageSize [ 612 792 ] /ImagingBBox null >> setpagedevice %%EndFeature %%IncludeResource: font Times-Roman grops begin/DEFS 1 dict def DEFS begin/u{.001 mul}bind def end/RES 72 def/PL 792 def/LS false def/ENC0[/asciicircum/asciitilde/Scaron/Zcaron /scaron/zcaron/Ydieresis/trademark/quotesingle/Euro/.notdef/.notdef /.notdef/.notdef/.notdef/.notdef/.notdef/.notdef/.notdef/.notdef/.notdef /.notdef/.notdef/.notdef/.notdef/.notdef/.notdef/.notdef/.notdef/.notdef /.notdef/.notdef/space/exclam/quotedbl/numbersign/dollar/percent /ampersand/quoteright/parenleft/parenright/asterisk/plus/comma/hyphen /period/slash/zero/one/two/three/four/five/six/seven/eight/nine/colon /semicolon/less/equal/greater/question/at/A/B/C/D/E/F/G/H/I/J/K/L/M/N/O /P/Q/R/S/T/U/V/W/X/Y/Z/bracketleft/backslash/bracketright/circumflex /underscore/quoteleft/a/b/c/d/e/f/g/h/i/j/k/l/m/n/o/p/q/r/s/t/u/v/w/x/y /z/braceleft/bar/braceright/tilde/.notdef/quotesinglbase/guillemotleft /guillemotright/bullet/florin/fraction/perthousand/dagger/daggerdbl /endash/emdash/ff/fi/fl/ffi/ffl/dotlessi/dotlessj/grave/hungarumlaut /dotaccent/breve/caron/ring/ogonek/quotedblleft/quotedblright/oe/lslash /quotedblbase/OE/Lslash/.notdef/exclamdown/cent/sterling/currency/yen /brokenbar/section/dieresis/copyright/ordfeminine/guilsinglleft /logicalnot/minus/registered/macron/degree/plusminus/twosuperior /threesuperior/acute/mu/paragraph/periodcentered/cedilla/onesuperior /ordmasculine/guilsinglright/onequarter/onehalf/threequarters /questiondown/Agrave/Aacute/Acircumflex/Atilde/Adieresis/Aring/AE /Ccedilla/Egrave/Eacute/Ecircumflex/Edieresis/Igrave/Iacute/Icircumflex /Idieresis/Eth/Ntilde/Ograve/Oacute/Ocircumflex/Otilde/Odieresis /multiply/Oslash/Ugrave/Uacute/Ucircumflex/Udieresis/Yacute/Thorn /germandbls/agrave/aacute/acircumflex/atilde/adieresis/aring/ae/ccedilla /egrave/eacute/ecircumflex/edieresis/igrave/iacute/icircumflex/idieresis /eth/ntilde/ograve/oacute/ocircumflex/otilde/odieresis/divide/oslash /ugrave/uacute/ucircumflex/udieresis/yacute/thorn/ydieresis]def /Times-Roman@0 ENC0/Times-Roman RE %%EndSetup %%Page: 1 1 %%BeginPageSetup BP %%EndPageSetup /F0 10/Times-Roman@0 SF()0 12 Q()0 24 Q()36 36 Q (August 19, 2006 LIB)74.5 48 Q(ARCHIVE 3)-.35 E()36 72 Q 0 Cg EP %%Page: 2 2 %%BeginPageSetup BP %%EndPageSetup /F0 10/Times-Roman@0 SF()36 48 Q()0 60 Q ()-.15 E 0 Cg EP %%Page: 4 4 %%BeginPageSetup BP %%EndPageSetup /F0 10/Times-Roman@0 SF(

)-.35 E -.35(NA)36 24 S (ME).35 E(

)36 36 Q(libarchi)0 48 Q -.15(ve)-.25 G().15 E 2.5 (-f)0 60 S(unctions for reading and writing streaming archi)-2.5 E -.15 (ve)-.25 G(s).15 E(

)-.65 E 0 Cg EP %%Page: 5 5 %%BeginPageSetup BP %%EndPageSetup /F0 10/Times-Roman@0 SF(LIBRAR)36 12 Q(Y)-.65 E(

)36 24 Q(

)-.8 E -.5(OV)36 48 S(ER).5 E(VIEW)-.8 E(

) 36 60 Q(The)0 72 Q 0 Cg EP %%Page: 6 6 %%BeginPageSetup BP %%EndPageSetup /F0 10/Times-Roman@0 SF(libarchi)0 12 Q -.15(ve)-.25 G().15 E (library pro)0 24 Q(vides a \215e)-.15 E(xible interf)-.15 E (ace for reading and writing)-.1 E(streaming archi)0 36 Q .3 -.15 (ve \214)-.25 H(les such as tar and cpio.).15 E(The library is inherent\ ly stream-oriented; readers serially iterate through)0 48 Q(the archi)0 60 Q -.15(ve)-.25 G 2.5(,w).15 G (riters serially add things to the archi)-2.5 E -.15(ve)-.25 G(.).15 E (In particular)0 72 Q 2.5(,n)-.4 G(ote that there is no b)-2.5 E (uilt-in support for)-.2 E 0 Cg EP %%Page: 7 7 %%BeginPageSetup BP %%EndPageSetup /F0 10/Times-Roman@0 SF(random access nor for in-place modi\214cation.)0 12 Q(

)36 24 Q(When reading an archi)0 36 Q -.15(ve)-.25 G 2.5(,t).15 G(he library automatically detects the)-2.5 E (format and the compression.)0 48 Q (The library currently has read support for:)0 60 Q(

)0 12 Q (The library automatically detects archi)0 24 Q -.15(ve)-.25 G 2.5(sc) .15 G(ompressed with)-2.5 E(gzip\(1\),) 0 36 Q(bzip2\(1\),)0 48 Q(or)0 60 Q (compress\(1\))0 72 Q 0 Cg EP %%Page: 12 12 %%BeginPageSetup BP %%EndPageSetup /F0 10/Times-Roman@0 SF(and decompresses them transparently)0 12 Q(.) -.65 E(

)36 24 Q(When writing an archi)0 36 Q -.15(ve)-.25 G 2.5(,y) .15 G(ou can specify the compression)-2.5 E (to be used and the format to use.)0 48 Q(The library can write)0 60 Q (

)0 12 Q -.15(Pa)0 24 S 2.5(xi).15 G (nterchange format is an e)-2.5 E(xtension of the tar archi)-.15 E .3 -.15(ve f)-.25 H(ormat that).15 E (eliminates essentially all of the limitations of historic tar formats)0 36 Q(in a standard f)0 48 Q(ashion that is supported)-.1 E (by POSIX-compliant)0 60 Q(pax\(1\))0 72 Q 0 Cg EP %%Page: 16 16 %%BeginPageSetup BP %%EndPageSetup /F0 10/Times-Roman@0 SF(implementations on man)0 12 Q 2.5(ys)-.15 G (ystems as well as se)-2.5 E -.15(ve)-.25 G(ral ne).15 E (wer implementations of)-.25 E(tar\(1\).)-.55 E(Note that the def)0 36 Q (ault write format will suppress the pax e)-.1 E(xtended)-.15 E(attrib)0 48 Q(utes for most entries; e)-.2 E (xplicitly requesting pax format will)-.15 E(enable those attrib)0 60 Q (utes for all entries.)-.2 E(

)36 72 Q 0 Cg EP %%Page: 17 17 %%BeginPageSetup BP %%EndPageSetup /F0 10/Times-Roman@0 SF (The read and write APIs are accessed through the)0 12 Q(archi)0 24 Q -.15(ve)-.25 G(_read_XXX\(\)).15 E(functions and the)0 36 Q(archi)0 48 Q -.15(ve)-.25 G(_write_XXX\(\)).15 E(functions, respecti)0 60 Q -.15(ve)-.25 G(ly).15 E 2.5(,a)-.65 G (nd either can be used independently)-2.5 E(of the other)0 72 Q(.)-.55 E 0 Cg EP %%Page: 18 18 %%BeginPageSetup BP %%EndPageSetup /F0 10/Times-Roman@0 SF(

)36 12 Q(The rest of this manual page pro)0 24 Q(vides an o)-.15 E -.15(ve)-.15 G(rvie).15 E 2.5(wo)-.25 G 2.5(ft) -2.5 G(he library)-2.5 E(operation.)0 36 Q (More detailed information can be found in the indi)0 48 Q (vidual manual)-.25 E(pages for each API or utility function.)0 60 Q (

)36 72 Q 0 Cg EP %%Page: 19 19 %%BeginPageSetup BP %%EndPageSetup /F0 10/Times-Roman@0 SF(READING AN ARCHIVE)36 12 Q(

)36 24 Q 1.6 -.8 (To r)0 36 T(ead an archi).8 E -.15(ve)-.25 G 2.5(,y).15 G (ou must \214rst obtain an initialized)-2.5 E(struct archi)0 48 Q -.15(ve)-.25 G ().15 E(object from)0 60 Q(archi)0 72 Q -.15(ve)-.25 G (_read_ne).15 E(w\(\).)-.25 E 0 Cg EP %%Page: 20 20 %%BeginPageSetup BP %%EndPageSetup /F0 10/Times-Roman@0 SF -1.1(Yo)0 12 S 2.5(uc)1.1 G (an then modify this object for the desired operations with the)-2.5 E -.25(va)0 24 S(rious).25 E(archi)0 36 Q -.15(ve)-.25 G (_read_set_XXX\(\)).15 E(and)0 48 Q(archi)0 60 Q -.15(ve)-.25 G(_read_support_XXX\(\)).15 E(functions.)0 72 Q 0 Cg EP %%Page: 21 21 %%BeginPageSetup BP %%EndPageSetup /F0 10/Times-Roman@0 SF(In particular)0 12 Q 2.5(,y)-.4 G (ou will need to in)-2.5 E -.2(vo)-.4 G .2 -.1(ke a).2 H(ppropriate).1 E (archi)0 24 Q -.15(ve)-.25 G(_read_support_XXX\(\)) .15 E(functions to enable the corresponding compression and format)0 36 Q(support.)0 48 Q(Note that these latter functions perform tw)0 60 Q 2.5 (od)-.1 G(istinct operations:)-2.5 E(the)0 72 Q 2.5(yc)-.15 G (ause the corresponding support code to be link)-2.5 E(ed into your)-.1 E 0 Cg EP %%Page: 22 22 %%BeginPageSetup BP %%EndPageSetup /F0 10/Times-Roman@0 SF(program, and the)0 12 Q 2.5(ye)-.15 G (nable the corresponding auto-detect code.)-2.5 E(Unless you ha)0 24 Q .3 -.15(ve s)-.2 H(peci\214c constraints, you will generally w).15 E (ant)-.1 E(to in)0 36 Q -.2(vo)-.4 G -.1(ke).2 G(archi)0 48 Q -.15 (ve)-.25 G(_read_support_compression_all\(\)).15 E(and) 0 60 Q(archi)0 72 Q -.15(ve)-.25 G (_read_support_format_all\(\)).15 E 0 Cg EP %%Page: 23 23 %%BeginPageSetup BP %%EndPageSetup /F0 10/Times-Roman@0 SF (to enable auto-detect for all formats and compression types)0 12 Q (currently supported by the library)0 24 Q(.)-.65 E(

)36 36 Q (Once you ha)0 48 Q .3 -.15(ve p)-.2 H(repared the).15 E(struct archi)0 60 Q -.15 (ve)-.25 G().15 E(object, you call)0 72 Q 0 Cg EP %%Page: 24 24 %%BeginPageSetup BP %%EndPageSetup /F0 10/Times-Roman@0 SF(archi)0 12 Q -.15(ve)-.25 G (_read_open\(\)).15 E(to actually open the archi)0 24 Q .3 -.15(ve a)-.25 H(nd prepare it for reading.).15 E(There are se)0 36 Q -.15(ve)-.25 G(ral v).15 E(ariants of this function;)-.25 E (the most basic e)0 48 Q(xpects you to pro)-.15 E(vide pointers to se) -.15 E -.15(ve)-.25 G(ral).15 E(functions that can pro)0 60 Q (vide blocks of bytes from the archi)-.15 E -.15(ve)-.25 G(.).15 E (There are con)0 72 Q -.15(ve)-.4 G(nience forms that allo).15 E 2.5(wy) -.25 G(ou to)-2.5 E 0 Cg EP %%Page: 25 25 %%BeginPageSetup BP %%EndPageSetup /F0 10/Times-Roman@0 SF(specify a \214lename, \214le descriptor)0 12 Q (,)-.4 E(

FILE *)0 24 Q (object, or a block of memory from which to read the archi)0 36 Q .3 -.15(ve d)-.25 H(ata.).15 E(Note that the core library mak)0 48 Q (es no assumptions about the)-.1 E(size of the blocks read;)0 60 Q (callback functions are free to read whate)0 72 Q -.15(ve)-.25 G 2.5(rb) .15 G(lock size is)-2.5 E 0 Cg EP %%Page: 26 26 %%BeginPageSetup BP %%EndPageSetup /F0 10/Times-Roman@0 SF(most appropriate for the medium.)0 12 Q(

)36 24 Q(Each archi)0 36 Q .3 -.15(ve e)-.25 H (ntry consists of a header follo).15 E(wed by a certain)-.25 E (amount of data.)0 48 Q -1.1(Yo)0 60 S 2.5(uc)1.1 G(an obtain the ne) -2.5 E(xt header with)-.15 E(archi)0 72 Q -.15(ve)-.25 G(_read_ne).15 E(xt_header\(\),)-.15 E 0 Cg EP %%Page: 27 27 %%BeginPageSetup BP %%EndPageSetup /F0 10/Times-Roman@0 SF(which returns a pointer to an)0 12 Q(struct archi)0 24 Q -.15(ve)-.25 G(_entry).15 E (structure with information about the current archi)0 36 Q .3 -.15(ve e) -.25 H(lement.).15 E(If the entry is a re)0 48 Q (gular \214le, then the header will be follo)-.15 E(wed)-.25 E (by the \214le data.)0 60 Q -1.1(Yo)0 72 S 2.5(uc)1.1 G(an use)-2.5 E 0 Cg EP %%Page: 28 28 %%BeginPageSetup BP %%EndPageSetup /F0 10/Times-Roman@0 SF(archi)0 12 Q -.15(ve)-.25 G (_read_data\(\)).15 E(\(which w)0 24 Q(orks much lik) -.1 E 2.5(et)-.1 G(he)-2.5 E(read\(2\)) 0 36 Q(system call\))0 48 Q(to read this data from the archi)0 60 Q -.15 (ve)-.25 G(.).15 E -1.1(Yo)0 72 S 2.5(um)1.1 G (ay prefer to use the higher)-2.5 E(-le)-.2 E -.15(ve)-.25 G(l).15 E 0 Cg EP %%Page: 29 29 %%BeginPageSetup BP %%EndPageSetup /F0 10/Times-Roman@0 SF(archi)0 12 Q -.15(ve)-.25 G (_read_data_skip\(\),).15 E (which reads and discards the data for this entry)0 24 Q(,)-.65 E (archi)0 36 Q -.15(ve)-.25 G(_read_data_to_b).15 E(uf)-.2 E (fer\(\),)-.25 E (which reads the data into an in-memory b)0 48 Q(uf)-.2 E(fer)-.25 E(,) -.4 E(archi)0 60 Q -.15(ve)-.25 G (_read_data_to_\214le\(\),).15 E (which copies the data to the pro)0 72 Q(vided \214le descriptor)-.15 E 2.5(,o)-.4 G(r)-2.5 E 0 Cg EP %%Page: 30 30 %%BeginPageSetup BP %%EndPageSetup /F0 10/Times-Roman@0 SF(archi)0 12 Q -.15(ve)-.25 G(_read_e).15 E (xtract\(\),)-.15 E (which recreates the speci\214ed entry on disk and copies data)0 24 Q (from the archi)0 36 Q -.15(ve)-.25 G(.).15 E(In particular)0 48 Q 2.5 (,n)-.4 G(ote that)-2.5 E(archi)0 60 Q -.15(ve)-.25 G(_read_e).15 E (xtract\(\))-.15 E(uses the)0 72 Q 0 Cg EP %%Page: 31 31 %%BeginPageSetup BP %%EndPageSetup /F0 10/Times-Roman@0 SF(struct archi)0 12 Q -.15(ve)-.25 G(_entry).15 E (structure that you pro)0 24 Q(vide it, which may dif)-.15 E (fer from the)-.25 E(entry just read from the archi)0 36 Q -.15(ve)-.25 G(.).15 E(In particular)0 48 Q 2.5(,m)-.4 G(an)-2.5 E 2.5(ya)-.15 G (pplications will w)-2.5 E(ant to o)-.1 E -.15(ve)-.15 G(rride the).15 E (pathname, \214le permissions, or o)0 60 Q(wnership.)-.25 E(

)36 72 Q 0 Cg EP %%Page: 32 32 %%BeginPageSetup BP %%EndPageSetup /F0 10/Times-Roman@0 SF(Once you ha)0 12 Q .3 -.15(ve \214)-.2 H (nished reading data from the archi).15 E -.15(ve)-.25 G 2.5(,y).15 G (ou)-2.5 E(should call)0 24 Q(archi)0 36 Q -.15(ve)-.25 G (_read_close\(\)).15 E(to close the archi)0 48 Q -.15 (ve)-.25 G 2.5(,t).15 G(hen call)-2.5 E(archi)0 60 Q -.15(ve)-.25 G (_read_\214nish\(\)).15 E(to release all resources, in\ cluding all memory allocated by the library)0 72 Q(.)-.65 E 0 Cg EP %%Page: 33 33 %%BeginPageSetup BP %%EndPageSetup /F0 10/Times-Roman@0 SF(

)36 12 Q(The)0 24 Q(archi).15 E -.15(ve)-.25 G (_read\(3\)).15 E(manual page pro)0 48 Q (vides more detailed calling information for this API.)-.15 E (

)36 60 Q(WRITING AN ARCHIVE)36 72 Q 0 Cg EP %%Page: 34 34 %%BeginPageSetup BP %%EndPageSetup /F0 10/Times-Roman@0 SF(

)36 12 Q -1.1(Yo)0 24 S 2.5(uu)1.1 G (se a similar process to write an archi)-2.5 E -.15(ve)-.25 G(.).15 E (The)0 36 Q(archi)0 48 Q -.15(ve)-.25 G(_write_ne).15 E (w\(\))-.25 E(function creates an archi)0 60 Q .3 -.15 (ve o)-.25 H(bject useful for writing,).15 E(the v)0 72 Q(arious)-.25 E 0 Cg EP %%Page: 35 35 %%BeginPageSetup BP %%EndPageSetup /F0 10/Times-Roman@0 SF(archi)0 12 Q -.15(ve)-.25 G (_write_set_XXX\(\)).15 E (functions are used to set parameters for writing the archi)0 24 Q -.15 (ve)-.25 G 2.5(,a).15 G(nd)-2.5 E(archi)0 36 Q -.15(ve)-.25 G (_write_open\(\)).15 E (completes the setup and opens the archi)0 48 Q .3 -.15(ve f)-.25 H (or writing.).15 E(

)36 60 Q(Indi)0 72 Q(vidual archi)-.25 E .3 -.15 (ve e)-.25 H(ntries are written in a three-step).15 E 0 Cg EP %%Page: 36 36 %%BeginPageSetup BP %%EndPageSetup /F0 10/Times-Roman@0 SF(process:)0 12 Q -1.1(Yo)0 24 S 2.5<758c>1.1 G (rst initialize a)-2.5 E(struct<\ /font> archi)0 36 Q -.15(ve)-.25 G(_entry).15 E (structure with information about the ne)0 48 Q 2.5(we)-.25 G(ntry)-2.5 E(.)-.65 E(At a minimum, you should set the pathname of the)0 60 Q (entry and pro)0 72 Q(vide a)-.15 E 0 Cg EP %%Page: 37 37 %%BeginPageSetup BP %%EndPageSetup /F0 10/Times-Roman@0 SF(struct stat)0 12 Q (with a v)0 24 Q(alid)-.25 E(st_mode)0 36 Q (\214eld, which speci\214es the type of object and)0 48 Q (st_size)0 60 Q (\214eld, which speci\214es the size of the data portion of the object.) 0 72 Q 0 Cg EP %%Page: 38 38 %%BeginPageSetup BP %%EndPageSetup /F0 10/Times-Roman@0 SF(The)0 12 Q(archi)0 24 Q -.15(ve)-.25 G (_write_header\(\)).15 E (function actually writes the header data to the archi)0 36 Q -.15(ve) -.25 G(.).15 E -1.1(Yo)0 48 S 2.5(uc)1.1 G(an then use)-2.5 E(archi)0 60 Q -.15(ve)-.25 G(_write_data\(\)).15 E (to write the actual data.)0 72 Q 0 Cg EP %%Page: 39 39 %%BeginPageSetup BP %%EndPageSetup /F0 10/Times-Roman@0 SF(

)36 12 Q(After all entries ha)0 24 Q .3 -.15 (ve b)-.2 H(een written, use the).15 E(archi)0 36 Q -.15(ve)-.25 G (_write_\214nish\(\)).15 E (function to release all resources.)0 48 Q(

)36 60 Q(The)0 72 Q 0 Cg EP %%Page: 40 40 %%BeginPageSetup BP %%EndPageSetup /F0 10/Times-Roman@0 SF(archi).15 E -.15(ve)-.25 G(_write\(3\)).15 E (manual page pro)0 24 Q (vides more detailed calling information for this API.)-.15 E (

)36 36 Q(DESCRIPTION)36 48 Q(

)36 60 Q (Detailed descriptions of each function are pro)0 72 Q(vided by the)-.15 E 0 Cg EP %%Page: 41 41 %%BeginPageSetup BP %%EndPageSetup /F0 10/Times-Roman@0 SF(corresponding manual pages.)0 12 Q(

)36 24 Q (All of the functions utilize an opaque)0 36 Q(<\ font size="-1">struct archi)0 48 Q -.15(ve)-.25 G ().15 E(datatype that pro)0 60 Q(vides access to the archi)-.15 E .3 -.15(ve c)-.25 H(ontents.).15 E(

)36 72 Q 0 Cg EP %%Page: 42 42 %%BeginPageSetup BP %%EndPageSetup /F0 10/Times-Roman@0 SF(The)0 12 Q(struct archi)0 24 Q -.15(ve)-.25 G (_entry).15 E (structure contains a complete description of a single archi)0 36 Q -.15 (ve)-.25 G(entry)0 48 Q(.)-.65 E(It uses an opaque interf)0 60 Q (ace that is fully documented in)-.1 E(archi)-.65 E -.15(ve)-.25 G (_entry\(3\).).15 E 0 Cg EP %%Page: 43 43 %%BeginPageSetup BP %%EndPageSetup /F0 10/Times-Roman@0 SF(

)36 12 Q(Users f)0 24 Q (amiliar with historic formats should be a)-.1 E -.1(wa)-.15 G (re that the ne).1 E(wer)-.25 E -.25(va)0 36 S(riants ha).25 E .3 -.15 (ve e)-.2 H(liminated most restrictions on the length of te).15 E (xtual \214elds.)-.15 E (Clients should not assume that \214lenames, link names, user names, or) 0 48 Q(group names are limited in length.)0 60 Q(In particular)0 72 Q 2.5(,p)-.4 G(ax interchange format can easily accommodate pathnames)-2.5 E 0 Cg EP %%Page: 44 44 %%BeginPageSetup BP %%EndPageSetup /F0 10/Times-Roman@0 SF(in arbitrary character sets that e)0 12 Q(xceed) -.15 E(P)0 24 Q -1.11(AT)-.92 G(H_MAX.)1.11 E (

)-1.35 E(RETURN V)36 48 Q(ALUES)-1.35 E (

)36 60 Q(Most functions return zero on success, non-zero on error) 0 72 Q(.)-.55 E 0 Cg EP %%Page: 45 45 %%BeginPageSetup BP %%EndPageSetup /F0 10/Times-Roman@0 SF(The return v)0 12 Q (alue indicates the general se)-.25 E -.15(ve)-.25 G(rity of the error) .15 E 2.5(,r)-.4 G(anging)-2.5 E(from)0 24 Q(ARCHIVE_W)0 36 Q (ARN,)-1.2 E (which indicates a minor problem that should probably be reported)0 48 Q (to the user)0 60 Q 2.5(,t)-.4 G(o)-2.5 E(ARCHIVE_F)0 72 Q -1.21 -1.11(AT A)-.74 H(L,)1.11 E 0 Cg EP %%Page: 46 46 %%BeginPageSetup BP %%EndPageSetup /F0 10/Times-Roman@0 SF(which indicates a serious problem that will pre) 0 12 Q -.15(ve)-.25 G(nt an).15 E 2.5(yf)-.15 G(urther)-2.5 E (operations on this archi)0 24 Q -.15(ve)-.25 G(.).15 E(On error)0 36 Q 2.5(,t)-.4 G(he)-2.5 E(archi)0 48 Q -.15(ve)-.25 G (_errno\(\)).15 E(function can be used to retrie)0 60 Q .3 -.15(ve a n)-.25 H(umeric error code \(see).15 E (errno\(2\)\).)0 72 Q 0 Cg EP %%Page: 47 47 %%BeginPageSetup BP %%EndPageSetup /F0 10/Times-Roman@0 SF(The)0 12 Q(archi)0 24 Q -.15(ve)-.25 G (_error_string\(\)).15 E(returns a te)0 36 Q (xtual error message suitable for display)-.15 E(.)-.65 E(

)36 48 Q (archi)0 60 Q -.15(ve)-.25 G(_read_ne).15 E(w\(\)) -.25 E(and)0 72 Q 0 Cg EP %%Page: 48 48 %%BeginPageSetup BP %%EndPageSetup /F0 10/Times-Roman@0 SF(archi)0 12 Q -.15(ve)-.25 G(_write_ne).15 E (w\(\))-.25 E (return pointers to an allocated and initialized)0 24 Q(struct archi)0 36 Q -.15 (ve)-.25 G().15 E(object.)0 48 Q(

)36 60 Q(archi)0 72 Q -.15 (ve)-.25 G(_read_data\(\)).15 E 0 Cg EP %%Page: 49 49 %%BeginPageSetup BP %%EndPageSetup /F0 10/Times-Roman@0 SF(and)0 12 Q(archi)0 24 Q -.15(ve)-.25 G (_write_data\(\)).15 E (return a count of the number of bytes actually read or written.)0 36 Q 2.5(Av)0 48 S(alue of zero indicates the end of the data for this entry) -2.75 E(.)-.65 E 2.5(An)0 60 S -2.25 -.15(eg a)-2.5 H(ti).15 E .3 -.15 (ve v)-.25 H(alue indicates an error)-.1 E 2.5(,i)-.4 G 2.5(nw)-2.5 G (hich case the)-2.5 E(archi)0 72 Q -.15(ve)-.25 G (_errno\(\)).15 E 0 Cg EP %%Page: 50 50 %%BeginPageSetup BP %%EndPageSetup /F0 10/Times-Roman@0 SF(and)0 12 Q(archi)0 24 Q -.15(ve)-.25 G (_error_string\(\)).15 E (functions can be used to obtain more information.)0 36 Q(

)-.4 E(ENVIR)36 60 Q(ONMENT)-.4 E(

)36 72 Q 0 Cg EP %%Page: 51 51 %%BeginPageSetup BP %%EndPageSetup /F0 10/Times-Roman@0 SF(There are character set con)0 12 Q -.15(ve)-.4 G (rsions within the).15 E(archi)-.65 E -.15(ve)-.25 G(_entry\(3\)).15 E (functions that are impacted by the currently-selected locale.)0 36 Q (

)36 48 Q(SEE ALSO)36 60 Q(

)36 72 Q 0 Cg EP %%Page: 52 52 %%BeginPageSetup BP %%EndPageSetup /F0 10/Times-Roman@0 SF(tar\(1\),)-.55 E(archi)-.65 E -.15(ve)-.25 G(_entry\(3\),).15 E (archi).15 E -.15(ve)-.25 G(_read\(3\),).15 E(archi).15 E -.15(ve)-.25 G(_util\(3\),).15 E (archi).15 E -.15(ve)-.25 G(_write\(3\),).15 E(tar\(5\))-.55 E 0 Cg EP %%Page: 53 53 %%BeginPageSetup BP %%EndPageSetup /F0 10/Times-Roman@0 SF(

)-.65 E(HIST) 36 24 Q(OR)-.18 E(Y)-.65 E(

)36 36 Q(The)0 48 Q(libarchi)0 60 Q -.15(ve)-.25 G().15 E(library \214rst appeared in)0 72 Q 0 Cg EP %%Page: 54 54 %%BeginPageSetup BP %%EndPageSetup /F0 10/Times-Roman@0 SF(FreeBSD5.3.)0 12 Q(

) -.55 E -.55(AU)36 36 S(THORS).55 E(

)36 48 Q(

)36 60 Q(The)0 72 Q 0 Cg EP %%Page: 55 55 %%BeginPageSetup BP %%EndPageSetup /F0 10/Times-Roman@0 SF(libarchi)0 12 Q -.15(ve)-.25 G().15 E (library w)0 24 Q(as written by)-.1 E -.35(Ti)0 36 S 2.5(mK).35 G (ientzle <kientzle@acm.or)-2.5 E(g>.)-.18 E(

)-.1 E -.1(BU)36 60 S(GS).1 E(

)36 72 Q 0 Cg EP %%Page: 56 56 %%BeginPageSetup BP %%EndPageSetup /F0 10/Times-Roman@0 SF(Some archi)0 12 Q .3 -.15(ve f)-.25 H (ormats support information that is not supported by).15 E(struct archi)0 24 Q -.15(ve)-.25 G(_entry.).15 E (Such information cannot be fully archi)0 36 Q -.15(ve)-.25 G 2.5(do).15 G 2.5(rr)-2.5 G(estored using this library)-2.5 E(.)-.65 E (This includes, for e)0 48 Q(xample, comments, character sets,)-.15 E (or the arbitrary k)0 60 Q -.15(ey)-.1 G(/v).15 E (alue pairs that can appear in)-.25 E(pax interchange format archi)0 72 Q -.15(ve)-.25 G(s.).15 E 0 Cg EP %%Page: 57 57 %%BeginPageSetup BP %%EndPageSetup /F0 10/Times-Roman@0 SF(

)36 12 Q(Con)0 24 Q -.15(ve)-.4 G(rsely).15 E 2.5(,o)-.65 G 2.5(fc)-2.5 G (ourse, not all of the information that can be)-2.5 E(stored in an)0 36 Q(struct \ archi)0 48 Q -.15(ve)-.25 G(_entry).15 E (is supported by all formats.)0 60 Q -.15(Fo)0 72 S 2.5(re).15 G (xample, cpio formats do not support nanosecond timestamps;)-2.65 E 0 Cg EP %%Page: 58 58 %%BeginPageSetup BP %%EndPageSetup /F0 10/Times-Roman@0 SF(old tar formats do not support lar)0 12 Q(ge de) -.18 E(vice numbers.)-.25 E()0 24 Q()0 36 Q 0 Cg EP %%Trailer end %%EOF