ustream-ssl: cyassl compatibility with build time options
authorKarl Palsson <karlp@etactica.com>
Mon, 6 Jun 2016 15:49:22 +0000 (15:49 +0000)
committerFelix Fietkau <nbd@nbd.name>
Tue, 7 Jun 2016 07:03:43 +0000 (09:03 +0200)
Adds a HAVE_CYASSL definition to be consistent with polar/mbedtls.
Uses that definition to include the wolfssl build time options.
This enables the correct pullin of the "remainder" of the wolfssl openssl
compatibility options, if they were enabled in the build of wolfssl in the
first place.

Signed-off-by: Karl Palsson <karlp@etactica.com>
CMakeLists.txt
ustream-internal.h

index c1c2b32d72eb0267dbe354a588baf05bfb5281fa..2ce9bf894219f0c1cc95f68e24394be4fa8cca01 100644 (file)
@@ -21,6 +21,7 @@ ELSEIF(CYASSL)
   IF (HAVE_CYASSL_VERSION_H)
     ADD_DEFINITIONS(-DHAVE_CYASSL_VERSION_H)
   ENDIF()
+  ADD_DEFINITIONS(-DHAVE_CYASSL)
   SET(SSL_SRC ustream-io-cyassl.c ustream-openssl.c)
   SET(SSL_LIB cyassl m)
 ELSE()
index 020e1c69d1be70eb27a70ab861b84bcb092da916..4932a0d539c729b181a98905bcadcc29c07fa542 100644 (file)
@@ -26,6 +26,9 @@
 #elif defined(HAVE_POLARSSL)
 #include "ustream-polarssl.h"
 #else
+#if defined(HAVE_CYASSL)
+#include <wolfssl/options.h>
+#endif
 #include "ustream-openssl.h"
 #endif