diff options
author | Itamar <itamar8910@gmail.com> | 2020-10-10 17:48:27 +0300 |
---|---|---|
committer | Andreas Kling <kling@serenityos.org> | 2020-12-14 23:05:53 +0100 |
commit | 781aa424a9b34917ad4abb1753d7cf7809dea7be (patch) | |
tree | f42bbf620e9a816c5242afdf59576d77c0fce79d /Libraries/LibC/errno.h | |
parent | 65ee2f07b725e8e71c156de8a8741e8e545c8786 (diff) | |
download | serenity-781aa424a9b34917ad4abb1753d7cf7809dea7be.zip |
LibC: Add NO_TLS preprocessor flag
When this flag is defined, LibC does not use TLS.
It will be useful for the dynamic loader.
Diffstat (limited to 'Libraries/LibC/errno.h')
-rw-r--r-- | Libraries/LibC/errno.h | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/Libraries/LibC/errno.h b/Libraries/LibC/errno.h index 2d2a0b334f..f763dbc914 100644 --- a/Libraries/LibC/errno.h +++ b/Libraries/LibC/errno.h @@ -43,7 +43,12 @@ __BEGIN_DECLS extern const char* const sys_errlist[]; extern int sys_nerr; + +#ifdef NO_TLS +extern int errno; +#else extern __thread int errno; +#endif #define errno errno |