Skip to contentSkip to conversation

msmtp: use alternatives to manage /usr/lib/sendmail

PATCH New Chen Qi 1 participant 2 messages Jul 15, 2019

lore
Share & tools
lore

Chen Qi

author
#0 lore raw

v2 cover msmtp: use alternatives to manage /usr/lib/sendmail

Changes in V2:
* Use alternatives instead fixing the postinstall. This avoid inconsistent /usr/lib/sendmail link.

The following changes since commit 80ab79168ede2786868cbd354f0950c949f73527:

gnome-themes-standard: remove (2019-07-11 09:32:50 +0100)

are available in the git repository at:

git://git.pokylinux.org/poky-contrib ChenQi/msmtp-lsb
http://git.pokylinux.org/cgit.cgi/poky-contrib/log/?h=ChenQi/msmtp-lsb

Chen Qi (1):
msmtp: use alternatives to manage /usr/lib/sendmail

 meta/recipes-extended/msmtp/msmtp_1.8.4.bb | 9 ++++-----
 1 file changed, 4 insertions(+), 5 deletions(-)
Signature · 1 line
1.9.1
author
#1 lore raw

PATCH v2 1/1 msmtp: use alternatives to manage /usr/lib/sendmail

There are several packages which all provide /usr/lib/sendmail when lsb is enabled. So use alternative to manage it.

---
 meta/recipes-extended/msmtp/msmtp_1.8.4.bb | 9 ++++-----
 1 file changed, 4 insertions(+), 5 deletions(-)
meta/recipes-extended/msmtp/msmtp_1.8.4.bb +4 -5
index 888c1bb..0f10500 100644
@@ -19,11 +19,10 @@ inherit gettext autotools update-alternatives pkgconfig
 EXTRA_OECONF += "--without-libsecret --without-libgsasl --without-libidn"
 
 ALTERNATIVE_${PN} = "sendmail"
+# /usr/lib/sendmial is required by LSB core test
+ALTERNATIVE_${PN}_linuxstdbase = "sendmail usr-lib-sendmail"
 ALTERNATIVE_TARGET[sendmail] = "${bindir}/msmtp"
 ALTERNATIVE_LINK_NAME[sendmail] = "${sbindir}/sendmail"
+ALTERNATIVE_TARGET[usr-lib-sendmail] = "${bindir}/msmtp"
+ALTERNATIVE_LINK_NAME[usr-lib-sendmail] = "/usr/lib/sendmail"
 ALTERNATIVE_PRIORITY = "100"
-
-pkg_postinst_${PN}_linuxstdbase () {
-	# /usr/lib/sendmial is required by LSB core test
-	[ ! -L $D/usr/lib/sendmail ] && ln -sf ${sbindir}/sendmail $D/usr/lib/
-}
Signature · 1 line
1.9.1