mbed TLS v1.3.11
check_config.h
Go to the documentation of this file.
1 
25 /*
26  * It is recommended to include this file from your config.h
27  * in order to catch dependency issues early.
28  */
29 
30 #ifndef POLARSSL_CHECK_CONFIG_H
31 #define POLARSSL_CHECK_CONFIG_H
32 
33 #if defined(POLARSSL_DEPRECATED_WARNING) && \
34  !defined(__GNUC__) && !defined(__clang__)
35 #error "POLARSSL_DEPRECATED_WARNING only works with GCC and Clang"
36 #endif
37 
38 #if defined(POLARSSL_NET_C) && !defined(POLARSSL_HAVE_IPV6)
39 #if defined(POLARSSL_DEPRECATED_WARNING)
40 #warning "Using POLARSSL_NET_C without POLARSSL_HAVE_IPV6 is deprecated"
41 #endif
42 #if defined(POLARSSL_DEPRECATED_REMOVED)
43 #define POLARSSL_HAVE_IPV6
44 #endif
45 #endif /* POLARSSL_NET_C && !POLARSSL_HAVE_IPV6 */
46 
47 #if defined(POLARSSL_AESNI_C) && !defined(POLARSSL_HAVE_ASM)
48 #error "POLARSSL_AESNI_C defined, but not all prerequisites"
49 #endif
50 
51 #if defined(POLARSSL_CERTS_C) && !defined(POLARSSL_PEM_PARSE_C)
52 #error "POLARSSL_CERTS_C defined, but not all prerequisites"
53 #endif
54 
55 #if defined(POLARSSL_CTR_DRBG_C) && !defined(POLARSSL_AES_C)
56 #error "POLARSSL_CTR_DRBG_C defined, but not all prerequisites"
57 #endif
58 
59 #if defined(POLARSSL_DHM_C) && !defined(POLARSSL_BIGNUM_C)
60 #error "POLARSSL_DHM_C defined, but not all prerequisites"
61 #endif
62 
63 #if defined(POLARSSL_ECDH_C) && !defined(POLARSSL_ECP_C)
64 #error "POLARSSL_ECDH_C defined, but not all prerequisites"
65 #endif
66 
67 #if defined(POLARSSL_ECDSA_C) && \
68  ( !defined(POLARSSL_ECP_C) || \
69  !defined(POLARSSL_ASN1_PARSE_C) || \
70  !defined(POLARSSL_ASN1_WRITE_C) )
71 #error "POLARSSL_ECDSA_C defined, but not all prerequisites"
72 #endif
73 
74 #if defined(POLARSSL_ECDSA_DETERMINISTIC) && !defined(POLARSSL_HMAC_DRBG_C)
75 #error "POLARSSL_ECDSA_DETERMINISTIC defined, but not all prerequisites"
76 #endif
77 
78 #if defined(POLARSSL_ECP_C) && ( !defined(POLARSSL_BIGNUM_C) || ( \
79  !defined(POLARSSL_ECP_DP_SECP192R1_ENABLED) && \
80  !defined(POLARSSL_ECP_DP_SECP224R1_ENABLED) && \
81  !defined(POLARSSL_ECP_DP_SECP256R1_ENABLED) && \
82  !defined(POLARSSL_ECP_DP_SECP384R1_ENABLED) && \
83  !defined(POLARSSL_ECP_DP_SECP521R1_ENABLED) && \
84  !defined(POLARSSL_ECP_DP_BP256R1_ENABLED) && \
85  !defined(POLARSSL_ECP_DP_BP384R1_ENABLED) && \
86  !defined(POLARSSL_ECP_DP_BP512R1_ENABLED) && \
87  !defined(POLARSSL_ECP_DP_SECP192K1_ENABLED) && \
88  !defined(POLARSSL_ECP_DP_SECP224K1_ENABLED) && \
89  !defined(POLARSSL_ECP_DP_SECP256K1_ENABLED) ) )
90 #error "POLARSSL_ECP_C defined, but not all prerequisites"
91 #endif
92 
93 #if defined(POLARSSL_ENTROPY_C) && (!defined(POLARSSL_SHA512_C) && \
94  !defined(POLARSSL_SHA256_C))
95 #error "POLARSSL_ENTROPY_C defined, but not all prerequisites"
96 #endif
97 #if defined(POLARSSL_ENTROPY_C) && defined(POLARSSL_SHA512_C) && \
98  defined(CTR_DRBG_ENTROPY_LEN) && (CTR_DRBG_ENTROPY_LEN > 64)
99 #error "CTR_DRBG_ENTROPY_LEN value too high"
100 #endif
101 #if defined(POLARSSL_ENTROPY_C) && \
102  ( !defined(POLARSSL_SHA512_C) || defined(POLARSSL_ENTROPY_FORCE_SHA256) ) \
103  && defined(CTR_DRBG_ENTROPY_LEN) && (CTR_DRBG_ENTROPY_LEN > 32)
104 #error "CTR_DRBG_ENTROPY_LEN value too high"
105 #endif
106 #if defined(POLARSSL_ENTROPY_C) && \
107  defined(POLARSSL_ENTROPY_FORCE_SHA256) && !defined(POLARSSL_SHA256_C)
108 #error "POLARSSL_ENTROPY_FORCE_SHA256 defined, but not all prerequisites"
109 #endif
110 
111 #if defined(POLARSSL_GCM_C) && ( \
112  !defined(POLARSSL_AES_C) && !defined(POLARSSL_CAMELLIA_C) )
113 #error "POLARSSL_GCM_C defined, but not all prerequisites"
114 #endif
115 
116 #if defined(POLARSSL_HAVEGE_C) && !defined(POLARSSL_TIMING_C)
117 #error "POLARSSL_HAVEGE_C defined, but not all prerequisites"
118 #endif
119 
120 #if defined(POLARSSL_HMAC_DRBG) && !defined(POLARSSL_MD_C)
121 #error "POLARSSL_HMAC_DRBG_C defined, but not all prerequisites"
122 #endif
123 
124 #if defined(POLARSSL_KEY_EXCHANGE_ECDH_ECDSA_ENABLED) && \
125  ( !defined(POLARSSL_ECDH_C) || !defined(POLARSSL_X509_CRT_PARSE_C) )
126 #error "POLARSSL_KEY_EXCHANGE_ECDH_ECDSA_ENABLED defined, but not all prerequisites"
127 #endif
128 
129 #if defined(POLARSSL_KEY_EXCHANGE_ECDH_RSA_ENABLED) && \
130  ( !defined(POLARSSL_ECDH_C) || !defined(POLARSSL_X509_CRT_PARSE_C) )
131 #error "POLARSSL_KEY_EXCHANGE_ECDH_RSA_ENABLED defined, but not all prerequisites"
132 #endif
133 
134 #if defined(POLARSSL_KEY_EXCHANGE_DHE_PSK_ENABLED) && !defined(POLARSSL_DHM_C)
135 #error "POLARSSL_KEY_EXCHANGE_DHE_PSK_ENABLED defined, but not all prerequisites"
136 #endif
137 
138 #if defined(POLARSSL_KEY_EXCHANGE_ECDHE_PSK_ENABLED) && \
139  !defined(POLARSSL_ECDH_C)
140 #error "POLARSSL_KEY_EXCHANGE_ECDHE_PSK_ENABLED defined, but not all prerequisites"
141 #endif
142 
143 #if defined(POLARSSL_KEY_EXCHANGE_DHE_RSA_ENABLED) && \
144  ( !defined(POLARSSL_DHM_C) || !defined(POLARSSL_RSA_C) || \
145  !defined(POLARSSL_X509_CRT_PARSE_C) || !defined(POLARSSL_PKCS1_V15) )
146 #error "POLARSSL_KEY_EXCHANGE_DHE_RSA_ENABLED defined, but not all prerequisites"
147 #endif
148 
149 #if defined(POLARSSL_KEY_EXCHANGE_ECDHE_RSA_ENABLED) && \
150  ( !defined(POLARSSL_ECDH_C) || !defined(POLARSSL_RSA_C) || \
151  !defined(POLARSSL_X509_CRT_PARSE_C) || !defined(POLARSSL_PKCS1_V15) )
152 #error "POLARSSL_KEY_EXCHANGE_ECDHE_RSA_ENABLED defined, but not all prerequisites"
153 #endif
154 
155 #if defined(POLARSSL_KEY_EXCHANGE_ECDHE_ECDSA_ENABLED) && \
156  ( !defined(POLARSSL_ECDH_C) || !defined(POLARSSL_ECDSA_C) || \
157  !defined(POLARSSL_X509_CRT_PARSE_C) )
158 #error "POLARSSL_KEY_EXCHANGE_ECDHE_ECDSA_ENABLED defined, but not all prerequisites"
159 #endif
160 
161 #if defined(POLARSSL_KEY_EXCHANGE_RSA_PSK_ENABLED) && \
162  ( !defined(POLARSSL_RSA_C) || !defined(POLARSSL_X509_CRT_PARSE_C) || \
163  !defined(POLARSSL_PKCS1_V15) )
164 #error "POLARSSL_KEY_EXCHANGE_RSA_PSK_ENABLED defined, but not all prerequisites"
165 #endif
166 
167 #if defined(POLARSSL_KEY_EXCHANGE_RSA_ENABLED) && \
168  ( !defined(POLARSSL_RSA_C) || !defined(POLARSSL_X509_CRT_PARSE_C) || \
169  !defined(POLARSSL_PKCS1_V15) )
170 #error "POLARSSL_KEY_EXCHANGE_RSA_ENABLED defined, but not all prerequisites"
171 #endif
172 
173 #if defined(POLARSSL_MEMORY_C) && !defined(POLARSSL_PLATFORM_C)
174 #error "POLARSSL_MEMORY_C defined, but not all prerequisites"
175 #endif
176 
177 #if defined(POLARSSL_MEMORY_BUFFER_ALLOC_C) && \
178  ( !defined(POLARSSL_PLATFORM_C) || !defined(POLARSSL_PLATFORM_MEMORY) )
179 #error "POLARSSL_MEMORY_BUFFER_ALLOC_C defined, but not all prerequisites"
180 #endif
181 
182 #if defined(POLARSSL_PADLOCK_C) && !defined(POLARSSL_HAVE_ASM)
183 #error "POLARSSL_PADLOCK_C defined, but not all prerequisites"
184 #endif
185 
186 #if defined(POLARSSL_PBKDF2_C) && !defined(POLARSSL_MD_C)
187 #error "POLARSSL_PBKDF2_C defined, but not all prerequisites"
188 #endif
189 
190 #if defined(POLARSSL_PEM_PARSE_C) && !defined(POLARSSL_BASE64_C)
191 #error "POLARSSL_PEM_PARSE_C defined, but not all prerequisites"
192 #endif
193 
194 #if defined(POLARSSL_PEM_WRITE_C) && !defined(POLARSSL_BASE64_C)
195 #error "POLARSSL_PEM_WRITE_C defined, but not all prerequisites"
196 #endif
197 
198 #if defined(POLARSSL_PK_C) && \
199  ( !defined(POLARSSL_RSA_C) && !defined(POLARSSL_ECP_C) )
200 #error "POLARSSL_PK_C defined, but not all prerequisites"
201 #endif
202 
203 #if defined(POLARSSL_PK_PARSE_C) && !defined(POLARSSL_PK_C)
204 #error "POLARSSL_PK_PARSE_C defined, but not all prerequisites"
205 #endif
206 
207 #if defined(POLARSSL_PK_WRITE_C) && !defined(POLARSSL_PK_C)
208 #error "POLARSSL_PK_WRITE_C defined, but not all prerequisites"
209 #endif
210 
211 #if defined(POLARSSL_PKCS11_C) && !defined(POLARSSL_PK_C)
212 #error "POLARSSL_PKCS11_C defined, but not all prerequisites"
213 #endif
214 
215 #if defined(POLARSSL_PLATFORM_EXIT_ALT) && !defined(POLARSSL_PLATFORM_C)
216 #error "POLARSSL_PLATFORM_EXIT_ALT defined, but not all prerequisites"
217 #endif
218 
219 #if defined(POLARSSL_PLATFORM_EXIT_MACRO) && !defined(POLARSSL_PLATFORM_C)
220 #error "POLARSSL_PLATFORM_EXIT_MACRO defined, but not all prerequisites"
221 #endif
222 
223 #if defined(POLARSSL_PLATFORM_EXIT_MACRO) &&\
224  ( defined(POLARSSL_PLATFORM_STD_EXIT) ||\
225  defined(POLARSSL_PLATFORM_EXIT_ALT) )
226 #error "POLARSSL_PLATFORM_EXIT_MACRO and POLARSSL_PLATFORM_STD_EXIT/POLARSSL_PLATFORM_EXIT_ALT cannot be defined simultaneously"
227 #endif
228 
229 #if defined(POLARSSL_PLATFORM_FPRINTF_ALT) && !defined(POLARSSL_PLATFORM_C)
230 #error "POLARSSL_PLATFORM_FPRINTF_ALT defined, but not all prerequisites"
231 #endif
232 
233 #if defined(POLARSSL_PLATFORM_FPRINTF_MACRO) && !defined(POLARSSL_PLATFORM_C)
234 #error "POLARSSL_PLATFORM_FPRINTF_MACRO defined, but not all prerequisites"
235 #endif
236 
237 #if defined(POLARSSL_PLATFORM_FPRINTF_MACRO) &&\
238  ( defined(POLARSSL_PLATFORM_STD_FPRINTF) ||\
239  defined(POLARSSL_PLATFORM_FPRINTF_ALT) )
240 #error "POLARSSL_PLATFORM_FPRINTF_MACRO and POLARSSL_PLATFORM_STD_FPRINTF/POLARSSL_PLATFORM_FPRINTF_ALT cannot be defined simultaneously"
241 #endif
242 
243 #if defined(POLARSSL_PLATFORM_FREE_MACRO) &&\
244  ( !defined(POLARSSL_PLATFORM_C) || !defined(POLARSSL_PLATFORM_MEMORY) )
245 #error "POLARSSL_PLATFORM_FREE_MACRO defined, but not all prerequisites"
246 #endif
247 
248 #if defined(POLARSSL_PLATFORM_FREE_MACRO) &&\
249  defined(POLARSSL_PLATFORM_STD_FREE)
250 #error "POLARSSL_PLATFORM_FREE_MACRO and POLARSSL_PLATFORM_STD_FREE cannot be defined simultaneously"
251 #endif
252 
253 #if defined(POLARSSL_PLATFORM_FREE_MACRO) && !defined(POLARSSL_PLATFORM_MALLOC_MACRO)
254 #error "POLARSSL_PLATFORM_MALLOC_MACRO must be defined if POLARSSL_PLATFORM_FREE_MACRO is"
255 #endif
256 
257 #if defined(POLARSSL_PLATFORM_MALLOC_MACRO) &&\
258  ( !defined(POLARSSL_PLATFORM_C) || !defined(POLARSSL_PLATFORM_MEMORY) )
259 #error "POLARSSL_PLATFORM_MALLOC_MACRO defined, but not all prerequisites"
260 #endif
261 
262 #if defined(POLARSSL_PLATFORM_MALLOC_MACRO) &&\
263  defined(POLARSSL_PLATFORM_STD_MALLOC)
264 #error "POLARSSL_PLATFORM_MALLOC_MACRO and POLARSSL_PLATFORM_STD_MALLOC cannot be defined simultaneously"
265 #endif
266 
267 #if defined(POLARSSL_PLATFORM_MALLOC_MACRO) && !defined(POLARSSL_PLATFORM_FREE_MACRO)
268 #error "POLARSSL_PLATFORM_FREE_MACRO must be defined if POLARSSL_PLATFORM_MALLOC_MACRO is"
269 #endif
270 
271 #if defined(POLARSSL_PLATFORM_MEMORY) && !defined(POLARSSL_PLATFORM_C)
272 #error "POLARSSL_PLATFORM_MEMORY defined, but not all prerequisites"
273 #endif
274 
275 #if defined(POLARSSL_PLATFORM_PRINTF_ALT) && !defined(POLARSSL_PLATFORM_C)
276 #error "POLARSSL_PLATFORM_PRINTF_ALT defined, but not all prerequisites"
277 #endif
278 
279 #if defined(POLARSSL_PLATFORM_PRINTF_MACRO) && !defined(POLARSSL_PLATFORM_C)
280 #error "POLARSSL_PLATFORM_PRINTF_MACRO defined, but not all prerequisites"
281 #endif
282 
283 #if defined(POLARSSL_PLATFORM_PRINTF_MACRO) &&\
284  ( defined(POLARSSL_PLATFORM_STD_PRINTF) ||\
285  defined(POLARSSL_PLATFORM_PRINTF_ALT) )
286 #error "POLARSSL_PLATFORM_PRINTF_MACRO and POLARSSL_PLATFORM_STD_PRINTF/POLARSSL_PLATFORM_PRINTF_ALT cannot be defined simultaneously"
287 #endif
288 
289 #if defined(POLARSSL_PLATFORM_SNPRINTF_ALT) && !defined(POLARSSL_PLATFORM_C)
290 #error "POLARSSL_PLATFORM_SNPRINTF_ALT defined, but not all prerequisites"
291 #endif
292 
293 #if defined(POLARSSL_PLATFORM_SNPRINTF_ALT) && ( defined(_WIN32)\
294  && !defined(EFIX64) && !defined(EFI32) )
295 #error "POLARSSL_PLATFORM_SNPRINTF_ALT defined but not available on Windows"
296 #endif
297 
298 #if defined(POLARSSL_PLATFORM_SNPRINTF_MACRO) && !defined(POLARSSL_PLATFORM_C)
299 #error "POLARSSL_PLATFORM_SNPRINTF_MACRO defined, but not all prerequisites"
300 #endif
301 
302 #if defined(POLARSSL_PLATFORM_SNPRINTF_MACRO) &&\
303  ( defined(POLARSSL_PLATFORM_STD_SNPRINTF) ||\
304  defined(POLARSSL_PLATFORM_SNPRINTF_ALT) )
305 #error "POLARSSL_PLATFORM_SNPRINTF_MACRO and POLARSSL_PLATFORM_STD_SNPRINTF/POLARSSL_PLATFORM_SNPRINTF_ALT cannot be defined simultaneously"
306 #endif
307 
308 #if defined(POLARSSL_PLATFORM_STD_MEM_HDR) &&\
309  !defined(POLARSSL_PLATFORM_NO_STD_FUNCTIONS)
310 #error "POLARSSL_PLATFORM_STD_MEM_HDR defined, but not all prerequisites"
311 #endif
312 
313 #if defined(POLARSSL_PLATFORM_STD_MALLOC) && !defined(POLARSSL_PLATFORM_MEMORY)
314 #error "POLARSSL_PLATFORM_STD_MALLOC defined, but not all prerequisites"
315 #endif
316 
317 #if defined(POLARSSL_PLATFORM_STD_MALLOC) && !defined(POLARSSL_PLATFORM_MEMORY)
318 #error "POLARSSL_PLATFORM_STD_MALLOC defined, but not all prerequisites"
319 #endif
320 
321 #if defined(POLARSSL_PLATFORM_STD_FREE) && !defined(POLARSSL_PLATFORM_MEMORY)
322 #error "POLARSSL_PLATFORM_STD_FREE defined, but not all prerequisites"
323 #endif
324 
325 #if defined(POLARSSL_PLATFORM_STD_EXIT) &&\
326  !defined(POLARSSL_PLATFORM_EXIT_ALT)
327 #error "POLARSSL_PLATFORM_STD_EXIT defined, but not all prerequisites"
328 #endif
329 
330 #if defined(POLARSSL_PLATFORM_STD_FPRINTF) &&\
331  !defined(POLARSSL_PLATFORM_FPRINTF_ALT)
332 #error "POLARSSL_PLATFORM_STD_FPRINTF defined, but not all prerequisites"
333 #endif
334 
335 #if defined(POLARSSL_PLATFORM_STD_PRINTF) &&\
336  !defined(POLARSSL_PLATFORM_PRINTF_ALT)
337 #error "POLARSSL_PLATFORM_STD_PRINTF defined, but not all prerequisites"
338 #endif
339 
340 #if defined(POLARSSL_PLATFORM_STD_SNPRINTF) &&\
341  !defined(POLARSSL_PLATFORM_SNPRINTF_ALT)
342 #error "POLARSSL_PLATFORM_STD_SNPRINTF defined, but not all prerequisites"
343 #endif
344 
345 #if defined(POLARSSL_RSA_C) && ( !defined(POLARSSL_BIGNUM_C) || \
346  !defined(POLARSSL_OID_C) )
347 #error "POLARSSL_RSA_C defined, but not all prerequisites"
348 #endif
349 
350 #if defined(POLARSSL_X509_RSASSA_PSS_SUPPORT) && \
351  ( !defined(POLARSSL_RSA_C) || !defined(POLARSSL_PKCS1_V21) )
352 #error "POLARSSL_X509_RSASSA_PSS_SUPPORT defined, but not all prerequisites"
353 #endif
354 
355 #if defined(POLARSSL_SSL_PROTO_SSL3) && ( !defined(POLARSSL_MD5_C) || \
356  !defined(POLARSSL_SHA1_C) )
357 #error "POLARSSL_SSL_PROTO_SSL3 defined, but not all prerequisites"
358 #endif
359 
360 #if defined(POLARSSL_SSL_PROTO_TLS1) && ( !defined(POLARSSL_MD5_C) || \
361  !defined(POLARSSL_SHA1_C) )
362 #error "POLARSSL_SSL_PROTO_TLS1 defined, but not all prerequisites"
363 #endif
364 
365 #if defined(POLARSSL_SSL_PROTO_TLS1_1) && ( !defined(POLARSSL_MD5_C) || \
366  !defined(POLARSSL_SHA1_C) )
367 #error "POLARSSL_SSL_PROTO_TLS1_1 defined, but not all prerequisites"
368 #endif
369 
370 #if defined(POLARSSL_SSL_PROTO_TLS1_2) && ( !defined(POLARSSL_SHA1_C) && \
371  !defined(POLARSSL_SHA256_C) && !defined(POLARSSL_SHA512_C) )
372 #error "POLARSSL_SSL_PROTO_TLS1_2 defined, but not all prerequisites"
373 #endif
374 
375 #if defined(POLARSSL_SSL_CLI_C) && !defined(POLARSSL_SSL_TLS_C)
376 #error "POLARSSL_SSL_CLI_C defined, but not all prerequisites"
377 #endif
378 
379 #if defined(POLARSSL_SSL_TLS_C) && ( !defined(POLARSSL_CIPHER_C) || \
380  !defined(POLARSSL_MD_C) )
381 #error "POLARSSL_SSL_TLS_C defined, but not all prerequisites"
382 #endif
383 
384 #if defined(POLARSSL_SSL_SRV_C) && !defined(POLARSSL_SSL_TLS_C)
385 #error "POLARSSL_SSL_SRV_C defined, but not all prerequisites"
386 #endif
387 
388 #if defined(POLARSSL_SSL_TLS_C) && (!defined(POLARSSL_SSL_PROTO_SSL3) && \
389  !defined(POLARSSL_SSL_PROTO_TLS1) && !defined(POLARSSL_SSL_PROTO_TLS1_1) && \
390  !defined(POLARSSL_SSL_PROTO_TLS1_2))
391 #error "POLARSSL_SSL_TLS_C defined, but no protocols are active"
392 #endif
393 
394 #if defined(POLARSSL_SSL_TLS_C) && (defined(POLARSSL_SSL_PROTO_SSL3) && \
395  defined(POLARSSL_SSL_PROTO_TLS1_1) && !defined(POLARSSL_SSL_PROTO_TLS1))
396 #error "Illegal protocol selection"
397 #endif
398 
399 #if defined(POLARSSL_SSL_TLS_C) && (defined(POLARSSL_SSL_PROTO_TLS1) && \
400  defined(POLARSSL_SSL_PROTO_TLS1_2) && !defined(POLARSSL_SSL_PROTO_TLS1_1))
401 #error "Illegal protocol selection"
402 #endif
403 
404 #if defined(POLARSSL_SSL_TLS_C) && (defined(POLARSSL_SSL_PROTO_SSL3) && \
405  defined(POLARSSL_SSL_PROTO_TLS1_2) && (!defined(POLARSSL_SSL_PROTO_TLS1) || \
406  !defined(POLARSSL_SSL_PROTO_TLS1_1)))
407 #error "Illegal protocol selection"
408 #endif
409 
410 #if defined(POLARSSL_SSL_ENCRYPT_THEN_MAC) && \
411  !defined(POLARSSL_SSL_PROTO_TLS1) && \
412  !defined(POLARSSL_SSL_PROTO_TLS1_1) && \
413  !defined(POLARSSL_SSL_PROTO_TLS1_2)
414 #error "POLARSSL_SSL_ENCRYPT_THEN_MAC defined, but not all prerequsites"
415 #endif
416 
417 #if defined(POLARSSL_SSL_EXTENDED_MASTER_SECRET) && \
418  !defined(POLARSSL_SSL_PROTO_TLS1) && \
419  !defined(POLARSSL_SSL_PROTO_TLS1_1) && \
420  !defined(POLARSSL_SSL_PROTO_TLS1_2)
421 #error "POLARSSL_SSL_EXTENDED_MASTER_SECRET defined, but not all prerequsites"
422 #endif
423 
424 #if defined(POLARSSL_SSL_SESSION_TICKETS) && defined(POLARSSL_SSL_TLS_C) && \
425  ( !defined(POLARSSL_AES_C) || !defined(POLARSSL_SHA256_C) || \
426  !defined(POLARSSL_CIPHER_MODE_CBC) )
427 #error "POLARSSL_SSL_SESSION_TICKETS_C defined, but not all prerequisites"
428 #endif
429 
430 #if defined(POLARSSL_SSL_CBC_RECORD_SPLITTING) && \
431  !defined(POLARSSL_SSL_PROTO_SSL3) && !defined(POLARSSL_SSL_PROTO_TLS1)
432 #error "POLARSSL_SSL_CBC_RECORD_SPLITTING defined, but not all prerequisites"
433 #endif
434 
435 #if defined(POLARSSL_SSL_SERVER_NAME_INDICATION) && \
436  !defined(POLARSSL_X509_CRT_PARSE_C)
437 #error "POLARSSL_SSL_SERVER_NAME_INDICATION defined, but not all prerequisites"
438 #endif
439 
440 #if defined(POLARSSL_THREADING_PTHREAD)
441 #if !defined(POLARSSL_THREADING_C) || defined(POLARSSL_THREADING_IMPL)
442 #error "POLARSSL_THREADING_PTHREAD defined, but not all prerequisites"
443 #endif
444 #define POLARSSL_THREADING_IMPL
445 #endif
446 
447 #if defined(POLARSSL_THREADING_ALT)
448 #if !defined(POLARSSL_THREADING_C) || defined(POLARSSL_THREADING_IMPL)
449 #error "POLARSSL_THREADING_ALT defined, but not all prerequisites"
450 #endif
451 #define POLARSSL_THREADING_IMPL
452 #endif
453 
454 #if defined(POLARSSL_THREADING_C) && !defined(POLARSSL_THREADING_IMPL)
455 #error "POLARSSL_THREADING_C defined, single threading implementation required"
456 #endif
457 #undef POLARSSL_THREADING_IMPL
458 
459 #if defined(POLARSSL_VERSION_FEATURES) && !defined(POLARSSL_VERSION_C)
460 #error "POLARSSL_VERSION_FEATURES defined, but not all prerequisites"
461 #endif
462 
463 #if defined(POLARSSL_X509_USE_C) && ( !defined(POLARSSL_BIGNUM_C) || \
464  !defined(POLARSSL_OID_C) || !defined(POLARSSL_ASN1_PARSE_C) || \
465  !defined(POLARSSL_PK_PARSE_C) )
466 #error "POLARSSL_X509_USE_C defined, but not all prerequisites"
467 #endif
468 
469 #if defined(POLARSSL_X509_CREATE_C) && ( !defined(POLARSSL_BIGNUM_C) || \
470  !defined(POLARSSL_OID_C) || !defined(POLARSSL_ASN1_WRITE_C) || \
471  !defined(POLARSSL_PK_WRITE_C) )
472 #error "POLARSSL_X509_CREATE_C defined, but not all prerequisites"
473 #endif
474 
475 #if defined(POLARSSL_X509_CRT_PARSE_C) && ( !defined(POLARSSL_X509_USE_C) )
476 #error "POLARSSL_X509_CRT_PARSE_C defined, but not all prerequisites"
477 #endif
478 
479 #if defined(POLARSSL_X509_CRL_PARSE_C) && ( !defined(POLARSSL_X509_USE_C) )
480 #error "POLARSSL_X509_CRL_PARSE_C defined, but not all prerequisites"
481 #endif
482 
483 #if defined(POLARSSL_X509_CSR_PARSE_C) && ( !defined(POLARSSL_X509_USE_C) )
484 #error "POLARSSL_X509_CSR_PARSE_C defined, but not all prerequisites"
485 #endif
486 
487 #if defined(POLARSSL_X509_CRT_WRITE_C) && ( !defined(POLARSSL_X509_CREATE_C) )
488 #error "POLARSSL_X509_CRT_WRITE_C defined, but not all prerequisites"
489 #endif
490 
491 #if defined(POLARSSL_X509_CSR_WRITE_C) && ( !defined(POLARSSL_X509_CREATE_C) )
492 #error "POLARSSL_X509_CSR_WRITE_C defined, but not all prerequisites"
493 #endif
494 
495 #endif /* POLARSSL_CHECK_CONFIG_H */