From f4edc7180e472779682df2e5a115c9713755ff9b Mon Sep 17 00:00:00 2001 From: Christian Wiese Date: Fri, 11 Apr 2014 11:15:00 +0200 Subject: doc: curvetun: add documentation how to use libsodium instead of libnacl Add information to INSTALL on how to build with libsodium. Signed-off-by: Christian Wiese Signed-off-by: Daniel Borkmann --- INSTALL | 20 +++++++++++++++++++- 1 file changed, 19 insertions(+), 1 deletion(-) diff --git a/INSTALL b/INSTALL index eefac70..d828f39 100644 --- a/INSTALL +++ b/INSTALL @@ -22,7 +22,7 @@ What libraries are required? - libncurses: ifpps, flowtop - libGeoIP >=1.4.8: astraceroute, flowtop, netsniff-ng - libz: astraceroute, flowtop, netsniff-ng - - libnacl: curvetun + - libnacl or libsodium: curvetun - libnetfilter-conntrack: flowtop - libpcap: mausezahn, netsniff-ng (tcpdump-like filters) - liburcu: flowtop @@ -119,6 +119,24 @@ nacl_path.sh this way: $ cd curvetun $ ./nacl_path.sh ~/nacl/build/include/x86 ~/nacl/build/lib/x86 +Instead of libnacl you can also use libsodium which itself is a portable, +cross-compilable, API compatible drop-in replacement for libnacl. + +In order to use libsodium you need to provide some little help when running +the configure script, so it will be able to detect the needed header files. +Additionally you need to configure the build to not link against libnacl +but against libsodium. + +In the case libsodium was installed into /usr/local you run the netsniff-ng +configure script this way: + + $ NACL_INC_DIR=/usr/local/include/sodium NACL_LIB=sodium ./configure + +Alternatively you can use pkg-config for determining the include dir by +setting the NACL_INC_DIR variable for the configure script like this: + + $ NACL_INC_DIR=$(pkg-config --variable=includedir libsodium )/sodium + When done, netsniff-ng's build infrastructure will read those evironment variables in order to get the needed paths to NaCl. -- cgit v1.2.3-54-g00ecf