0
0
Fork 0
mirror of https://github.com/matrix-construct/construct synced 2024-06-26 13:58:18 +02:00

configure: Use pkg check for libsodium.

This commit is contained in:
Danilo Spinella 2019-06-06 03:43:48 -07:00 committed by Jason Volk
parent fe41932b1a
commit 731e474b10

View file

@ -1044,11 +1044,9 @@ AC_HELP_STRING([--with-sodium-libs=[[[DIR]]]], [Path to sodium library directory
SODIUM_LDFLAGS="-L$withval" SODIUM_LDFLAGS="-L$withval"
], []) ], [])
RB_CHK_SYSHEADER(sodium.h, [SODIUM_H]) PKG_CHECK_MODULES(SODIUM, libsodium,
AC_CHECK_LIB([sodium], sodium_init,
[ [
have_sodium="yes" have_sodium="yes"
SODIUM_LIBS="-lsodium"
], [ ], [
have_sodium="no" have_sodium="no"
AC_MSG_ERROR([libsodium is required but not found. Try apt-get install libsodium-dev]) AC_MSG_ERROR([libsodium is required but not found. Try apt-get install libsodium-dev])