mirror of
https://gitlab.com/chrony/chrony.git
synced 2025-12-07 03:25:06 -05:00
hash: add support for older nettle versions
Use nettle_hashes[] instead of nettle_get_hashes(), which is available only in nettle >= 3.4. nettle_hashes[] is a symbol available in older versions and may be renamed in future. In nettle >= 3.4 it is a macro using nettle_get_hashes() for compatibility.
This commit is contained in:
2
configure
vendored
2
configure
vendored
@@ -867,7 +867,7 @@ if [ $feat_sechash = "1" ] && [ "x$HASH_LINK" = "x" ] && [ $try_nettle = "1" ];
|
||||
test_link="`pkg_config --libs nettle`"
|
||||
if test_code 'nettle' 'nettle/nettle-meta.h nettle/sha2.h' \
|
||||
"$test_cflags" "$test_link" \
|
||||
'return nettle_get_hashes()[0]->context_size;'
|
||||
'return nettle_hashes[0]->context_size;'
|
||||
then
|
||||
HASH_OBJ="hash_nettle.o"
|
||||
HASH_LINK="$test_link"
|
||||
|
||||
Reference in New Issue
Block a user