[pacman-dev] [PATCH 2/3] doc: generalize description of the bash nature of PKGBUILD functions
Eli Schwartz
eschwartz at archlinux.org
Tue Mar 12 17:01:13 UTC 2019
Currently this is scoped to the build() function, which is simply wrong
as it equally applies to any function. Simply moving the paragraphs up
to the main manpage section makes this clear.
Signed-off-by: Eli Schwartz <eschwartz at archlinux.org>
---
doc/PKGBUILD.5.asciidoc | 17 +++++++++--------
1 file changed, 9 insertions(+), 8 deletions(-)
diff --git a/doc/PKGBUILD.5.asciidoc b/doc/PKGBUILD.5.asciidoc
index 285627ab..83a61458 100644
--- a/doc/PKGBUILD.5.asciidoc
+++ b/doc/PKGBUILD.5.asciidoc
@@ -332,6 +332,14 @@ PKGBUILD must contain a `package()` function which installs all the package's
files into the packaging directory, with optional `prepare()`, `build()`, and
`check()` functions being used to create those files from source.
+This is directly sourced and executed by makepkg, so anything that Bash or the
+system has available is available for use here. Be sure any exotic commands
+used are covered by the `makedepends` array.
+
+If you create any variables of your own in any of these functions, it is
+recommended to use the Bash `local` keyword to scope the variable to inside the
+function.
+
*package() Function*::
The `package()` function is used to install files into the directory that
will become the root directory of the built package and is run after all
@@ -351,14 +359,7 @@ files into the packaging directory, with optional `prepare()`, `build()`, and
*build() Function*::
The optional `build()` function is use to compile and/or adjust the source
- files in preparation to be installed by the `package()` function. This is
- directly sourced and executed by makepkg, so anything that Bash or the
- system has available is available for use here. Be sure any exotic
- commands used are covered by the `makedepends` array.
-+
-If you create any variables of your own in the `build()` function, it is
-recommended to use the Bash `local` keyword to scope the variable to inside
-the `build()` function.
+ files in preparation to be installed by the `package()` function.
*check() Function*::
An optional `check()` function can be specified in which a package's
--
2.21.0
More information about the pacman-dev
mailing list