diff mbox series

[3/9] package/dovecot: add optional dependency to libxcrypt

Message ID 20240403153641.4122789-3-bernd@kuhls.net
State Accepted
Headers show
Series [1/9] package/apg: add optional dependency to libxcrypt | expand

Commit Message

Bernd Kuhls April 3, 2024, 3:36 p.m. UTC
When glibc was bumped to version 2.39 in commit
b5680f53d60acf8ff6010082f873438a39bd5d97 it removed the deprecated
libcrypt support.

As glibc's libcrypt was providing dovecot's libcrypt dependency this
broke the dovecot build using glibc version 2.39.

To fix this select the libxcrypt dependency to dovecot when using a
glibc toolchain and add the dependency if selected.

Fixes:
http://autobuild.buildroot.net/results/99d816fb7a033ec73a958200041f0dcd728e0e87/

Signed-off-by: Bernd Kuhls <bernd@kuhls.net>
---
 package/dovecot/Config.in  | 1 +
 package/dovecot/dovecot.mk | 4 ++++
 2 files changed, 5 insertions(+)
diff mbox series

Patch

diff --git a/package/dovecot/Config.in b/package/dovecot/Config.in
index 20b08b62be..c94421526f 100644
--- a/package/dovecot/Config.in
+++ b/package/dovecot/Config.in
@@ -2,6 +2,7 @@  config BR2_PACKAGE_DOVECOT
 	bool "dovecot"
 	depends on !BR2_STATIC_LIBS
 	depends on BR2_USE_MMU # fork()
+	select BR2_PACKAGE_LIBXCRYPT if BR2_TOOLCHAIN_USES_GLIBC
 	select BR2_PACKAGE_OPENSSL
 	select BR2_PACKAGE_ZLIB
 	help
diff --git a/package/dovecot/dovecot.mk b/package/dovecot/dovecot.mk
index f90996fdd7..b8652900d0 100644
--- a/package/dovecot/dovecot.mk
+++ b/package/dovecot/dovecot.mk
@@ -73,6 +73,10 @@  else
 DOVECOT_CONF_OPTS += --without-sodium
 endif
 
+ifeq ($(BR2_PACKAGE_LIBXCRYPT),y)
+DOVECOT_DEPENDENCIES += libxcrypt
+endif
+
 ifeq ($(BR2_PACKAGE_LINUX_PAM),y)
 DOVECOT_CONF_OPTS += --with-pam
 DOVECOT_DEPENDENCIES += linux-pam