mirror of
https://github.com/Mbed-TLS/mbedtls.git
synced 2026-03-20 19:21:09 +01:00
Unify the detection of Unix-like platforms
We were using slightly different guards to decide whether to include `<unistd.h>` in different places. Unify those. Signed-off-by: Gilles Peskine <Gilles.Peskine@arm.com>
This commit is contained in:
3
ChangeLog.d/unistd.txt
Normal file
3
ChangeLog.d/unistd.txt
Normal file
@@ -0,0 +1,3 @@
|
|||||||
|
Changes
|
||||||
|
* Tweak the detection of Unix-like platforms, which makes more system
|
||||||
|
interfaces (timing, threading) available on Haiku, QNX and Midipix.
|
||||||
@@ -19,9 +19,7 @@
|
|||||||
|
|
||||||
#if defined(MBEDTLS_NET_C)
|
#if defined(MBEDTLS_NET_C)
|
||||||
|
|
||||||
#if !defined(unix) && !defined(__unix__) && !defined(__unix) && \
|
#if !defined(MBEDTLS_PLATFORM_IS_UNIXLIKE) && !defined(_WIN32)
|
||||||
!defined(__APPLE__) && !defined(_WIN32) && !defined(__QNXNTO__) && \
|
|
||||||
!defined(__HAIKU__) && !defined(__midipix__)
|
|
||||||
#error "This module only works on Unix and Windows, see MBEDTLS_NET_C in mbedtls_config.h"
|
#error "This module only works on Unix and Windows, see MBEDTLS_NET_C in mbedtls_config.h"
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user