1 .\" Copyright Andries Brouwer, A. Wik 1998, Ragnar Hojland Espinosa 1998-2002
3 .\" This file may be copied under the conditions described
4 .\" in the LDP GENERAL PUBLIC LICENSE, Version 1, September 1998
5 .\" that should have been distributed together with this file.
7 .TH INSTALL 1 "18 June 2002" "GNU fileutils 4.1"
9 install \- copy files and set attributes
19 .I source... directory
23 .B [\-d,\-\-directory]
26 Options (shortest form):
33 .B [\-V {numbered,existing,simple}]
34 .B [\-\-preserve\-timestamps]
35 .BI [\-\-target\-directory= dir ]
36 .B [\-\-help] [\-\-version] [\-\-]
39 copies files while setting their permission modes and, if
40 possible, their owner and group.
42 In the first of these invocation forms, the
46 target file. In the second, each of the
48 files are copied to the destination
52 (and any missing parent directories) is created.
57 but allows you to control the attributes of destination files.
58 It is typically used in Makefiles to copy programs into their
59 destination directories. It refuses to copy files onto themselves.
64 Ignored; for compatibility with old Unix versions of
67 .B "\-d, \-\-directory"
68 Create each given directory and any missing parent directories,
69 setting the owner, group and mode as given on the command line or
70 to the defaults. It also gives any parent directories it creates
73 .BI "\-g " "group" ", \-\-group=" "group"
74 Set the group ownership of installed files or directories to
76 The default is the process's current group.
78 may be either a group name or a numeric group id.
80 .BI "\-m " "mode" ", \-\-mode=" "mode"
81 Set the permissions for the installed file or directory to
83 which can be either an octal number, or a symbolic mode as in
85 with 0 as the point of departure. The default mode is 0755 - read,
86 write, and execute for the owner, and read and execute for group and other.
88 .BI "\-o " "owner" ", \-\-owner=" "owner"
91 has appropriate privileges (is run as root), set the ownership of
92 installed files or directories to
94 The default is `root'.
96 may be either a user name or a numeric user ID.
98 .B \-p, \-\-preserve\-timestamps
99 Set the time of last access and the time of last modification of
100 each installed file to match those of each corresponding original
103 When a file is installed without this option, its last
104 access and last modification times are both set to the time of installation.
105 This option is useful if you want to use the last modification times of
106 installed files to keep track of when they were last built as opposed to
107 when they were last installed.
110 Strip the symbol tables from installed binary executables.
112 .BI "\-\-target\-directory=" dir
113 Specify the the target directory with an option instead of as the last arg
114 in the command line. This is useful with \fBxargs(1)\fR.
117 Create all leading components of \fIdest\fR except the last,
118 then copy \fIsource\fR to \fIdest\fR; useful in the 1st format.
121 Print the name of each file before installing it.
122 .SH "GNU BACKUP OPTIONS"
123 The GNU versions of programs like
130 will make a backup of files about to be overwritten, changed or destroyed
131 if that is desired. That backup files are desired is indicated by
132 the \-b option. How they should be named is specified by the \-\-backup option.
133 In case the name of the backup file is given by the name of the file
134 extended by a suffix, this suffix is specified by the \-S option.
136 .BI "\-b, \-\-backup[=" method ]
137 Make backups of files that are about to be overwritten or removed. Note
138 that \fB\-b\fR does not take args.
140 .BI "\-S " suffix ", \-\-suffix=" suffix
143 to each backup file made.
144 If this option is not specified, the value of the
145 .B SIMPLE_BACKUP_SUFFIX
146 environment variable is used. And if
147 .B SIMPLE_BACKUP_SUFFIX
148 is not set, the default is `~'.
150 .BI "\-V " method ", \-\-version\-control=" method
152 Specify how backup files are named. The
154 argument can be `numbered' (or `t'), `existing' (or `nil'), or `never' (or
156 If this option is not specified, the value of the
158 environment variable is used. And if
160 is not set, the default backup type is `existing'.
162 This option corresponds to the Emacs variable `version-control'.
165 are (unique abbreviations are accepted):
168 Always make numbered backups.
170 .BR nil ", " existing
171 Make numbered backups of files that already have them, simple
172 backups of the others.
174 .BR never ", " simple
175 Always make simple backups.
177 This option is deprecated, use \fB\-\-backup=\fImethod\fR instead.
178 .SH "GNU STANDARD OPTIONS"
181 Print a usage message on standard output and exit successfully.
184 Print version information on standard output, then exit successfully.
187 Terminate option list.
189 The variables LANG, LC_ALL, LC_CTYPE and LC_MESSAGES have the
190 usual meaning. For the GNU version, the variables SIMPLE_BACKUP_SUFFIX
191 and VERSION_CONTROL control backup file naming, as described above.
193 BSD 4.2 (which had the \-c, \-m, \-o, \-g and \-s options).
197 as found in the fileutils-4.1 package;
198 other versions may differ slightly. Mail corrections and additions to
199 aeb@cwi.nl and aw@mail1.bet1.puv.fi and ragnar@ragnar-hojland.com
200 Report bugs in the program to bug-fileutils@gnu.org.