Port of TI's CC3100 Websock camera demo. Using FreeRTOS, mbedTLS, also parts of Arducam for cams ov5642 and 0v2640. Can also use MT9D111. Work in progress. Be warned some parts maybe a bit flacky. This is for Seeed Arch max only, for an M3, see the demo for CM3 using the 0v5642 aducam mini.
check_config.h
00001 /** 00002 * \file check_config.h 00003 * 00004 * \brief Consistency checks for configuration options 00005 * 00006 * Copyright (C) 2006-2014, ARM Limited, All Rights Reserved 00007 * 00008 * This file is part of mbed TLS (https://tls.mbed.org) 00009 * 00010 * This program is free software; you can redistribute it and/or modify 00011 * it under the terms of the GNU General Public License as published by 00012 * the Free Software Foundation; either version 2 of the License, or 00013 * (at your option) any later version. 00014 * 00015 * This program is distributed in the hope that it will be useful, 00016 * but WITHOUT ANY WARRANTY; without even the implied warranty of 00017 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 00018 * GNU General Public License for more details. 00019 * 00020 * You should have received a copy of the GNU General Public License along 00021 * with this program; if not, write to the Free Software Foundation, Inc., 00022 * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. 00023 */ 00024 00025 /* 00026 * It is recommended to include this file from your config.h 00027 * in order to catch dependency issues early. 00028 */ 00029 00030 #ifndef POLARSSL_CHECK_CONFIG_H 00031 #define POLARSSL_CHECK_CONFIG_H 00032 00033 #if defined(POLARSSL_DEPRECATED_WARNING) && \ 00034 !defined(__GNUC__) && !defined(__clang__) 00035 #error "POLARSSL_DEPRECATED_WARNING only works with GCC and Clang" 00036 #endif 00037 00038 #if defined(POLARSSL_NET_C) && !defined(POLARSSL_HAVE_IPV6) 00039 #if defined(POLARSSL_DEPRECATED_WARNING) 00040 #warning "Using POLARSSL_NET_C without POLARSSL_HAVE_IPV6 is deprecated" 00041 #endif 00042 #if defined(POLARSSL_DEPRECATED_REMOVED) 00043 #define POLARSSL_HAVE_IPV6 00044 #endif 00045 #endif /* POLARSSL_NET_C && !POLARSSL_HAVE_IPV6 */ 00046 00047 #if defined(POLARSSL_AESNI_C) && !defined(POLARSSL_HAVE_ASM) 00048 #error "POLARSSL_AESNI_C defined, but not all prerequisites" 00049 #endif 00050 00051 #if defined(POLARSSL_CERTS_C) && !defined(POLARSSL_PEM_PARSE_C) 00052 #error "POLARSSL_CERTS_C defined, but not all prerequisites" 00053 #endif 00054 00055 #if defined(POLARSSL_CTR_DRBG_C) && !defined(POLARSSL_AES_C) 00056 #error "POLARSSL_CTR_DRBG_C defined, but not all prerequisites" 00057 #endif 00058 00059 #if defined(POLARSSL_DHM_C) && !defined(POLARSSL_BIGNUM_C) 00060 #error "POLARSSL_DHM_C defined, but not all prerequisites" 00061 #endif 00062 00063 #if defined(POLARSSL_ECDH_C) && !defined(POLARSSL_ECP_C) 00064 #error "POLARSSL_ECDH_C defined, but not all prerequisites" 00065 #endif 00066 00067 #if defined(POLARSSL_ECDSA_C) && \ 00068 ( !defined(POLARSSL_ECP_C) || \ 00069 !defined(POLARSSL_ASN1_PARSE_C) || \ 00070 !defined(POLARSSL_ASN1_WRITE_C) ) 00071 #error "POLARSSL_ECDSA_C defined, but not all prerequisites" 00072 #endif 00073 00074 #if defined(POLARSSL_ECDSA_DETERMINISTIC) && !defined(POLARSSL_HMAC_DRBG_C) 00075 #error "POLARSSL_ECDSA_DETERMINISTIC defined, but not all prerequisites" 00076 #endif 00077 00078 #if defined(POLARSSL_ECP_C) && ( !defined(POLARSSL_BIGNUM_C) || ( \ 00079 !defined(POLARSSL_ECP_DP_SECP192R1_ENABLED) && \ 00080 !defined(POLARSSL_ECP_DP_SECP224R1_ENABLED) && \ 00081 !defined(POLARSSL_ECP_DP_SECP256R1_ENABLED) && \ 00082 !defined(POLARSSL_ECP_DP_SECP384R1_ENABLED) && \ 00083 !defined(POLARSSL_ECP_DP_SECP521R1_ENABLED) && \ 00084 !defined(POLARSSL_ECP_DP_BP256R1_ENABLED) && \ 00085 !defined(POLARSSL_ECP_DP_BP384R1_ENABLED) && \ 00086 !defined(POLARSSL_ECP_DP_BP512R1_ENABLED) && \ 00087 !defined(POLARSSL_ECP_DP_SECP192K1_ENABLED) && \ 00088 !defined(POLARSSL_ECP_DP_SECP224K1_ENABLED) && \ 00089 !defined(POLARSSL_ECP_DP_SECP256K1_ENABLED) ) ) 00090 #error "POLARSSL_ECP_C defined, but not all prerequisites" 00091 #endif 00092 00093 #if defined(POLARSSL_ENTROPY_C) && (!defined(POLARSSL_SHA512_C) && \ 00094 !defined(POLARSSL_SHA256_C)) 00095 #error "POLARSSL_ENTROPY_C defined, but not all prerequisites" 00096 #endif 00097 #if defined(POLARSSL_ENTROPY_C) && defined(POLARSSL_SHA512_C) && \ 00098 defined(CTR_DRBG_ENTROPY_LEN) && (CTR_DRBG_ENTROPY_LEN > 64) 00099 #error "CTR_DRBG_ENTROPY_LEN value too high" 00100 #endif 00101 #if defined(POLARSSL_ENTROPY_C) && \ 00102 ( !defined(POLARSSL_SHA512_C) || defined(POLARSSL_ENTROPY_FORCE_SHA256) ) \ 00103 && defined(CTR_DRBG_ENTROPY_LEN) && (CTR_DRBG_ENTROPY_LEN > 32) 00104 #error "CTR_DRBG_ENTROPY_LEN value too high" 00105 #endif 00106 #if defined(POLARSSL_ENTROPY_C) && \ 00107 defined(POLARSSL_ENTROPY_FORCE_SHA256) && !defined(POLARSSL_SHA256_C) 00108 #error "POLARSSL_ENTROPY_FORCE_SHA256 defined, but not all prerequisites" 00109 #endif 00110 00111 #if defined(POLARSSL_GCM_C) && ( \ 00112 !defined(POLARSSL_AES_C) && !defined(POLARSSL_CAMELLIA_C) ) 00113 #error "POLARSSL_GCM_C defined, but not all prerequisites" 00114 #endif 00115 00116 #if defined(POLARSSL_HAVEGE_C) && !defined(POLARSSL_TIMING_C) 00117 #error "POLARSSL_HAVEGE_C defined, but not all prerequisites" 00118 #endif 00119 00120 #if defined(POLARSSL_HMAC_DRBG) && !defined(POLARSSL_MD_C) 00121 #error "POLARSSL_HMAC_DRBG_C defined, but not all prerequisites" 00122 #endif 00123 00124 #if defined(POLARSSL_KEY_EXCHANGE_ECDH_ECDSA_ENABLED) && \ 00125 ( !defined(POLARSSL_ECDH_C) || !defined(POLARSSL_X509_CRT_PARSE_C) ) 00126 #error "POLARSSL_KEY_EXCHANGE_ECDH_ECDSA_ENABLED defined, but not all prerequisites" 00127 #endif 00128 00129 #if defined(POLARSSL_KEY_EXCHANGE_ECDH_RSA_ENABLED) && \ 00130 ( !defined(POLARSSL_ECDH_C) || !defined(POLARSSL_X509_CRT_PARSE_C) ) 00131 #error "POLARSSL_KEY_EXCHANGE_ECDH_RSA_ENABLED defined, but not all prerequisites" 00132 #endif 00133 00134 #if defined(POLARSSL_KEY_EXCHANGE_DHE_PSK_ENABLED) && !defined(POLARSSL_DHM_C) 00135 #error "POLARSSL_KEY_EXCHANGE_DHE_PSK_ENABLED defined, but not all prerequisites" 00136 #endif 00137 00138 #if defined(POLARSSL_KEY_EXCHANGE_ECDHE_PSK_ENABLED) && \ 00139 !defined(POLARSSL_ECDH_C) 00140 #error "POLARSSL_KEY_EXCHANGE_ECDHE_PSK_ENABLED defined, but not all prerequisites" 00141 #endif 00142 00143 #if defined(POLARSSL_KEY_EXCHANGE_DHE_RSA_ENABLED) && \ 00144 ( !defined(POLARSSL_DHM_C) || !defined(POLARSSL_RSA_C) || \ 00145 !defined(POLARSSL_X509_CRT_PARSE_C) || !defined(POLARSSL_PKCS1_V15) ) 00146 #error "POLARSSL_KEY_EXCHANGE_DHE_RSA_ENABLED defined, but not all prerequisites" 00147 #endif 00148 00149 #if defined(POLARSSL_KEY_EXCHANGE_ECDHE_RSA_ENABLED) && \ 00150 ( !defined(POLARSSL_ECDH_C) || !defined(POLARSSL_RSA_C) || \ 00151 !defined(POLARSSL_X509_CRT_PARSE_C) || !defined(POLARSSL_PKCS1_V15) ) 00152 #error "POLARSSL_KEY_EXCHANGE_ECDHE_RSA_ENABLED defined, but not all prerequisites" 00153 #endif 00154 00155 #if defined(POLARSSL_KEY_EXCHANGE_ECDHE_ECDSA_ENABLED) && \ 00156 ( !defined(POLARSSL_ECDH_C) || !defined(POLARSSL_ECDSA_C) || \ 00157 !defined(POLARSSL_X509_CRT_PARSE_C) ) 00158 #error "POLARSSL_KEY_EXCHANGE_ECDHE_ECDSA_ENABLED defined, but not all prerequisites" 00159 #endif 00160 00161 #if defined(POLARSSL_KEY_EXCHANGE_RSA_PSK_ENABLED) && \ 00162 ( !defined(POLARSSL_RSA_C) || !defined(POLARSSL_X509_CRT_PARSE_C) || \ 00163 !defined(POLARSSL_PKCS1_V15) ) 00164 #error "POLARSSL_KEY_EXCHANGE_RSA_PSK_ENABLED defined, but not all prerequisites" 00165 #endif 00166 00167 #if defined(POLARSSL_KEY_EXCHANGE_RSA_ENABLED) && \ 00168 ( !defined(POLARSSL_RSA_C) || !defined(POLARSSL_X509_CRT_PARSE_C) || \ 00169 !defined(POLARSSL_PKCS1_V15) ) 00170 #error "POLARSSL_KEY_EXCHANGE_RSA_ENABLED defined, but not all prerequisites" 00171 #endif 00172 00173 #if defined(POLARSSL_MEMORY_C) && !defined(POLARSSL_PLATFORM_C) 00174 #error "POLARSSL_MEMORY_C defined, but not all prerequisites" 00175 #endif 00176 00177 #if defined(POLARSSL_MEMORY_BUFFER_ALLOC_C) && \ 00178 ( !defined(POLARSSL_PLATFORM_C) || !defined(POLARSSL_PLATFORM_MEMORY) ) 00179 #error "POLARSSL_MEMORY_BUFFER_ALLOC_C defined, but not all prerequisites" 00180 #endif 00181 00182 #if defined(POLARSSL_PADLOCK_C) && !defined(POLARSSL_HAVE_ASM) 00183 #error "POLARSSL_PADLOCK_C defined, but not all prerequisites" 00184 #endif 00185 00186 #if defined(POLARSSL_PBKDF2_C) && !defined(POLARSSL_MD_C) 00187 #error "POLARSSL_PBKDF2_C defined, but not all prerequisites" 00188 #endif 00189 00190 #if defined(POLARSSL_PEM_PARSE_C) && !defined(POLARSSL_BASE64_C) 00191 #error "POLARSSL_PEM_PARSE_C defined, but not all prerequisites" 00192 #endif 00193 00194 #if defined(POLARSSL_PEM_WRITE_C) && !defined(POLARSSL_BASE64_C) 00195 #error "POLARSSL_PEM_WRITE_C defined, but not all prerequisites" 00196 #endif 00197 00198 #if defined(POLARSSL_PK_C) && \ 00199 ( !defined(POLARSSL_RSA_C) && !defined(POLARSSL_ECP_C) ) 00200 #error "POLARSSL_PK_C defined, but not all prerequisites" 00201 #endif 00202 00203 #if defined(POLARSSL_PK_PARSE_C) && !defined(POLARSSL_PK_C) 00204 #error "POLARSSL_PK_PARSE_C defined, but not all prerequisites" 00205 #endif 00206 00207 #if defined(POLARSSL_PK_WRITE_C) && !defined(POLARSSL_PK_C) 00208 #error "POLARSSL_PK_WRITE_C defined, but not all prerequisites" 00209 #endif 00210 00211 #if defined(POLARSSL_PKCS11_C) && !defined(POLARSSL_PK_C) 00212 #error "POLARSSL_PKCS11_C defined, but not all prerequisites" 00213 #endif 00214 00215 #if defined(POLARSSL_PLATFORM_EXIT_ALT) && !defined(POLARSSL_PLATFORM_C) 00216 #error "POLARSSL_PLATFORM_EXIT_ALT defined, but not all prerequisites" 00217 #endif 00218 00219 #if defined(POLARSSL_PLATFORM_EXIT_MACRO) && !defined(POLARSSL_PLATFORM_C) 00220 #error "POLARSSL_PLATFORM_EXIT_MACRO defined, but not all prerequisites" 00221 #endif 00222 00223 #if defined(POLARSSL_PLATFORM_EXIT_MACRO) &&\ 00224 ( defined(POLARSSL_PLATFORM_STD_EXIT) ||\ 00225 defined(POLARSSL_PLATFORM_EXIT_ALT) ) 00226 #error "POLARSSL_PLATFORM_EXIT_MACRO and POLARSSL_PLATFORM_STD_EXIT/POLARSSL_PLATFORM_EXIT_ALT cannot be defined simultaneously" 00227 #endif 00228 00229 #if defined(POLARSSL_PLATFORM_FPRINTF_ALT) && !defined(POLARSSL_PLATFORM_C) 00230 #error "POLARSSL_PLATFORM_FPRINTF_ALT defined, but not all prerequisites" 00231 #endif 00232 00233 #if defined(POLARSSL_PLATFORM_FPRINTF_MACRO) && !defined(POLARSSL_PLATFORM_C) 00234 #error "POLARSSL_PLATFORM_FPRINTF_MACRO defined, but not all prerequisites" 00235 #endif 00236 00237 #if defined(POLARSSL_PLATFORM_FPRINTF_MACRO) &&\ 00238 ( defined(POLARSSL_PLATFORM_STD_FPRINTF) ||\ 00239 defined(POLARSSL_PLATFORM_FPRINTF_ALT) ) 00240 #error "POLARSSL_PLATFORM_FPRINTF_MACRO and POLARSSL_PLATFORM_STD_FPRINTF/POLARSSL_PLATFORM_FPRINTF_ALT cannot be defined simultaneously" 00241 #endif 00242 00243 #if defined(POLARSSL_PLATFORM_FREE_MACRO) &&\ 00244 ( !defined(POLARSSL_PLATFORM_C) || !defined(POLARSSL_PLATFORM_MEMORY) ) 00245 #error "POLARSSL_PLATFORM_FREE_MACRO defined, but not all prerequisites" 00246 #endif 00247 00248 #if defined(POLARSSL_PLATFORM_FREE_MACRO) &&\ 00249 defined(POLARSSL_PLATFORM_STD_FREE) 00250 #error "POLARSSL_PLATFORM_FREE_MACRO and POLARSSL_PLATFORM_STD_FREE cannot be defined simultaneously" 00251 #endif 00252 00253 #if defined(POLARSSL_PLATFORM_FREE_MACRO) && !defined(POLARSSL_PLATFORM_MALLOC_MACRO) 00254 #error "POLARSSL_PLATFORM_MALLOC_MACRO must be defined if POLARSSL_PLATFORM_FREE_MACRO is" 00255 #endif 00256 00257 #if defined(POLARSSL_PLATFORM_MALLOC_MACRO) &&\ 00258 ( !defined(POLARSSL_PLATFORM_C) || !defined(POLARSSL_PLATFORM_MEMORY) ) 00259 #error "POLARSSL_PLATFORM_MALLOC_MACRO defined, but not all prerequisites" 00260 #endif 00261 00262 #if defined(POLARSSL_PLATFORM_MALLOC_MACRO) &&\ 00263 defined(POLARSSL_PLATFORM_STD_MALLOC) 00264 #error "POLARSSL_PLATFORM_MALLOC_MACRO and POLARSSL_PLATFORM_STD_MALLOC cannot be defined simultaneously" 00265 #endif 00266 00267 #if defined(POLARSSL_PLATFORM_MALLOC_MACRO) && !defined(POLARSSL_PLATFORM_FREE_MACRO) 00268 #error "POLARSSL_PLATFORM_FREE_MACRO must be defined if POLARSSL_PLATFORM_MALLOC_MACRO is" 00269 #endif 00270 00271 #if defined(POLARSSL_PLATFORM_MEMORY) && !defined(POLARSSL_PLATFORM_C) 00272 #error "POLARSSL_PLATFORM_MEMORY defined, but not all prerequisites" 00273 #endif 00274 00275 #if defined(POLARSSL_PLATFORM_PRINTF_ALT) && !defined(POLARSSL_PLATFORM_C) 00276 #error "POLARSSL_PLATFORM_PRINTF_ALT defined, but not all prerequisites" 00277 #endif 00278 00279 #if defined(POLARSSL_PLATFORM_PRINTF_MACRO) && !defined(POLARSSL_PLATFORM_C) 00280 #error "POLARSSL_PLATFORM_PRINTF_MACRO defined, but not all prerequisites" 00281 #endif 00282 00283 #if defined(POLARSSL_PLATFORM_PRINTF_MACRO) &&\ 00284 ( defined(POLARSSL_PLATFORM_STD_PRINTF) ||\ 00285 defined(POLARSSL_PLATFORM_PRINTF_ALT) ) 00286 #error "POLARSSL_PLATFORM_PRINTF_MACRO and POLARSSL_PLATFORM_STD_PRINTF/POLARSSL_PLATFORM_PRINTF_ALT cannot be defined simultaneously" 00287 #endif 00288 00289 #if defined(POLARSSL_PLATFORM_SNPRINTF_ALT) && !defined(POLARSSL_PLATFORM_C) 00290 #error "POLARSSL_PLATFORM_SNPRINTF_ALT defined, but not all prerequisites" 00291 #endif 00292 00293 #if defined(POLARSSL_PLATFORM_SNPRINTF_ALT) && ( defined(_WIN32)\ 00294 && !defined(EFIX64) && !defined(EFI32) ) 00295 #error "POLARSSL_PLATFORM_SNPRINTF_ALT defined but not available on Windows" 00296 #endif 00297 00298 #if defined(POLARSSL_PLATFORM_SNPRINTF_MACRO) && !defined(POLARSSL_PLATFORM_C) 00299 #error "POLARSSL_PLATFORM_SNPRINTF_MACRO defined, but not all prerequisites" 00300 #endif 00301 00302 #if defined(POLARSSL_PLATFORM_SNPRINTF_MACRO) &&\ 00303 ( defined(POLARSSL_PLATFORM_STD_SNPRINTF) ||\ 00304 defined(POLARSSL_PLATFORM_SNPRINTF_ALT) ) 00305 #error "POLARSSL_PLATFORM_SNPRINTF_MACRO and POLARSSL_PLATFORM_STD_SNPRINTF/POLARSSL_PLATFORM_SNPRINTF_ALT cannot be defined simultaneously" 00306 #endif 00307 00308 #if defined(POLARSSL_PLATFORM_STD_MEM_HDR) &&\ 00309 !defined(POLARSSL_PLATFORM_NO_STD_FUNCTIONS) 00310 #error "POLARSSL_PLATFORM_STD_MEM_HDR defined, but not all prerequisites" 00311 #endif 00312 00313 #if defined(POLARSSL_PLATFORM_STD_MALLOC) && !defined(POLARSSL_PLATFORM_MEMORY) 00314 #error "POLARSSL_PLATFORM_STD_MALLOC defined, but not all prerequisites" 00315 #endif 00316 00317 #if defined(POLARSSL_PLATFORM_STD_MALLOC) && !defined(POLARSSL_PLATFORM_MEMORY) 00318 #error "POLARSSL_PLATFORM_STD_MALLOC defined, but not all prerequisites" 00319 #endif 00320 00321 #if defined(POLARSSL_PLATFORM_STD_FREE) && !defined(POLARSSL_PLATFORM_MEMORY) 00322 #error "POLARSSL_PLATFORM_STD_FREE defined, but not all prerequisites" 00323 #endif 00324 00325 #if defined(POLARSSL_PLATFORM_STD_EXIT) &&\ 00326 !defined(POLARSSL_PLATFORM_EXIT_ALT) 00327 #error "POLARSSL_PLATFORM_STD_EXIT defined, but not all prerequisites" 00328 #endif 00329 00330 #if defined(POLARSSL_PLATFORM_STD_FPRINTF) &&\ 00331 !defined(POLARSSL_PLATFORM_FPRINTF_ALT) 00332 #error "POLARSSL_PLATFORM_STD_FPRINTF defined, but not all prerequisites" 00333 #endif 00334 00335 #if defined(POLARSSL_PLATFORM_STD_PRINTF) &&\ 00336 !defined(POLARSSL_PLATFORM_PRINTF_ALT) 00337 #error "POLARSSL_PLATFORM_STD_PRINTF defined, but not all prerequisites" 00338 #endif 00339 00340 #if defined(POLARSSL_PLATFORM_STD_SNPRINTF) &&\ 00341 !defined(POLARSSL_PLATFORM_SNPRINTF_ALT) 00342 #error "POLARSSL_PLATFORM_STD_SNPRINTF defined, but not all prerequisites" 00343 #endif 00344 00345 #if defined(POLARSSL_RSA_C) && ( !defined(POLARSSL_BIGNUM_C) || \ 00346 !defined(POLARSSL_OID_C) ) 00347 #error "POLARSSL_RSA_C defined, but not all prerequisites" 00348 #endif 00349 00350 #if defined(POLARSSL_X509_RSASSA_PSS_SUPPORT) && \ 00351 ( !defined(POLARSSL_RSA_C) || !defined(POLARSSL_PKCS1_V21) ) 00352 #error "POLARSSL_X509_RSASSA_PSS_SUPPORT defined, but not all prerequisites" 00353 #endif 00354 00355 #if defined(POLARSSL_SSL_PROTO_SSL3) && ( !defined(POLARSSL_MD5_C) || \ 00356 !defined(POLARSSL_SHA1_C) ) 00357 #error "POLARSSL_SSL_PROTO_SSL3 defined, but not all prerequisites" 00358 #endif 00359 00360 #if defined(POLARSSL_SSL_PROTO_TLS1) && ( !defined(POLARSSL_MD5_C) || \ 00361 !defined(POLARSSL_SHA1_C) ) 00362 #error "POLARSSL_SSL_PROTO_TLS1 defined, but not all prerequisites" 00363 #endif 00364 00365 #if defined(POLARSSL_SSL_PROTO_TLS1_1) && ( !defined(POLARSSL_MD5_C) || \ 00366 !defined(POLARSSL_SHA1_C) ) 00367 #error "POLARSSL_SSL_PROTO_TLS1_1 defined, but not all prerequisites" 00368 #endif 00369 00370 #if defined(POLARSSL_SSL_PROTO_TLS1_2) && ( !defined(POLARSSL_SHA1_C) && \ 00371 !defined(POLARSSL_SHA256_C) && !defined(POLARSSL_SHA512_C) ) 00372 #error "POLARSSL_SSL_PROTO_TLS1_2 defined, but not all prerequisites" 00373 #endif 00374 00375 #if defined(POLARSSL_SSL_CLI_C) && !defined(POLARSSL_SSL_TLS_C) 00376 #error "POLARSSL_SSL_CLI_C defined, but not all prerequisites" 00377 #endif 00378 00379 #if defined(POLARSSL_SSL_TLS_C) && ( !defined(POLARSSL_CIPHER_C) || \ 00380 !defined(POLARSSL_MD_C) ) 00381 #error "POLARSSL_SSL_TLS_C defined, but not all prerequisites" 00382 #endif 00383 00384 #if defined(POLARSSL_SSL_SRV_C) && !defined(POLARSSL_SSL_TLS_C) 00385 #error "POLARSSL_SSL_SRV_C defined, but not all prerequisites" 00386 #endif 00387 00388 #if defined(POLARSSL_SSL_TLS_C) && (!defined(POLARSSL_SSL_PROTO_SSL3) && \ 00389 !defined(POLARSSL_SSL_PROTO_TLS1) && !defined(POLARSSL_SSL_PROTO_TLS1_1) && \ 00390 !defined(POLARSSL_SSL_PROTO_TLS1_2)) 00391 #error "POLARSSL_SSL_TLS_C defined, but no protocols are active" 00392 #endif 00393 00394 #if defined(POLARSSL_SSL_TLS_C) && (defined(POLARSSL_SSL_PROTO_SSL3) && \ 00395 defined(POLARSSL_SSL_PROTO_TLS1_1) && !defined(POLARSSL_SSL_PROTO_TLS1)) 00396 #error "Illegal protocol selection" 00397 #endif 00398 00399 #if defined(POLARSSL_SSL_TLS_C) && (defined(POLARSSL_SSL_PROTO_TLS1) && \ 00400 defined(POLARSSL_SSL_PROTO_TLS1_2) && !defined(POLARSSL_SSL_PROTO_TLS1_1)) 00401 #error "Illegal protocol selection" 00402 #endif 00403 00404 #if defined(POLARSSL_SSL_TLS_C) && (defined(POLARSSL_SSL_PROTO_SSL3) && \ 00405 defined(POLARSSL_SSL_PROTO_TLS1_2) && (!defined(POLARSSL_SSL_PROTO_TLS1) || \ 00406 !defined(POLARSSL_SSL_PROTO_TLS1_1))) 00407 #error "Illegal protocol selection" 00408 #endif 00409 00410 #if defined(POLARSSL_SSL_ENCRYPT_THEN_MAC) && \ 00411 !defined(POLARSSL_SSL_PROTO_TLS1) && \ 00412 !defined(POLARSSL_SSL_PROTO_TLS1_1) && \ 00413 !defined(POLARSSL_SSL_PROTO_TLS1_2) 00414 #error "POLARSSL_SSL_ENCRYPT_THEN_MAC defined, but not all prerequsites" 00415 #endif 00416 00417 #if defined(POLARSSL_SSL_EXTENDED_MASTER_SECRET) && \ 00418 !defined(POLARSSL_SSL_PROTO_TLS1) && \ 00419 !defined(POLARSSL_SSL_PROTO_TLS1_1) && \ 00420 !defined(POLARSSL_SSL_PROTO_TLS1_2) 00421 #error "POLARSSL_SSL_EXTENDED_MASTER_SECRET defined, but not all prerequsites" 00422 #endif 00423 00424 #if defined(POLARSSL_SSL_SESSION_TICKETS) && defined(POLARSSL_SSL_TLS_C) && \ 00425 ( !defined(POLARSSL_AES_C) || !defined(POLARSSL_SHA256_C) || \ 00426 !defined(POLARSSL_CIPHER_MODE_CBC) ) 00427 #error "POLARSSL_SSL_SESSION_TICKETS_C defined, but not all prerequisites" 00428 #endif 00429 00430 #if defined(POLARSSL_SSL_CBC_RECORD_SPLITTING) && \ 00431 !defined(POLARSSL_SSL_PROTO_SSL3) && !defined(POLARSSL_SSL_PROTO_TLS1) 00432 #error "POLARSSL_SSL_CBC_RECORD_SPLITTING defined, but not all prerequisites" 00433 #endif 00434 00435 #if defined(POLARSSL_SSL_SERVER_NAME_INDICATION) && \ 00436 !defined(POLARSSL_X509_CRT_PARSE_C) 00437 #error "POLARSSL_SSL_SERVER_NAME_INDICATION defined, but not all prerequisites" 00438 #endif 00439 00440 #if defined(POLARSSL_THREADING_PTHREAD) 00441 #if !defined(POLARSSL_THREADING_C) || defined(POLARSSL_THREADING_IMPL) 00442 #error "POLARSSL_THREADING_PTHREAD defined, but not all prerequisites" 00443 #endif 00444 #define POLARSSL_THREADING_IMPL 00445 #endif 00446 00447 #if defined(POLARSSL_THREADING_ALT) 00448 #if !defined(POLARSSL_THREADING_C) || defined(POLARSSL_THREADING_IMPL) 00449 #error "POLARSSL_THREADING_ALT defined, but not all prerequisites" 00450 #endif 00451 #define POLARSSL_THREADING_IMPL 00452 #endif 00453 00454 #if defined(POLARSSL_THREADING_C) && !defined(POLARSSL_THREADING_IMPL) 00455 #error "POLARSSL_THREADING_C defined, single threading implementation required" 00456 #endif 00457 #undef POLARSSL_THREADING_IMPL 00458 00459 #if defined(POLARSSL_VERSION_FEATURES) && !defined(POLARSSL_VERSION_C) 00460 #error "POLARSSL_VERSION_FEATURES defined, but not all prerequisites" 00461 #endif 00462 00463 #if defined(POLARSSL_X509_USE_C) && ( !defined(POLARSSL_BIGNUM_C) || \ 00464 !defined(POLARSSL_OID_C) || !defined(POLARSSL_ASN1_PARSE_C) || \ 00465 !defined(POLARSSL_PK_PARSE_C) ) 00466 #error "POLARSSL_X509_USE_C defined, but not all prerequisites" 00467 #endif 00468 00469 #if defined(POLARSSL_X509_CREATE_C) && ( !defined(POLARSSL_BIGNUM_C) || \ 00470 !defined(POLARSSL_OID_C) || !defined(POLARSSL_ASN1_WRITE_C) || \ 00471 !defined(POLARSSL_PK_WRITE_C) ) 00472 #error "POLARSSL_X509_CREATE_C defined, but not all prerequisites" 00473 #endif 00474 00475 #if defined(POLARSSL_X509_CRT_PARSE_C) && ( !defined(POLARSSL_X509_USE_C) ) 00476 #error "POLARSSL_X509_CRT_PARSE_C defined, but not all prerequisites" 00477 #endif 00478 00479 #if defined(POLARSSL_X509_CRL_PARSE_C) && ( !defined(POLARSSL_X509_USE_C) ) 00480 #error "POLARSSL_X509_CRL_PARSE_C defined, but not all prerequisites" 00481 #endif 00482 00483 #if defined(POLARSSL_X509_CSR_PARSE_C) && ( !defined(POLARSSL_X509_USE_C) ) 00484 #error "POLARSSL_X509_CSR_PARSE_C defined, but not all prerequisites" 00485 #endif 00486 00487 #if defined(POLARSSL_X509_CRT_WRITE_C) && ( !defined(POLARSSL_X509_CREATE_C) ) 00488 #error "POLARSSL_X509_CRT_WRITE_C defined, but not all prerequisites" 00489 #endif 00490 00491 #if defined(POLARSSL_X509_CSR_WRITE_C) && ( !defined(POLARSSL_X509_CREATE_C) ) 00492 #error "POLARSSL_X509_CSR_WRITE_C defined, but not all prerequisites" 00493 #endif 00494 00495 #endif /* POLARSSL_CHECK_CONFIG_H */ 00496
Generated on Tue Jul 12 2022 22:22:38 by 1.7.2