]> granicus.if.org Git - curl/commitdiff
cyassl: Include the CyaSSL build config
authorJay Satiro <raysatiro@yahoo.com>
Sun, 12 Apr 2015 03:58:42 +0000 (23:58 -0400)
committerJay Satiro <raysatiro@yahoo.com>
Sun, 12 Apr 2015 03:58:42 +0000 (23:58 -0400)
CyaSSL >= 2.6.0 may have an options.h that was generated during
its build by configure.

configure.ac
lib/vtls/cyassl.c

index 098629801bd4fcf26cd550b9d8fd896066a38213..5673257b8159247372bc5463122f8c30ec7b3e04 100644 (file)
@@ -2049,6 +2049,9 @@ if test "$curl_ssl_msg" = "$init_ssl_msg"; then
       dnl cyassl/ctaocrypt/types.h needs SIZEOF_LONG_LONG defined!
       AC_CHECK_SIZEOF(long long)
 
+      dnl Versions since at least 2.6.0 may have options.h
+      AC_CHECK_HEADERS(cyassl/options.h)
+
       dnl Versions since at least 2.9.4 renamed error.h to error-ssl.h
       AC_CHECK_HEADERS(cyassl/error-ssl.h)
 
index 5e79389ea8dba5b278cacb3fada2e550ade3c212..9ea7a88f6abca638f804e30a532910d147dd4349 100644 (file)
 #include "rawstr.h"
 #include "curl_printf.h"
 
+/* The first CyaSSL include should be its build config aka options.h */
+#ifdef HAVE_CYASSL_OPTIONS_H
+#include <cyassl/options.h>
+#endif
 #include <cyassl/ssl.h>
 #include <cyassl/version.h>
 #ifdef HAVE_CYASSL_ERROR_SSL_H