mirror of
https://github.com/zeromq/libzmq.git
synced 2025-11-12 11:14:46 +01:00
Problem: tweetnacl sources are a mess
- they have no copyright / license statement - they are in some randomish directory structure - they are a mix of postable and non-portable files - they do not conform to conditional compile environment Overall, it makes it rather more work than needed, in build scripts. Solution: clean up tweetnacl sauce. - merged code into single tweetnacl.c and .h - standard copyright header, DJB to AUTHORS - moved into src/ along with all other source files - all system and conditional compilation hidden in these files - thus, they can be compiled and packaged in all cases - ZMQ_USE_TWEETNACL is set when we're using built-in tweetnacl - HAVE_LIBSODIUM is set when we're using external libsodium
This commit is contained in:
@@ -34,9 +34,8 @@
|
||||
|
||||
#include "platform.hpp"
|
||||
|
||||
#if defined (HAVE_TWEETNACL)
|
||||
# include "tweetnacl_base.h"
|
||||
# include "randombytes.h"
|
||||
#if defined (ZMQ_USE_TWEETNACL)
|
||||
# include "tweetnacl.h"
|
||||
#elif defined (HAVE_LIBSODIUM)
|
||||
# include "sodium.h"
|
||||
#endif
|
||||
@@ -49,7 +48,7 @@
|
||||
|| crypto_secretbox_NONCEBYTES != 24 \
|
||||
|| crypto_secretbox_ZEROBYTES != 32 \
|
||||
|| crypto_secretbox_BOXZEROBYTES != 16
|
||||
# error "libsodium not built properly"
|
||||
# error "CURVE library not built properly"
|
||||
#endif
|
||||
|
||||
#include "mechanism.hpp"
|
||||
|
||||
Reference in New Issue
Block a user