[pacman-dev] [PATCH] doc: declare what type of comments we support in pacman.conf

2018-06-12 Thread Eli Schwartz
Ini-style configuration formats are all over the place. So are we, for that matter, as we switched how we treated middle-of-line comments in commit 8a19c4a78251c5e34ecf508a65d943ca2dc833c7 -- namely, they're not comments anymore. This is surprising to users, who report bugs because it used to work,

[pacman-dev] [PATCH] libmakepkg/integrity: use more shared functions to generate signatures

2018-06-12 Thread Eli Schwartz
The newly changed print_all_package_names function can iterate over the list of all package files that will be created; this avoids the need to independently recreate those filenames here. Additionally, since debug packages may not actually exist, check if the package file exists first. If the mai

[pacman-dev] [PATCH] scripts: pass on options such as set -x to child processes

2018-06-12 Thread Eli Schwartz
When re-running makepkg for fakeroot, if `bash -x makepkg` was used this is lost. Fix by encoding the current set of options explicitly in the invocation, both for makepkg and for the wrapper used to test scripts inside the source tree. Also change to use ${BASH_SOURCE[0]} instead of $0 as the lat

Re: [pacman-dev] [PATCH] libmakepkg/integrity: use more shared functions to generate signatures

2018-06-12 Thread Dave Reisner
On Tue, Jun 12, 2018 at 07:28:50AM -0400, Eli Schwartz wrote: > The newly changed print_all_package_names function can iterate over the > list of all package files that will be created; this avoids the need to > independently recreate those filenames here. > > Additionally, since debug packages ma

[pacman-dev] [PATCH v2] libmakepkg/integrity: use more shared functions to generate signatures

2018-06-12 Thread Eli Schwartz
The newly changed print_all_package_names function can iterate over the list of all package files that will be created; this avoids the need to independently recreate those filenames here. Additionally, since debug packages may not actually exist, check if the package file exists first. If the mai

[pacman-dev] [PATCH] makepkg: when signing packages, report package filename on failure

2018-06-12 Thread Eli Schwartz
In commit c6b04c04653ba9933fe978829148312e412a9ea7 the signing function was moved out of fakeroot, and thus out of the create_package loop. This meant that if package signing failed, it was no longer possible to tell which package it failed on by checking which package creation is currently running

[pacman-dev] [PATCH] makepkg: reject PKGBUILDs with both split and non-split package functions

2018-06-12 Thread Eli Schwartz
We accept package_foo() in non-split packages, because it's easier to switch to/from a split package just by removing a pkgname element. But it makes no sense to have both in one PKGBUILD. Signed-off-by: Eli Schwartz --- scripts/libmakepkg/lint_pkgbuild/package_function.sh.in | 9 - 1 fi

[pacman-dev] [PATCH] libmakepkg/lint_pkgbuild: check for invalid variables even if they're empty

2018-06-12 Thread Eli Schwartz
Checking the length of the variable to be non-zero before considering it an error is inconsistent; license=() and depends='' and `declare arch` should be considered just as wrong. In fact the current check detects depends='' as non-zero and returns an error, but happily considers the others to be

[pacman-dev] [PATCH] libmakepkg/tidy: fix debug sources not being properly detected sometimes

2018-06-12 Thread Eli Schwartz
DW_AT_comp_dir is meant to contain the directory in which the compiler was run DW_AT_name contains the source file the compiler was told to use. In the event that DW_AT_name is an absolute path, it is (obviously) not meant to be computed relative to DW_AT_comp_dir. However, we did not handle this

Re: [pacman-dev] [PATCH 7/7] libmakepkg: disallow using 'any' with other arches

2018-06-12 Thread Eli Schwartz
On 06/11/2018 06:57 PM, Morgan Adamiec wrote: > On Mon, 11 Jun 2018 at 22:27, Eli Schwartz wrote: >> >> On 06/11/2018 04:53 PM, morganamilo wrote: >>> Error if the arch array contains any and any other values. This also >>> fixes a bug where the check for `$arch == 'any'` which only evaluated >>>

[pacman-dev] [PATCH 7/7] libmakepkg: disallow using 'any' with other arches

2018-06-12 Thread morganamilo
Error if the arch array contains any and any other values. This also fixes a bug where the check for `$arch == 'any'` which only evaluated the first value in the array, meaning the rest of the values would not be linted. Signed-off-by: morganamilo --- scripts/libmakepkg/lint_pkgbuild/arch.sh.in

Re: [pacman-dev] [PATCH 7/7] libmakepkg: disallow using 'any' with other arches

2018-06-12 Thread Morgan Adamiec
On Wed, 13 Jun 2018 at 02:31, Eli Schwartz wrote: > > On 06/11/2018 06:57 PM, Morgan Adamiec wrote: > > On Mon, 11 Jun 2018 at 22:27, Eli Schwartz wrote: > >> > >> On 06/11/2018 04:53 PM, morganamilo wrote: > >>> Error if the arch array contains any and any other values. This also > >>> fixes a b