summaryrefslogtreecommitdiffstats
path: root/man1/install.1
diff options
context:
space:
mode:
Diffstat (limited to 'man1/install.1')
-rw-r--r--man1/install.1186
1 files changed, 186 insertions, 0 deletions
diff --git a/man1/install.1 b/man1/install.1
new file mode 100644
index 000000000..7151b69dd
--- /dev/null
+++ b/man1/install.1
@@ -0,0 +1,186 @@
+.\" Copyright Andries Brouwer, Ragnar Hojland Espinosa and A. Wik, 1998.
+.\"
+.\" This file may be copied under the conditions described
+.\" in the LDP GENERAL PUBLIC LICENSE, Version 1, September 1998
+.\" that should have been distributed together with this file.
+.\"
+.TH INSTALL 1 1998-11 "GNU fileutils 4.0"
+.SH NAME
+install \- copy files and set attributes
+.SH SYNOPSIS
+.B install
+.BI [ options ]
+.B [\-s] [\-\-strip]
+.I source dest
+.br
+.B install
+.BI [ options ]
+.B [\-s] [\-\-strip]
+.I source... directory
+.br
+.B install
+.BI [ options ]
+.B [\-d,\-\-directory]
+.I directory...
+.sp
+Options (shortest form):
+.br
+.B [\-b]
+.B [\-c]
+.B [\-D]
+.BI "[\-g " group ]
+.BI "[\-m " mode ]
+.BI "[\-o " owner ]
+.BI "[\-S " SUFFIX ]
+.B [\-V {numbered,existing,simple}]
+.B [\-\-help] [\-\-version] [\-\-]
+.SH DESCRIPTION
+.B install
+copies files while setting their permission modes and, if
+possible, their owner and group.
+.PP
+In the first of these invocation forms, the
+.I source
+file is copied to the
+.I dest
+target file. In the second, each of the
+.I source
+files are copied to the destination
+.IR directory .
+In the last, each
+.I directory
+(and any missing parent directories) is created.
+.PP
+.B install
+is similar to
+.BR cp ,
+but allows you to control the attributes of destination files.
+It is typically used in Makefiles to copy programs into their
+destination directories. It refuses to copy files onto themselves.
+.PP
+.SH OPTIONS
+.TP
+.B "\-c"
+Ignored; for compatibility with old Unix versions of
+.BR install .
+.TP
+.B "\-d, \-\-directory"
+Create each given directory and any missing parent directories,
+setting the owner, group and mode as given on the command line or
+to the defaults. It also gives any parent directories it creates
+those attributes. (This is different from the SunOS 4.x
+.BR install ,
+which gives directories that it creates the default attributes.)
+.TP
+.B "\-D"
+Create all leading components of the
+.I dest
+except the last, then copy
+.I source
+to
+.IR dest .
+This option is useful in the first format in the synopsis, above.
+(New in file\%utils-4.0.)
+.TP
+.BI "\-g " "group" ", \-\-group=" "group"
+Set the group ownership of installed files or directories to
+.IR group .
+The default is the process's current group.
+.I group
+may be either a group name or a numeric group id.
+.TP
+.BI "\-m " "mode" ", \-\-mode=" "mode"
+Set the permissions for the installed file or directory to
+.IR mode ,
+which can be either an octal number, or a symbolic mode as in
+.BR chmod ,
+with 0 as the point of departure. The default mode is 0755 - read,
+write, and execute for the owner, and read and execute for group and other.
+.TP
+.BI "\-o " "owner" ", \-\-owner=" "owner"
+If
+.B install
+has appropriate privileges (is run as root), set the ownership of
+installed files or directories to
+.IR owner .
+The default is `root'.
+.I owner
+may be either a user name or a numeric user ID.
+.TP
+.B "\-s, \-\-strip"
+Strip the symbol tables from installed binary executables.
+.SH "GNU BACKUP OPTIONS"
+The GNU versions of programs like
+.BR cp ,
+.BR mv ,
+.BR ln ,
+.B install
+and
+.B patch
+will make a backup of files about to be overwritten, changed or destroyed
+if that is desired. That backup files are desired is indicated by
+the \-b option. How they should be named is specified by the \-V option.
+In case the name of the backup file is given by the name of the file
+extended by a suffix, this suffix is specified by the \-S option.
+.TP
+.B "\-b, \-\-backup"
+Make backups of files that are about to be overwritten or removed.
+.TP
+.BI "\-S " SUFFIX ", \-\-suffix=" SUFFIX
+Append
+.I SUFFIX
+to each backup file made.
+If this option is not specified, the value of the
+.B SIMPLE_BACKUP_SUFFIX
+environment variable is used. And if
+.B SIMPLE_BACKUP_SUFFIX
+is not set, the default is `~'.
+.TP
+.BI "\-V " METHOD ", \-\-version\-control=" METHOD
+.RS
+Specify how backup files are named. The
+.I METHOD
+argument can be `numbered' (or `t'), `existing' (or `nil'), or `never' (or
+`simple').
+If this option is not specified, the value of the
+.B VERSION_CONTROL
+environment variable is used. And if
+.B VERSION_CONTROL
+is not set, the default backup type is `existing'.
+.PP
+This option corresponds to the Emacs variable `version-control'.
+The valid
+.IR METHOD s
+are (unique abbreviations are accepted):
+.TP
+.BR t ", " numbered
+Always make numbered backups.
+.TP
+.BR nil ", " existing
+Make numbered backups of files that already have them, simple
+backups of the others.
+.TP
+.BR never ", " simple
+Always make simple backups.
+.RE
+.SH "GNU STANDARD OPTIONS"
+.TP
+.B "\-\-help"
+Print a usage message on standard output and exit successfully.
+.TP
+.B "\-\-version"
+Print version information on standard output, then exit successfully.
+.TP
+.B "\-\-"
+Terminate option list.
+.SH ENVIRONMENT
+The variables LANG, LC_ALL, LC_CTYPE and LC_MESSAGES have the
+usual meaning. For the GNU version, the variables SIMPLE_BACKUP_SUFFIX
+and VERSION_CONTROL control backup file naming, as described above.
+.SH "CONFORMING TO"
+BSD 4.2 (which had the \-c, \-m, \-o, \-g and \-s options).
+.SH NOTES
+This page describes
+.B install
+as found in the fileutils-4.0 package;
+other versions may differ slightly.