logo

cross-unix-documentation

documentation of similarities and (noteworthy) differencies between Unix systems git clone https://hacktivis.me/git/cross-unix-documentation.git

install.1x (2389B)


  1. .\" This file is part of Cross Unix Documentation
  2. .\" Copyright © 2019-2020 Haelwenn (lanodan) Monnier <contact@hacktivis.me>
  3. .\" SPDX-License-Identifier: CC-BY-4.0
  4. .Dd 2019-11-16
  5. .Dt INSTALL 1x
  6. .Os
  7. .Sh PROLOG
  8. This manual page is part of
  9. .Lk https://hacktivis.me/git/cross-unix-documentation "Cross-Unix Documentation"
  10. which is an attempt to provide documentation of similarities and (noteworthy) differencies between Unix-like systems.
  11. To be used as an addition to the POSIX standard.
  12. .Sh NAME
  13. .Nm install
  14. .Nd install binairies
  15. .Sh SYNOPSIS
  16. .Ss BusyBox, GNU coreutils, OpenBSD
  17. .Nm
  18. .Op Fl bcDsp
  19. .Op Fl g Ar group
  20. .Op Fl m Ar mode
  21. .Op Fl o Ar owner
  22. .Op Ar source
  23. .Op Ar destination
  24. .Ss NetBSD, FreeBSD
  25. .Nm
  26. .Op Fl bcsp
  27. .Op Fl g Ar group
  28. .Op Fl m Ar mode
  29. .Op Fl o Ar owner
  30. .Op Fl D Ar destdir
  31. .Op Ar source
  32. .Op Ar destination
  33. .Sh DESCRIPTION
  34. .Nm
  35. copies
  36. .Ar source
  37. to
  38. .Ar destination ,
  39. if
  40. .Ar destination
  41. already exists it is removed or renamed if
  42. .Fl b
  43. is specified before source is copied.
  44. If destination is a directory then source is copied into destination with its original filename.
  45. The mode of
  46. .Ar destination
  47. is set to 755 unless
  48. .Fl m Ar mode
  49. is specified.
  50. .Bl -tag -width Ds
  51. .It Fl b
  52. backup any existing files before overwriting them by renaming them.
  53. (GNU appends '~' by default,
  54. BSDs
  55. appends .old by default)
  56. .It Fl c
  57. Copy the file.
  58. .Bx 4.2
  59. default behaviour is to move the binary unless
  60. .Fl c
  61. is specified.
  62. Copying the file is now the default behaviour; the flag is maintained for backwards compatibility only.
  63. .It Fl D
  64. BusyBox, GNU coreutils,
  65. .Ox :
  66. Create any missing directories for
  67. .Ar destination
  68. (which still points to a file).
  69. .It Fl D Ar destdir
  70. .Nx ,
  71. .Fx :
  72. Sets the DESTDIR (top of the file hierarchy) that the items are installed in to.
  73. .It Fl g Ar group
  74. Sets group ownership.
  75. GNU: instead of the process' current group
  76. .It Fl m Ar mode
  77. Sets alternative mode.
  78. The default mode is set to rwr-xr-x(0755).
  79. .It Fl o Ar owner
  80. Sets user ownership.
  81. .It Fl p
  82. Preserve file access and modification times.
  83. .It Fl s
  84. executes
  85. .Xr strip 1
  86. on each binary/file
  87. .El
  88. .Pp
  89. There are many extra flags in GNU/*BSD versions of
  90. .Xr install 1
  91. but this is kept to the common ones.
  92. .Sh SOURCE
  93. .Nx 8.1 ,
  94. .Fx 12.1 ,
  95. .Ox 6.6 ,
  96. GNU coreutils 8.30, Busybox 1.30.1,
  97. .Bx 4.2 .
  98. .Sh HISTORY
  99. The
  100. .Nm
  101. utility appeared in
  102. .Bx 4.2 .
  103. .Sh AUTHORS
  104. .An Haelwenn (lanodan) Monnier Aq Mt contact+c-u-d@hacktivis.me