dpkg-buildpackage.1 5.6 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220
  1. .TH dpkg\-buildpackage 1 "2007-09-28" "Debian Project" "dpkg utilities"
  2. .SH NAME
  3. dpkg\-buildpackage \- build binary or source packages from sources
  4. .
  5. .SH SYNOPSIS
  6. .B dpkg\-buildpackage
  7. .RI [ options ]
  8. .
  9. .SH DESCRIPTION
  10. .B dpkg\-buildpackage
  11. is a control script which can be used to help automate the building of
  12. a package.
  13. .
  14. .SH OPTIONS
  15. .TP
  16. .B \-b
  17. Specifies a binary-only build, no source files are to be built and/or
  18. distributed.
  19. .TP
  20. .B \-B
  21. Specifies a binary-only build, no architecture independent binary package
  22. files are to be distributed either.
  23. .TP
  24. .B \-S
  25. Specifies a source-only build, no binary packages need to be made.
  26. .PP
  27. The \fB-s\fP\fIx\fP options control whether the original source archive is
  28. included in the upload if any source is being generated (i.e.
  29. .BR \-b " or " \-B
  30. haven't been used).
  31. .TP
  32. .B \-si
  33. By default, or if specified, the original source will be included if the
  34. version number ends in
  35. .BR \-0 " or " \-1 ,
  36. i.e. if the Debian revision part of the version number is
  37. .BR 0 " or " 1 .
  38. .TP
  39. .B \-sa
  40. Forces the inclusion of the original source.
  41. .TP
  42. .B \-sd
  43. Forces the exclusion of the original source and includes only the diff.
  44. .TP
  45. .BI \-a architecture
  46. Specify the Debian architecture we build for. The architecture of the
  47. machine we build on is determined automatically, and is also the default
  48. for the host machine.
  49. .TP
  50. .BI \-j jobs
  51. Number of jobs allowed to be run simultaneously, equivalent to the
  52. .BR make (1)
  53. option of the same name. Will add itself to the MAKEFLAGS
  54. environment variable, which should cause all subsequent make
  55. invocations to inherit the option. Also adds \fBparallel=\fP\fIjobs\fP
  56. to the DEB_BUILD_OPTIONS environment variable which allows
  57. debian/rules files to use this information for their own purposes.
  58. If no \fB-j\fP option is given, an existing value for \fBparallel\fP will be
  59. honoured and added to MAKEFLAGS.
  60. .TP
  61. .BI \-v version
  62. Use changelog information from all versions strictly later than
  63. .IR version .
  64. .TP
  65. .BI \-C changesdescription
  66. Read the description of the changes from the file
  67. .I changesdescription
  68. rather than using the information from the source tree's changelog file.
  69. .TP
  70. .BI \-m maintaineraddress
  71. Use
  72. .I maintaineraddress
  73. as the name and email address of the maintainer for this package,
  74. rather than using the information from the source tree's control file.
  75. .TP
  76. .BI \-e maintaineraddress
  77. Use
  78. .I maintaineraddress
  79. as the name and email address of the maintainer for this upload,
  80. rather than using the information from the source tree's changelog.
  81. .TP
  82. .B \-D
  83. Check build dependencies and conflicts; abort if unsatisfied.
  84. .TP
  85. .B \-d
  86. Do not check build dependencies and conflicts.
  87. .TP
  88. .B \-E
  89. Turn certain warnings into errors. Only \fBdpkg\-source\fP uses this, but
  90. .BR dpkg\-buildpackage
  91. recognizes it, and passes it thru to
  92. .BR dpkg\-source "."
  93. .TP
  94. .B \-W
  95. Negates a previously set
  96. .BR \-E "."
  97. Only \fBdpkg\-source\fP uses this, but
  98. .BR dpkg\-buildpackage
  99. recognizes it, and passes it thru to
  100. .BR dpkg\-source "."
  101. .TP
  102. .B \-nc
  103. Do not clean the source tree (implies \fB\-b\fP).
  104. .TP
  105. .B \-tc
  106. Clean the source tree (using
  107. .I gain-root-command
  108. .BR "debian/rules clean" )
  109. after the package has been built.
  110. .TP
  111. .BI \-r gain-root-command
  112. When
  113. .B dpkg\-buildpackage
  114. needs to execute part of the build process as root, it prefixes the
  115. command it executes with
  116. .I gain-root-command
  117. if one has been specified. Otherwise, if none has been specified,
  118. \fBfakeroot\fP will be used by default, if the command is present.
  119. .I gain-root-command
  120. should be the name of a program on the
  121. .B PATH
  122. and will get as arguments the name of the real command to run and the
  123. arguments it should take.
  124. .I gain-root-command
  125. should not contain spaces or any other shell metacharacters.
  126. .\" what happens, if it contains spaces? (hs)
  127. .I gain-root-command
  128. might typically be
  129. .BR fakeroot ", " sudo ", " super " or " really .
  130. .B su
  131. is not suitable, since it requires a
  132. .B \-c
  133. option to run a command and even then it can only invoke the user's
  134. shell with
  135. .B \-c
  136. instead of passing arguments individually to the command to be run.
  137. .TP
  138. .BI \-p sign-command
  139. When
  140. .B dpkg\-buildpackage
  141. needs to execute GPG or PGP to sign a source control
  142. .RB ( .dsc )
  143. file or a
  144. .B .changes
  145. file it will run
  146. .I sign-command
  147. (searching the
  148. .B PATH
  149. if necessary) instead of
  150. .BR pgp .
  151. .I sign-command
  152. will get all the arguments that
  153. .B pgp
  154. would have gotten. If
  155. .I sign-command
  156. takes its arguments in GPG rather than PGP style, you should give
  157. the
  158. .B \-sgpg
  159. option.
  160. .I sign-command
  161. should not contain spaces or any other shell metacharacters.
  162. .TP
  163. .BI \-k key-id
  164. Specify a key-ID to use when signing packages.
  165. .TP
  166. .BR \-us
  167. Do not sign the source package.
  168. .TP
  169. .BR \-uc
  170. Do not sign the .changes file.
  171. .TP
  172. .BR \-i [\fIregexp\fP]
  173. Passed unchanged to
  174. .BR dpkg\-source .
  175. .TP
  176. .BI \-I [\fIpattern\fP]
  177. Passed unchanged to
  178. .BR dpkg\-source .
  179. May be repeated multiple times.
  180. .TP
  181. .BR \-s [ nsAkurKUR ]
  182. Passed unchanged to
  183. .BR dpkg\-source .
  184. .TP
  185. .BR \-z ", " \-Z
  186. Passed unchanged to
  187. .BR dpkg\-source .
  188. .TP
  189. .BI \-\-admindir= dir
  190. Change the location of the \fBdpkg\fR database. The default location is
  191. \fI/var/lib/dpkg\fP.
  192. .TP
  193. .BR \-h ", " \-\-help
  194. Show the usage message and exit.
  195. .TP
  196. .BR \-\-version
  197. Show the version and exit.
  198. .
  199. .SH BUGS
  200. It should be possible to specify spaces and shell metacharacters in
  201. and initial arguments for
  202. .IR gain-root-command " and " sign-command .
  203. .
  204. .SH "SEE ALSO"
  205. .BR dpkg\-source (1),
  206. .BR dpkg\-architecture (1),
  207. .BR dpkg\-genchanges (1),
  208. .BR gpg (1),
  209. .BR pgp (1).
  210. .
  211. .SH AUTHORS
  212. Copyright (C) 1995-1996 Ian Jackson
  213. .br
  214. Copyright (C) 2000 Wichert Akkerman
  215. .br
  216. Copyright (C) 2007 Frank Lichtenheld
  217. .sp
  218. This is free software; see the GNU General Public Licence version 2 or later
  219. for copying conditions. There is NO WARRANTY.