[pacman-dev] [PATCH v2] libmakepkg/integrity: fix regression that broke --install

Allan McRae allan at archlinux.org
Thu Mar 15 00:53:55 UTC 2018


On 15/03/18 10:42, Eli Schwartz wrote:
> In commit c6b04c04653ba9933fe978829148312e412a9ea7 package signing was
> moved out of fakeroot, and as part of this process, the global pkgname
> variable was modified in order to extract the built package names.
> 
> However, if a debug package was not available and added to the list of
> packages, the function was aborted early, before the pkgname array was
> restored, thereby corrupting the later stages of makepkg and
> specifically the install_package function which needs to know which
> pkgnames to install.
> 
> Fix this by inlining the debug package signing inside the `if` check,
> and as added security switch to using `for pkg in "${pkgname[@]}"` as is
> done in many other parts of makepkg, since package signing does not
> depend on the value of pkgname for anything.
> 
> Additionally, since debug packages may not actually exist, check if the
> package file exists first.
> 
> Signed-off-by: Eli Schwartz <eschwartz at archlinux.org>
> ---
> 
> v2: rm unused variable, also fix case where debug packages aren't
> created because no debug symbols were found.
> 

Looks good!

A


More information about the pacman-dev mailing list