[pacman-dev] [pacman] [PATCH] makepkg: remove makedepends before installing built package

Erich Eckner arch at eckner.net
Thu Sep 12 18:30:42 UTC 2019


-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA256

On Thu, 12 Sep 2019, Levente Polyak wrote:
> On 9/12/19 3:22 PM, arch at eckner.net wrote:
>> From: Erich Eckner <git at eckner.net>
>>
>> When running `makepkg -i` it may be necessary to first remove make- and
>> checkdepends before installing the built package - for example if they
>> conflict each other. This is the case for wireguard-arch which
>> makedepends and conflicts wireguard-dkms.
>>
>> Signed-off-by: Erich Eckner <git at eckner.net>
>> ---
>>  scripts/makepkg.sh.in | 3 +++
>>  1 file changed, 3 insertions(+)
>>
>> diff --git a/scripts/makepkg.sh.in b/scripts/makepkg.sh.in
>> index 43484db3..25d97287 100644
>> --- a/scripts/makepkg.sh.in
>> +++ b/scripts/makepkg.sh.in
>> @@ -821,6 +821,9 @@ create_srcpackage() {
>>  install_package() {
>>  	(( ! INSTALL )) && return 0
>>
>> +	remove_deps || return $?
>> +	RMDEPS=0
>> +
>>  	if (( ! SPLITPKG )); then
>>  		msg "$(gettext "Installing package %s with %s...")" "$pkgname" "$PACMAN -U"
>>  	else
>>
>
>
> This makes --install imply --rmdeps. I think the minimum would be to
> document this behavior in the CLI help and manpage.

No, it would not do that: remove_deps bails out early if RMDEPS == 0. This 
is also used in the current program flow: remove_deps is called 
unconditionally at the end of the cleanup trap.

>
> cheers
> Levente

Regards,
Erich
-----BEGIN PGP SIGNATURE-----

iQIyBAEBCAAdFiEE3p92iMrPBP64GmxZCu7JB1Xae1oFAl16jtMACgkQCu7JB1Xa
e1r1nQ/3e4Pgvmkgs9HLZc0+05eBoePbG7pjhPCp1LLa8aBBLWr5VGqyI1IcqFlX
ckcJNF+JNE1pJIQr2AwLtRuy6Bk1ZvXYg6mksqstnuDDsn+BG/oz/L1e5IpSJmja
uIhCiSx4TKggI2mXJkFxhAPxS/ksic8s/fBOCtrAjgkWZlhw4HujvCVHsdGhevvH
KCOTzHxTrxiQ/CTXq+ykgl2RbJt3R95sKQjvZDDP1BmK4vao8QbTHymFuxEgXotp
Y/CtR1wSvXO9KAUCjojviXRRQffQUE48nzqFdcFRez6SkiQ2hhflP4T1EUcyEX1P
aWY4LN4CunPOQzhoglCrFsI9/52De/dCueB+VYDoy9/sJRpEjoF0mlsaXDMX7BPl
l4VVQeLnbYBZk9dmqynSr1OCsRlPzZixa6jnzmchl7YGyAdFcInmQtuVjDJYx0Sc
ULNIVUy2yKp7RuTrCVEsUYrUTa3Jb4bdh+0dmMp/8I+e9jiPvlnuq8u2x0t2xZQD
Ad+XxokNbxEWrrXIw+86MAY5pDjpqiyww0F8C4jGQ0q/hhumF6/VWpZkp8jJJiHE
XTPIptUfnOl2Nm6mgd29+tUj0/aFnnH7toenYE7PolioQsFTEyKA3dCLd5nNS5VO
aRZCEVWdg802q5i+1w1iDynAgPJB66QMz8W6f4Y7E1zwu2Rwew==
=yfMD
-----END PGP SIGNATURE-----


More information about the pacman-dev mailing list