Fix ZT_SSO_SUPPORTED flag behavior. Allow disabling for embedded targets.
This commit is contained in:
parent
d67f59f5b5
commit
6f4a69703b
3 changed files with 43 additions and 30 deletions
|
@ -50,16 +50,17 @@
|
|||
#define __UNIX_LIKE__
|
||||
#endif
|
||||
#include <endian.h>
|
||||
|
||||
#if (defined(__amd64) || defined(__amd64__) || defined(__x86_64) || defined(__x86_64__) || defined(__AMD64) || defined(__AMD64__) || defined(_M_X64) || defined(__aarch64__))
|
||||
#define OIDC_SUPPORTED 1
|
||||
#else
|
||||
#define OIDC_SUPPORTED 0
|
||||
#ifdef ZT_SSO_SUPPORTED
|
||||
#define ZT_SSO_ENABLED 1
|
||||
#endif
|
||||
#endif
|
||||
#endif
|
||||
|
||||
#ifdef __APPLE__
|
||||
#define OIDC_SUPPORTED 1
|
||||
#ifdef ZT_SSO_SUPPORTED
|
||||
#define ZT_SSO_ENABLED 1
|
||||
#endif
|
||||
#define likely(x) __builtin_expect((x),1)
|
||||
#define unlikely(x) __builtin_expect((x),0)
|
||||
#include <TargetConditionals.h>
|
||||
|
@ -73,7 +74,9 @@
|
|||
#endif
|
||||
|
||||
#if defined(__FreeBSD__) || defined(__OpenBSD__) || defined(__NetBSD__)
|
||||
#define OIDC_SUPPORTED 0
|
||||
#ifdef ZT_SSO_SUPPORTED
|
||||
#define ZT_SSO_ENABLED 0
|
||||
#endif
|
||||
#ifndef __UNIX_LIKE__
|
||||
#define __UNIX_LIKE__
|
||||
#endif
|
||||
|
@ -89,7 +92,9 @@
|
|||
#endif
|
||||
|
||||
#if defined(_WIN32) || defined(_WIN64)
|
||||
#define OIDC_SUPPORTED 1
|
||||
#ifdef ZT_SSO_SUPPORTED
|
||||
#define ZT_SSO_ENABLED 1
|
||||
#endif
|
||||
#ifndef __WINDOWS__
|
||||
#define __WINDOWS__
|
||||
#endif
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue