Hallo, dies ist ein Test.
PWD: /www/data-lst1/unixsoft/unixsoft/kaempfer/.public_html
Running in File Mode
Relative path: ./../../../../../../usr/./man/man1/ar.1
Real path: /usr/share/man/man1/ar.1
Zurück
'\" te .\" Copyright (c) 2009, 2021, Oracle and/or its affiliates. .\" Copyright (c) 1989, AT&T. All rights reserved. .\" Portions Copyright (c) 1992, The X/Open Company Ltd. All rights reserved. .\" Oracle gratefully acknowledges The Open Group for permission to reproduce portions of its copyrighted documentation. Original documentation from The Open Group can be obtained online at http://www.opengroup.org/bookstore/. .\" The Institute of Electrical and Electronics Engineers and The Open Group, have given us permission to reprint portions of their documentation. In the following statement, the phrase "this text" refers to portions of the system documentation. Portions of this text are reprinted and reproduced in electronic form in the Sun OS Reference Manual, from IEEE Std 1003.1, 2004 Edition, Standard for Information Technology -- Portable Operating System Interface (POSIX), The Open Group Base Specifications Issue 6, Copyright (C) 2001-2004 by the Institute of Electrical and Electronics Engineers, Inc and The Open Group. In the event of any discrepancy between these versions and the original IEEE and The Open Group Standard, the original IEEE and The Open Group Standard is the referee document. The original Standard can be obtained online at http://www.opengroup.org/unix/online.html. This notice shall appear on any product containing this material. .TH ar 1 "11 May 2021" "Oracle Solaris 11.4" "User Commands" .SH NAME ar \- maintain portable archive or library .SH SYNOPSIS .LP .nf \fB/usr/bin/ar\fR \fB-d\fR [\fB-SvV\fR] \fIarchive\fR [\fIfile\fR...] .fi .LP .nf \fB/usr/bin/ar\fR \fB-m\fR [\fB-SvV\fR] [\fB-{a|b|i}\fR \fIposname\fR] \fIarchive\fR [\fIfile\fR...] .fi .LP .nf \fB/usr/bin/ar\fR \fB-p\fR [\fB-sSvV\fR] \fIarchive\fR [\fIfile\fR...] .fi .LP .nf \fB/usr/bin/ar\fR \fB-q\fR [\fB-cSvV\fR] \fIarchive\fR [\fIfile\fR...] .fi .LP .nf \fB/usr/bin/ar\fR \fB-r\fR [\fB-cuSvV\fR] [\fB-{a|b|i}\fR \fIposname\fR] \fIarchive\fR [\fIfile\fR...] .fi .LP .nf \fB/usr/bin/ar\fR \fB-s|-S\fR [\fB-vV\fR] \fIarchive\fR .fi .LP .nf \fB/usr/bin/ar\fR \fB-t\fR [\fB-sSvV\fR] \fIarchive\fR [\fIfile\fR...] .fi .LP .nf \fB/usr/bin/ar\fR \fB-x\fR [\fB-CsSTvV\fR] \fIarchive\fR [\fIfile\fR...] .fi .LP .nf \fB/usr/xpg4/bin/ar\fR \fB-d\fR [\fB-SvV\fR] \fIarchive\fR [\fIfile\fR...] .fi .LP .nf \fB/usr/xpg4/bin/ar\fR \fB-m\fR [\fB-SvV\fR] [\fB-{a|b|i}\fR \fIposname\fR] \fIarchive\fR [\fIfile\fR...] .fi .LP .nf \fB/usr/xpg4/bin/ar\fR \fB-p\fR [\fB-sSvV\fR] \fIarchive\fR [\fIfile\fR...] .fi .LP .nf \fB/usr/xpg4/bin/ar\fR \fB-q\fR [\fB-cSvV\fR] \fIarchive\fR [\fIfile\fR...] .fi .LP .nf \fB/usr/xpg4/bin/ar\fR \fB-r\fR [\fB-cuSvV\fR] [\fB-{a|b|i}\fR \fIposname\fR] \fIarchive\fR [\fIfile\fR...] .fi .LP .nf \fB/usr/xpg4/bin/ar\fR \fB-s|-S\fR [\fB-vV\fR] \fIarchive\fR .fi .LP .nf \fB/usr/xpg4/bin/ar\fR \fB-t\fR [\fB-sSvV\fR] \fIarchive\fR [\fIfile\fR...] .fi .LP .nf \fB/usr/xpg4/bin/ar\fR \fB-x\fR [\fB-CsSTvV\fR] \fIarchive\fR [\fIfile\fR...] .fi .SH DESCRIPTION .sp .LP The \fBar\fR utility maintains groups of files combined into a single archive file. Its main use is to create and update library files. However, it can be used for any similar purpose. The magic string and the file headers used by \fBar\fR consist of printable \fBASCII\fR characters. If an archive is composed of printable files, the entire archive is printable. .sp .LP When \fBar\fR creates an archive, it creates headers in a format that is portable across all machines. The portable archive format and structure are described in detail in \fBar.h\fR(3HEAD). The archive symbol table described there is used by the link editor \fBld\fR(1) to effect multiple passes over libraries of object files in an efficient manner. An archive symbol table is only created and maintained by \fBar\fR when there is at least one object file in the archive. The archive symbol table is in a specially named file that is always the first file in the archive. This file is never mentioned or accessible to the user. Whenever the \fBar\fR command is used to create or update the contents of such an archive, the symbol table is rebuilt. The \fB-s\fR option described below forces the symbol table to be rebuilt. .SH OPTIONS .sp .LP The following options are supported: .sp .ne 2 .mk .na \fB\fB-a\fR \fIposname\fR\fR .ad .br .sp .6 .RS 4n Positions new \fIfile\fRs in \fIarchive\fR after the file named by \fIposname\fR. .RE .sp .ne 2 .mk .na \fB\fB-b\fR \fIposname\fR\fR .ad .br .sp .6 .RS 4n Positions new \fIfile\fRs in \fIarchive\fR before the file named by \fIposname\fR. .RE .sp .ne 2 .mk .na \fB\fB-c\fR\fR .ad .br .sp .6 .RS 4n Suppresses the diagnostic message that is written to standard error by default when \fIarchive\fR is created. .RE .sp .ne 2 .mk .na \fB\fB-C\fR\fR .ad .br .sp .6 .RS 4n Prevents extracted files from replacing like-named files in the file system. This option is useful when \fB-T\fR is also used to prevent truncated file names from replacing files with the same prefix. .RE .sp .ne 2 .mk .na \fB\fB-d\fR\fR .ad .br .sp .6 .RS 4n Deletes one or more \fIfile\fRs from \fIarchive\fR. .RE .sp .ne 2 .mk .na \fB\fB-i\fR \fIposname\fR\fR .ad .br .sp .6 .RS 4n Positions new \fIfile\fRs in \fIarchive\fR before the file named by \fIposname\fR. This option is equivalent to \fB-b\fR. .RE .sp .ne 2 .mk .na \fB\fB-m\fR\fR .ad .br .sp .6 .RS 4n Moves \fIfile\fRs. If \fB-a\fR, \fB-b\fR, or \fB-i\fR are specified, the \fB-m\fR option moves \fIfile\fRs to the new position. Otherwise, \fB-m\fR moves \fIfile\fRs to the end of \fIarchive\fR. .RE .sp .ne 2 .mk .na \fB\fB-p\fR\fR .ad .br .sp .6 .RS 4n Prints the contents of \fIfile\fRs in \fIarchive\fR to standard output. If no \fIfile\fRs are specified, the contents of all files in \fIarchive\fR are written in the order of the archive. .RE .sp .ne 2 .mk .na \fB\fB-q\fR\fR .ad .br .sp .6 .RS 4n Quickly appends \fIfile\fRs to the end of \fIarchive\fR. Positioning options \fB-a\fR, \fB-b\fR, and \fB-i\fR are invalid. The command does not check whether the added \fIfile\fRs are already in \fIarchive\fR. This option is useful to avoid quadratic behavior when creating a large archive piece-by-piece. .RE .sp .ne 2 .mk .na \fB\fB-r\fR\fR .ad .br .sp .6 .RS 4n Replaces or adds \fIfile\fRs in \fIarchive\fR. If \fIarchive\fR does not exist, a new archive file is created and a diagnostic message is written to standard error, unless the \fB-c\fR option is specified. Files that replace existing files do not change the order of the archive. If the \fB-u\fR option is used with the \fB-r\fR option, only those files with dates of modification later than the archive files are replaced. The \fB-a\fR, \fB-b\fR, or \fB-i\fR options can be used to specify the position at which the new files are to be placed. Otherwise, the new files are placed at the end. .RE .sp .ne 2 .mk .na \fB\fB-s\fR\fR .ad .br .sp .6 .RS 4n Forces the regeneration of the archive symbol table even if \fBar\fR is not invoked with an option that will modify the archive contents. This command is useful to restore the archive symbol table after the \fBstrip\fR(1) command has been used on the archive. .RE .sp .ne 2 .mk .na \fB\fB-S\fR\fR .ad .br .sp .6 .RS 4n When building the archive symbol table, force the use of the 64-bit capable symbol table format. By default, the 32-bit format is used for all archives smaller than 4GB, and the larger format is used for larger archives that exceed the 32-bit limit. .RE .sp .ne 2 .mk .na \fB\fB-t\fR\fR .ad .br .sp .6 .RS 4n Prints a table of contents of \fIarchive\fR. The files specified by the \fIfile\fR operands are included in the written list. If no \fIfile\fR operands are specified, all files in \fIarchive\fR are included in the order of the archive. .RE .sp .ne 2 .mk .na \fB\fB-T\fR\fR .ad .br .sp .6 .RS 4n Allows file name truncation of extracted files whose archive names are longer than the file system can support. By default, extracting a file with a name that is too long is an error. In that case, a diagnostic message is written and the file is not extracted. .RE .sp .ne 2 .mk .na \fB\fB-u\fR\fR .ad .br .sp .6 .RS 4n Updates older files. When used with the \fB-r\fR option, files within \fIarchive\fR are replaced only if the corresponding \fIfile\fR has a modification time that is at least as new as the modification time of the file within \fIarchive\fR. .RE .sp .ne 2 .mk .na \fB\fB-v\fR\fR .ad .br .sp .6 .RS 4n Gives verbose output. When used with options \fB-d\fR, \fB-r\fR, or \fB-x\fR, the \fB-v\fR option writes a detailed file-by-file description of the archive creation and the constituent \fIfile\fRs, and maintenance activity. When used with \fB-p\fR, \fB-v\fR writes the name of the file to the standard output before writing the file itself to the standard output. When used with \fB-t\fR, \fB-v\fR includes a long listing of information about the files within the archive. When used with \fB-x\fR, \fB-v\fR prints the filename preceding each extraction. When writing to an archive, \fB-v\fR writes a message to the standard error. .RE .sp .ne 2 .mk .na \fB\fB-V\fR\fR .ad .br .na \fB\fB--version\fR\fR .ad .br .sp .6 .RS 4n Print version information. .RE .sp .ne 2 .mk .na \fB\fB-x\fR\fR .ad .br .sp .6 .RS 4n Extracts the files named by the \fIfile\fR operands from \fIarchive\fR. The contents of \fIarchive\fR are not changed. If no \fIfile\fR operands are given, all files in \fIarchive\fR are extracted. If the file name of a file extracted from \fIarchive\fR is longer than that supported in the directory to which it is being extracted, the results are undefined. The modification time of each \fIfile\fR extracted is set to the time \fIfile\fR is extracted from \fIarchive\fR. .RE .sp .ne 2 .mk .na \fB\fB-?\fR\fR .ad .br .na \fB\fB--help\fR\fR .ad .br .sp .6 .RS 4n Print usage message and immediately exit. .RE .SS "\fB/usr/xpg4/bin/ar\fR" .sp .LP The following options are supported for \fB/usr/xpg4/bin/ar\fR: .sp .ne 2 .mk .na \fB\fB-v\fR\fR .ad .RS 6n .rt Same as the \fB/usr/bin/ar\fR version, except when writing to an archive, no message is written to the standard error. .RE .SH OPERANDS .sp .LP The following operands are supported: .sp .ne 2 .mk .na \fB\fIarchive\fR\fR .ad .RS 11n .rt A path name of the archive file. .RE .sp .ne 2 .mk .na \fB\fIfile\fR\fR .ad .RS 11n .rt A path name. Only the last component is used when comparing against the names of files in the archive. If two or more \fIfile\fR operands have the same last path name component (see \fBbasename\fR(1)), the results are unspecified. The implementation's archive format will not truncate valid file names of files added to or replaced in the archive. .RE .SH ENVIRONMENT VARIABLES .sp .LP See \fBenviron\fR(7) for descriptions of the following environment variables that affect the execution of \fBar\fR: \fBLANG\fR, \fBLC_ALL\fR, \fBLC_CTYPE\fR, \fBLC_MESSAGES\fR, \fBLC_TIME\fR, and \fBNLSPATH\fR. .sp .ne 2 .mk .na \fB\fBTMPDIR\fR\fR .ad .RS 10n .rt Determine the pathname that overrides the default directory for temporary files, if any. .RE .sp .ne 2 .mk .na \fB\fBTZ\fR\fR .ad .RS 10n .rt Determine the time zone used to calculate date and time strings written by \fBar\fR \fB-tv\fR. If \fBTZ\fR is unset or null, an unspecified default time zone is used. .RE .SH EXIT STATUS .sp .LP The following exit values are returned: .sp .ne 2 .mk .na \fB\fB0\fR\fR .ad .RS 6n .rt Successful completion. .RE .sp .ne 2 .mk .na \fB\fB>0\fR\fR .ad .RS 6n .rt An error occurred. .RE .SH ATTRIBUTES .sp .LP See \fBattributes\fR(7) for descriptions of the following attributes: .SS "\fB/usr/bin/ar\fR" .sp .TS tab( ) box; cw(2.75i) |cw(2.75i) lw(2.75i) |lw(2.75i) . ATTRIBUTE TYPE ATTRIBUTE VALUE _ Availability system/linker _ Interface Stability Committed .TE .sp .SS "\fB/usr/xpg4/bin/ar\fR" .sp .TS tab( ) box; cw(2.75i) |cw(2.75i) lw(2.75i) |lw(2.75i) . ATTRIBUTE TYPE ATTRIBUTE VALUE _ Availability system/xopen/xcu4 _ Interface Stability Committed _ Standard See \fBstandards\fR(7). .TE .sp .SH SEE ALSO .sp .LP \fBbasename\fR(1), \fBcpio\fR(1), \fBelffile\fR(1), \fBfile\fR(1), \fBld\fR(1), \fBlorder\fR(1), \fBstrip\fR(1), \fBtar\fR(1), \fBar.h\fR(3HEAD), \fBa.out\fR(5), \fBattributes\fR(7), \fBenviron\fR(7), \fBstandards\fR(7) .SH NOTES .sp .LP If the same file is mentioned twice in an argument list, it may be put in the archive twice. .sp .LP By convention, archives are suffixed with "\fB.a\fR". .sp .LP To support historical convention, the '-' for the first command line option can be omitted. .sp .LP When inserting \fBELF\fR objects into an archive file, \fBar\fR might add \en characters to pad these objects to an 8-byte boundary. Such padding improves the efficiency with which \fBld\fR(1) can access the archive. Only \fBELF\fR object files are padded in this way. Other archive members are not altered. When an object with such padding is extracted from an archive, the padding is not included in the resulting output. .sp .LP It is faster to create a new archive from scratch than to insert individual files into an existing archive via separate calls to \fBar\fR. When possible, the recommended strategy is to remove the existing archive, and re-create it with a single \fBar\fR invocation. .sp .LP The overall size of an archive is allowed to exceed 4GB. However, the size of any individual file within an archive is limited to 4GB by the archive file format. See \fBar.h\fR(3HEAD). .sp .LP The maximum user ID and group ID for an individual file within an archive are limited to 6 decimal digits by the archive file format. Any file with a user or group ID greater than 999999 is quietly set to user ID "nobody" (60001) or group ID "nobody" (6001). See \fBar.h\fR(3HEAD).