aboutsummaryrefslogtreecommitdiff
path: root/elf
diff options
context:
space:
mode:
authorAdhemerval Zanella <adhemerval.zanella@linaro.org>2023-10-02 09:11:49 -0300
committerAdhemerval Zanella <adhemerval.zanella@linaro.org>2023-10-30 13:03:59 -0300
commite6e3c666880847ad908692087ca6d5015895dffa (patch)
treed8a728bc0a180334644cb62ce3f83905d5ce4c11 /elf
parentbb2ff12abd1ee7945957c6fb6f4c9ee091e446ce (diff)
downloadglibc-e6e3c666880847ad908692087ca6d5015895dffa.tar
glibc-e6e3c666880847ad908692087ca6d5015895dffa.tar.gz
glibc-e6e3c666880847ad908692087ca6d5015895dffa.tar.bz2
glibc-e6e3c666880847ad908692087ca6d5015895dffa.zip
crypt: Remove libcrypt support
All the crypt related functions, cryptographic algorithms, and make requirements are removed, with only the exception of md5 implementation which is moved to locale folder since it is required by localedef for integrity protection (libc's locale-reading code does not check these, but localedef does generate them). Besides thec code itself, both internal documentation and the manual is also adjusted. This allows to remove both --enable-crypt and --enable-nss-crypt configure options. Checked with a build for all affected ABIs. Co-authored-by: Zack Weinberg <zack@owlfolio.org> Reviewed-by: Carlos O'Donell <carlos@redhat.com>
Diffstat (limited to 'elf')
-rw-r--r--elf/Makefile38
-rw-r--r--elf/tst-linkall-static.c6
2 files changed, 0 insertions, 44 deletions
diff --git a/elf/Makefile b/elf/Makefile
index 9176cbf1e3..b46dee1c16 100644
--- a/elf/Makefile
+++ b/elf/Makefile
@@ -1217,23 +1217,6 @@ $(objpfx)tst-_dl_addr_inside_object: $(objpfx)dl-addr-obj.os
CFLAGS-tst-_dl_addr_inside_object.c += $(PIE-ccflag)
endif
-# We can only test static libcrypt use if libcrypt has been built,
-# and either NSS crypto is not in use, or static NSS libraries are
-# available.
-ifeq ($(build-crypt),no)
-CFLAGS-tst-linkall-static.c += -DUSE_CRYPT=0
-else
-ifeq ($(nss-crypt),no)
-CFLAGS-tst-linkall-static.c += -DUSE_CRYPT=1
-else
-ifeq ($(static-nss-crypt),no)
-CFLAGS-tst-linkall-static.c += -DUSE_CRYPT=0
-else
-CFLAGS-tst-linkall-static.c += -DUSE_CRYPT=1
-endif
-endif
-endif
-
include ../Rules
ifeq (yes,$(build-shared))
@@ -1951,9 +1934,6 @@ endif
ifeq ($(have-thread-library),yes)
localplt-built-dso += $(filter-out %_nonshared.a, $(shared-thread-library))
endif
-ifeq ($(build-crypt),yes)
-localplt-built-dso += $(addprefix $(common-objpfx), crypt/libcrypt.so)
-endif
ifneq ($(pthread-in-libc),yes)
localplt-built-dso += $(addprefix $(common-objpfx), rt/librt.so)
endif
@@ -2438,24 +2418,6 @@ $(objpfx)tst-linkall-static: \
$(common-objpfx)rt/librt.a \
$(static-thread-library)
-ifeq ($(build-crypt),yes)
-# If we are using NSS crypto and we have the ability to link statically
-# then we include libcrypt.a, otherwise we leave out libcrypt.a and
-# link as much as we can into the tst-linkall-static test. This assumes
-# that linking with libcrypt.a does everything required to include the
-# static NSS crypto library.
-ifeq (yesyes,$(nss-crypt)$(static-nss-crypt))
-$(objpfx)tst-linkall-static: \
- $(common-objpfx)crypt/libcrypt.a
-endif
-# If we are not using NSS crypto then we always have the ability to link
-# with libcrypt.a.
-ifeq (no,$(nss-crypt))
-$(objpfx)tst-linkall-static: \
- $(common-objpfx)crypt/libcrypt.a
-endif
-endif
-
LDFLAGS-nextmod3.so = -Wl,--version-script=nextmod3.map
# The application depends on the DSO, and the DSO loads the plugin.
diff --git a/elf/tst-linkall-static.c b/elf/tst-linkall-static.c
index d9943aa753..ccb6000d86 100644
--- a/elf/tst-linkall-static.c
+++ b/elf/tst-linkall-static.c
@@ -18,9 +18,6 @@
#include <math.h>
#include <pthread.h>
-#if USE_CRYPT
-# include <crypt.h>
-#endif
#include <resolv.h>
#include <dlfcn.h>
#include <utmp.h>
@@ -34,9 +31,6 @@ void *references[] =
{
&pow, /* libm */
&pthread_create, /* libpthread */
-#if USE_CRYPT
- &crypt, /* libcrypt */
-#endif
&res_send, /* libresolv */
&dlopen, /* libdl */
&login, /* libutil */