diff options
author | Andreas Kling <kling@serenityos.org> | 2022-10-01 14:23:49 +0200 |
---|---|---|
committer | Andreas Kling <kling@serenityos.org> | 2022-10-02 21:14:02 +0200 |
commit | 74840c5537e583d99e152d0ac4598f160f3dfb43 (patch) | |
tree | 2a0ddabc460d7e8748c239dd0208b287a1e1c403 /AK | |
parent | 95a3da86c327a7d25c6a85640e98350ab53773f0 (diff) | |
download | serenity-74840c5537e583d99e152d0ac4598f160f3dfb43.zip |
AK: Add more AK_OS_FOO macros, including AK_OS_SERENITY
Diffstat (limited to 'AK')
-rw-r--r-- | AK/Platform.h | 26 |
1 files changed, 25 insertions, 1 deletions
diff --git a/AK/Platform.h b/AK/Platform.h index 1a4e8a2620..5e16ae63bd 100644 --- a/AK/Platform.h +++ b/AK/Platform.h @@ -24,13 +24,37 @@ # define AK_ARCH_32_BIT #endif +#if defined(__serenity__) +# define AK_OS_SERENITY +#endif + +#if defined(__linux__) +# define AK_OS_LINUX +#endif + #if defined(__APPLE__) && defined(__MACH__) # define AK_OS_MACOS # define AK_OS_BSD_GENERIC #endif -#if defined(__FreeBSD__) || defined(__NetBSD__) || defined(__OpenBSD__) || defined(__DragonFly__) +#if defined(__FreeBSD__) +# define AK_OS_BSD_GENERIC +# define AK_OS_FREEBSD +#endif + +#if defined(__NetBSD__) +# define AK_OS_BSD_GENERIC +# define AK_OS_NETBSD +#endif + +#if defined(__OpenBSD__) +# define AK_OS_BSD_GENERIC +# define AK_OS_OPENBSD +#endif + +#if defined(__DragonFly__) # define AK_OS_BSD_GENERIC +# define AK_OS_DRAGONFLY #endif #if defined(_WIN32) || defined(_WIN64) |