diff mbox series

[1/1] package/openrc: add libxcrypt optional dependency

Message ID 20240407141608.1877716-1-fontaine.fabrice@gmail.com
State Accepted
Headers show
Series [1/1] package/openrc: add libxcrypt optional dependency | expand

Commit Message

Fabrice Fontaine April 7, 2024, 2:16 p.m. UTC
Fix the following build failure raised since bump of glibc to version
2.39 in commit b5680f53d60acf8ff6010082f873438a39bd5d97:

../output-1/build/openrc-0.52.1/meson.build:129:21: ERROR: C shared or static library 'crypt' not found

Fixes: b5680f53d60acf8ff6010082f873438a39bd5d97
 - http://autobuild.buildroot.org/results/52187a593d3da39051e635a9cb5a19d5bfe2bef6

Signed-off-by: Fabrice Fontaine <fontaine.fabrice@gmail.com>
---
 package/openrc/Config.in | 1 +
 package/openrc/openrc.mk | 4 ++++
 2 files changed, 5 insertions(+)
diff mbox series

Patch

diff --git a/package/openrc/Config.in b/package/openrc/Config.in
index adc61d2546..42d7347b0e 100644
--- a/package/openrc/Config.in
+++ b/package/openrc/Config.in
@@ -7,6 +7,7 @@  config BR2_PACKAGE_OPENRC
 	select BR2_PACKAGE_BUSYBOX_SHOW_OTHERS # kmod tools
 	select BR2_PACKAGE_KMOD # runtime
 	select BR2_PACKAGE_KMOD_TOOLS # runtime
+	select BR2_PACKAGE_LIBXCRYPT if BR2_TOOLCHAIN_USES_GLIBC
 	select BR2_PACKAGE_NCURSES
 	help
 	  Init that works on top of pid 1 (for example
diff --git a/package/openrc/openrc.mk b/package/openrc/openrc.mk
index f8e51f6720..69f5b3a121 100644
--- a/package/openrc/openrc.mk
+++ b/package/openrc/openrc.mk
@@ -33,6 +33,10 @@  else
 OPENRC_CONF_OPTS += -Dselinux=disabled
 endif
 
+ifeq ($(BR2_PACKAGE_LIBXCRYPT),y)
+OPENRC_DEPENDENCIES += libxcrypt
+endif
+
 ifeq ($(BR2_PACKAGE_LINUX_PAM),y)
 OPENRC_CONF_OPTS += -Dpam=true
 OPENRC_DEPENDENCIES += linux-pam