2007-07-06 16:54:18 -04:00
|
|
|
/////
|
2011-06-22 12:06:34 -04:00
|
|
|
vim:set ts=4 sw=4 syntax=asciidoc noet spell spelllang=en_us:
|
2007-07-06 16:54:18 -04:00
|
|
|
/////
|
2007-07-02 19:22:01 -04:00
|
|
|
makepkg(8)
|
|
|
|
==========
|
|
|
|
|
|
|
|
Name
|
|
|
|
----
|
|
|
|
makepkg - package build utility
|
|
|
|
|
|
|
|
|
|
|
|
Synopsis
|
|
|
|
--------
|
2011-03-27 22:27:15 -04:00
|
|
|
'makepkg' [options]
|
2007-07-02 19:22:01 -04:00
|
|
|
|
|
|
|
|
|
|
|
Description
|
|
|
|
-----------
|
2011-03-27 22:27:15 -04:00
|
|
|
'makepkg' is a script to automate the building of packages. The requirements for
|
2013-04-28 22:00:17 -04:00
|
|
|
using the script are a build-capable *nix platform and a custom build script
|
2007-11-09 00:38:32 -05:00
|
|
|
for each package you wish to build (known as a PKGBUILD). See
|
2007-12-29 01:24:15 -05:00
|
|
|
linkman:PKGBUILD[5] for details on creating your own build scripts.
|
2007-07-02 19:22:01 -04:00
|
|
|
|
|
|
|
The advantage to a script-based build is that the work is only done once. Once
|
2011-03-27 22:27:15 -04:00
|
|
|
you have the build script for a package, 'makepkg' will do the rest: download and
|
2007-07-02 19:22:01 -04:00
|
|
|
validate source files, check dependencies, configure the build-time settings,
|
|
|
|
build the package, install the package into a temporary root, make
|
2007-07-16 12:57:02 -04:00
|
|
|
customizations, generate meta-info, and package the whole thing up for pacman
|
|
|
|
to use.
|
2007-07-02 19:22:01 -04:00
|
|
|
|
2011-03-27 22:27:15 -04:00
|
|
|
NOTE: 'makepkg' uses your current locale by default and does not unset it when
|
2008-02-05 19:23:18 -05:00
|
|
|
building packages. If you wish to share your build output with others when
|
|
|
|
seeking help or for other purposes, you may wish to run "`LC_ALL=C makepkg`" so
|
|
|
|
your logs and output are not localized.
|
|
|
|
|
2007-07-02 19:22:01 -04:00
|
|
|
Options
|
|
|
|
-------
|
2008-01-13 18:41:35 -05:00
|
|
|
*\--asroot*::
|
|
|
|
Allow makepkg to run as root. This is for security purposes as it is
|
|
|
|
normally dangerous to do so. This will also disable use of fakeroot and
|
|
|
|
sudo.
|
|
|
|
|
2007-07-16 12:57:02 -04:00
|
|
|
*-A, \--ignorearch*::
|
|
|
|
Ignore a missing or incomplete arch field in the build script. This is
|
|
|
|
for rebuilding packages from source when the PKGBUILD may be slightly
|
2009-04-11 12:14:28 -04:00
|
|
|
outdated and not updated with an `arch=('yourarch')` field.
|
2007-07-16 12:57:02 -04:00
|
|
|
|
|
|
|
*-c, \--clean*::
|
2007-07-02 19:22:01 -04:00
|
|
|
Clean up leftover work files and directories after a successful build.
|
|
|
|
|
2011-03-23 02:43:58 -04:00
|
|
|
*\--config* <file>::
|
2011-06-01 13:11:31 -04:00
|
|
|
Use an alternate config file instead of the +{sysconfdir}/makepkg.conf+
|
2011-03-23 02:28:58 -04:00
|
|
|
default.
|
2008-08-07 11:08:33 -04:00
|
|
|
|
2007-07-16 12:57:02 -04:00
|
|
|
*-d, \--nodeps*::
|
2007-07-02 19:22:01 -04:00
|
|
|
Do not perform any dependency checks. This will let you override and
|
|
|
|
ignore any dependencies required. There is a good chance this option
|
|
|
|
will break the build process if all of the dependencies are not
|
|
|
|
installed.
|
|
|
|
|
2007-07-16 12:57:02 -04:00
|
|
|
*-e, \--noextract*::
|
2012-07-28 05:20:11 -04:00
|
|
|
Do not extract source files or run the prepare() function (if present);
|
|
|
|
use whatever source already exists in the $srcdir/ directory. This is
|
|
|
|
handy if you want to go into $srcdir/ and manually patch or tweak code,
|
|
|
|
then make a package out of the result. Keep in mind that creating a
|
|
|
|
patch may be a better solution to allow others to use your PKGBUILD.
|
2007-07-02 19:22:01 -04:00
|
|
|
|
2013-02-23 07:08:44 -05:00
|
|
|
*\--verifysource*::
|
|
|
|
For each source file in the source array of PKGBUILD, download the file
|
|
|
|
if required and perform the integrity checks. No extraction or build is
|
|
|
|
performed. Useful for performing subsequent offline builds.
|
|
|
|
|
2007-07-16 12:57:02 -04:00
|
|
|
*-f, \--force*::
|
2007-07-02 19:22:01 -04:00
|
|
|
makepkg will not build a package if a built package already exists in
|
2008-01-02 21:43:15 -05:00
|
|
|
the `PKGDEST` (set in linkman:makepkg.conf[5]) directory, which may
|
2007-07-02 19:22:01 -04:00
|
|
|
default to the current directory. This allows the built package to be
|
|
|
|
overwritten.
|
|
|
|
|
2007-07-16 12:57:02 -04:00
|
|
|
*-g, \--geninteg*::
|
2007-07-02 19:22:01 -04:00
|
|
|
For each source file in the source array of PKGBUILD, download the file
|
2009-10-14 14:07:28 -04:00
|
|
|
if required and generate integrity checks. The integrity checks generated
|
|
|
|
are determined by the checks present in the PKGBUILD, falling back to the
|
|
|
|
value of the INTEGRITY_CHECK array in makepkg.conf(5) if these are absent
|
|
|
|
This output can be redirected into your PKGBUILD for source validation
|
|
|
|
using "`makepkg -g >> PKGBUILD`".
|
2007-07-02 19:22:01 -04:00
|
|
|
|
2009-08-10 09:50:53 -04:00
|
|
|
*--skipinteg*::
|
2011-07-16 08:42:32 -04:00
|
|
|
Do not perform any integrity checks (checksum and PGP) on source files.
|
|
|
|
|
|
|
|
*\--skipchecksums*::
|
|
|
|
Do not verify checksums of source files.
|
2009-08-10 09:50:53 -04:00
|
|
|
|
2011-07-06 07:02:19 -04:00
|
|
|
*\--skippgpcheck*::
|
2011-07-16 08:42:32 -04:00
|
|
|
Do not verify PGP signatures of source files.
|
2011-07-06 07:02:19 -04:00
|
|
|
|
2007-07-16 12:57:02 -04:00
|
|
|
*-h, \--help*::
|
2007-07-02 19:22:01 -04:00
|
|
|
Output syntax and command line options.
|
|
|
|
|
2012-07-23 03:00:35 -04:00
|
|
|
*--holdver*::
|
|
|
|
When using VCS sources (linkman:PKGBUILD[5]) any currently checked out source
|
|
|
|
will not be updated to the latest revision.
|
|
|
|
|
2007-07-16 12:57:02 -04:00
|
|
|
*-i, \--install*::
|
|
|
|
Install or upgrade the package after a successful build using
|
2007-12-29 01:24:15 -05:00
|
|
|
linkman:pacman[8].
|
2007-07-02 19:22:01 -04:00
|
|
|
|
2008-02-05 19:23:18 -05:00
|
|
|
*-L, \--log*::
|
|
|
|
Enable makepkg build logging. This will use the *tee* program to send
|
|
|
|
output of the `build()` function to both the console and to a text file in
|
|
|
|
the build directory named `pkgname-pkgver-pkgrel-arch.log`. As mentioned
|
|
|
|
above, the build log will be localized so you may want to set your locale
|
|
|
|
accordingly if sharing the log output with others.
|
|
|
|
|
2007-07-16 12:57:02 -04:00
|
|
|
*-m, \--nocolor*::
|
2007-07-02 19:22:01 -04:00
|
|
|
Disable color in output messages.
|
|
|
|
|
2007-07-16 12:57:02 -04:00
|
|
|
*-o, \--nobuild*::
|
2012-07-28 05:20:11 -04:00
|
|
|
Download and extract files, run the prepare() function, but do not build
|
|
|
|
them. Useful with the '\--noextract' option if you wish to tweak the files
|
|
|
|
in $srcdir/ before building.
|
2007-07-02 19:22:01 -04:00
|
|
|
|
2011-03-23 02:43:58 -04:00
|
|
|
*-p* <buildscript>::
|
2007-10-29 23:25:30 -04:00
|
|
|
Read the package script `buildscript` instead of the `PKGBUILD` default;
|
2007-12-29 01:24:15 -05:00
|
|
|
see linkman:PKGBUILD[5].
|
2007-07-02 19:22:01 -04:00
|
|
|
|
2007-07-16 12:57:02 -04:00
|
|
|
*-r, \--rmdeps*::
|
2007-07-02 19:22:01 -04:00
|
|
|
Upon successful build, remove any dependencies installed by makepkg
|
2008-12-10 20:23:34 -05:00
|
|
|
during dependency auto-resolution and installation when using `-s`.
|
2007-07-02 19:22:01 -04:00
|
|
|
|
2007-07-16 12:57:02 -04:00
|
|
|
*-R, \--repackage*::
|
2009-05-10 11:16:51 -04:00
|
|
|
Repackage contents of the package without rebuilding the package. This
|
|
|
|
is useful if you forgot a depend or install file in your PKGBUILD and
|
|
|
|
the build itself will not change.
|
2007-07-02 19:22:01 -04:00
|
|
|
|
2007-07-16 12:57:02 -04:00
|
|
|
*-s, \--syncdeps*::
|
2007-10-29 23:25:30 -04:00
|
|
|
Install missing dependencies using pacman. When build-time or run-time
|
|
|
|
dependencies are not found, pacman will try to resolve them. If
|
2007-07-02 19:22:01 -04:00
|
|
|
successful, the missing packages will be downloaded and installed.
|
|
|
|
|
2011-08-18 06:46:19 -04:00
|
|
|
*-S, \--source*::
|
|
|
|
Do not actually build the package, but build a source-only tarball that
|
|
|
|
does not include sources that can be fetched via a download URL. This is
|
|
|
|
useful for passing a single tarball to another program such as a chroot,
|
|
|
|
remote builder, or a tarball upload. Because integrity checks are verified,
|
|
|
|
all source files of the package need to be present or downloadable.
|
|
|
|
|
2013-04-28 21:49:01 -04:00
|
|
|
*-V, \--version*::
|
|
|
|
Display version information.
|
|
|
|
|
2008-07-30 22:53:02 -04:00
|
|
|
*\--allsource*::
|
|
|
|
Do not actually build the package, but build a source-only tarball that
|
|
|
|
includes all sources, including those that are normally download via
|
|
|
|
makepkg. This is useful for passing a single tarball to another program
|
|
|
|
such as a chroot or remote builder. It will also satisfy requirements of
|
|
|
|
the GPL when distributing binary packages.
|
|
|
|
|
2012-04-22 00:03:07 -04:00
|
|
|
*\--pkg* <list>::
|
2012-04-08 13:13:07 -04:00
|
|
|
Only build listed packages from a split package. Multiple packages should
|
2012-04-08 13:26:41 -04:00
|
|
|
be comma separated in the list. This option can be specified multiple times.
|
2009-10-22 00:40:03 -04:00
|
|
|
|
2010-12-15 09:06:43 -05:00
|
|
|
*\--check*::
|
|
|
|
Run the check() function in the PKGBUILD, overriding the setting in
|
|
|
|
linkman:makepkg.conf[5].
|
|
|
|
|
|
|
|
*\--nocheck*::
|
|
|
|
Do not run the check() function in the PKGBUILD or handle the checkdepends.
|
|
|
|
|
2013-04-28 22:42:22 -04:00
|
|
|
*\--noprepare*::
|
|
|
|
Do not run the prepare() function in the PKGBUILD.
|
|
|
|
|
2011-04-17 08:17:24 -04:00
|
|
|
*\--sign*::
|
|
|
|
Sign the resulting package with gpg, overriding the setting in
|
|
|
|
linkman:makepkg.conf[5].
|
|
|
|
|
|
|
|
*\--nosign*::
|
|
|
|
Do not create a signature for the built package.
|
|
|
|
|
|
|
|
*\--key* <key>::
|
2011-04-17 08:38:35 -04:00
|
|
|
Specify a key to use when signing packages, overriding the GPGKEY setting
|
|
|
|
in linkman:makepkg.conf[5]. If not specified in either location, the
|
|
|
|
default key from the keyring will be used.
|
2011-04-17 08:17:24 -04:00
|
|
|
|
2007-07-16 12:57:02 -04:00
|
|
|
*\--noconfirm*::
|
2007-07-02 19:22:01 -04:00
|
|
|
(Passed to pacman) Prevent pacman from waiting for user input before
|
|
|
|
proceeding with operations.
|
|
|
|
|
2012-11-19 19:51:06 -05:00
|
|
|
*\--needed*::
|
|
|
|
(Passed to pacman) Tell pacman not to reinstall a target if it is already
|
|
|
|
up to date. (used with -i / --install).
|
|
|
|
|
2012-07-09 01:55:58 -04:00
|
|
|
*\--asdeps*::
|
|
|
|
(Passed to pacman) Install packages as non-explicitly installed (used
|
|
|
|
with -i / --install).
|
|
|
|
|
2007-07-16 12:57:02 -04:00
|
|
|
*\--noprogressbar*::
|
2007-07-02 19:22:01 -04:00
|
|
|
(Passed to pacman) Prevent pacman from displaying a progress bar;
|
|
|
|
useful if you are redirecting makepkg output to file.
|
|
|
|
|
|
|
|
|
2007-10-29 23:25:30 -04:00
|
|
|
Additional Features
|
|
|
|
-------------------
|
|
|
|
makepkg supports building development versions of packages without having to
|
|
|
|
manually update the pkgver in the PKGBUILD. This was formerly done using the
|
2007-12-29 01:24:15 -05:00
|
|
|
separate utility 'versionpkg'. See linkman:PKGBUILD[5] for details on how to
|
2007-10-29 23:25:30 -04:00
|
|
|
set up a development PKGBUILD.
|
|
|
|
|
|
|
|
|
2009-12-02 13:04:32 -05:00
|
|
|
Environment Variables
|
|
|
|
---------------------
|
|
|
|
*PACMAN*::
|
|
|
|
The command that will be used to check for missing dependencies and to
|
2009-10-23 01:30:47 -04:00
|
|
|
install and remove packages. Pacman's -Qq, -Rns, -S, -T, and -U
|
|
|
|
operations must be supported by this command. If the variable is not
|
|
|
|
set or empty, makepkg will fall back to `pacman'.
|
2009-12-02 13:04:32 -05:00
|
|
|
|
2009-12-04 11:49:54 -05:00
|
|
|
**PKGDEST=**"/path/to/folder"::
|
|
|
|
Folder where the resulting packages will be stored. Overrides the
|
|
|
|
corresponding value defined in linkman:makepkg.conf[5].
|
|
|
|
|
|
|
|
**SRCDEST=**"/path/to/folder"::
|
|
|
|
Folder where the downloaded sources will be stored. Overrides the
|
|
|
|
corresponding value defined in linkman:makepkg.conf[5].
|
|
|
|
|
2011-10-31 21:00:47 -04:00
|
|
|
**PACKAGER=**"John Doe <john@doe.com>"::
|
|
|
|
String to identify the creator of the resulting package. Overrides
|
|
|
|
the corresponding value defined in linkman:makepkg.conf[5].
|
|
|
|
|
2011-06-15 00:32:42 -04:00
|
|
|
**BUILDDIR=**"/path/to/folder"::
|
|
|
|
Folder where the package will be built. Overrides the corresponding
|
|
|
|
value defined in linkman:makepkg.conf[5].
|
2009-12-02 13:04:32 -05:00
|
|
|
|
2013-04-29 19:10:08 -04:00
|
|
|
**CARCH=**"(i686|x86_64)"::
|
|
|
|
Force build for a specific architecture. Useful for cross-compiling.
|
|
|
|
Overrides the corresponding value defined in linkman:makepkg.conf[5].
|
|
|
|
|
2007-07-02 19:22:01 -04:00
|
|
|
Configuration
|
|
|
|
-------------
|
2007-12-29 01:24:15 -05:00
|
|
|
See linkman:makepkg.conf[5] for more details on configuring makepkg using the
|
2007-07-16 12:57:02 -04:00
|
|
|
'makepkg.conf' file.
|
2007-07-02 19:22:01 -04:00
|
|
|
|
|
|
|
|
|
|
|
See Also
|
|
|
|
--------
|
2007-12-29 01:24:15 -05:00
|
|
|
linkman:makepkg.conf[5], linkman:PKGBUILD[5], linkman:pacman[8]
|
2007-07-02 19:22:01 -04:00
|
|
|
|
|
|
|
include::footer.txt[]
|