Build issue with libsodium 1.0.11 (<= 1.0.14)
Hi, if the libsodium is >= 1.0.15 another/newer pwhash_algo is used. But this is unknown in versions that are lower. So the function needed some ifdef to build properly with a smaller lib version: Regards, Matthias
diff --git a/src/trees-plugin.h b/src/trees-plugin.h
index c6fd36e..d3da04f 100644
--- a/src/trees-plugin.h
+++ b/src/trees-plugin.h
@@ -33,9 +33,11 @@ trees_pluging_pwhash_map(int value)
case 0:
/* argon2i, libsodium <= 1.0.14. */
return crypto_pwhash_ALG_ARGON2I13;
+#ifdef crypto_pwhash_ALG_ARGON2IDI3
case 1:
/* argon2id, libsodium >= 1.0.15 */
return crypto_pwhash_ALG_ARGON2ID13;
+#endif
default:
return -1;
}