diff options
author | Eli Schwartz <eschwartz@archlinux.org> | 2017-09-03 03:53:39 -0400 |
---|---|---|
committer | Luke Shumaker <lukeshu@parabola.nu> | 2018-01-03 14:55:21 -0500 |
commit | 73c1581fef3a5410b1edc9600e45edc15991784f (patch) | |
tree | 452ed6b1df529050bf67f791c5de0576edcef78b | |
parent | 6e81594d89c30b5d4ce9d74b094396ca26f2e1ae (diff) | |
download | devtools32-73c1581fef3a5410b1edc9600e45edc15991784f.tar.xz |
makechrootpkg: Fix unconditionally running namcap
Fixes regression in 2fd5931a8c67289a8a4acd327b3ce99a5d64c8c7
$run_namcap will always be set to ""
`if $not_a_var; then ...; fi` is always truthful when $not_a_var is
unset or equal to "" and the `then` clause will always be run.
I'm not sure why global state variables need to be cloned locally for
their sole explicit purpose.
But for now this patch implements the minimum necessary work to properly
pass the "do I want namcap" variable into prepare_chroot() according to
the current logic flow.
Note that I have still not thorougly tested makechrootpkg.
Signed-off-by: Eli Schwartz <eschwartz@archlinux.org>
Reviewed-by: Luke Shumaker <lukeshu@parabola.nu>
-rw-r--r-- | makechrootpkg.in | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/makechrootpkg.in b/makechrootpkg.in index ccdcebc..cacc52a 100644 --- a/makechrootpkg.in +++ b/makechrootpkg.in @@ -457,7 +457,7 @@ main() { download_sources "$copydir" "$makepkg_user" - prepare_chroot "$copydir" "$USER_HOME" "$keepbuilddir" + prepare_chroot "$copydir" "$USER_HOME" "$keepbuilddir" "$run_namcap" if arch-nspawn "$copydir" \ --bind="$PWD:/startdir" \ |