在Xrouter平台适配一个新的机型的时候,发现glibc 2.38 版本已经去掉了 libcrypt。导致crypt函数也无法使用了。
可替换的库:https://github.com/besser82/libxcrypt
https://sourceware.org/legacy-ml/libc-alpha/2017-08/msg01257.html
[glibc/zack/remove-libcrypt] Remove all of the remaining libcrypt code.
commit 46e817c4982dfda6aaf6863c141b2e56cfc75acd Author: Zack Weinberg <zack@owlfolio.org> Date: Thu Sep 21 14:58:05 2023 -0400 Remove all of the remaining libcrypt code. Completing the removal of libcrypt, delete all of its actual code. This patch contains only file removals: git rm -r crypt git rm include/crypt.h git rm $(find sysdeps -name libcrypt.abilist) git rm $(find sysdeps -name fips-private.h) git rm $(find sysdeps -name 'md5-*' -o -name 'sha256-*' -o -name 'sha512-*') For this patch (not the earlier ones, I'd still be waiting) I ran the complete testsuite and found no *new* failures. 26 tests are failing on my machine due to probable environment issues, but they were all failing on trunk before I started making changes, and none of them appear to have anything to do with this patchset.
https://inbox.sourceware.org/glibc-cvs/20230921202524.29CA53858005@sourceware.org/T/