/* SPDX-License-Identifier: LGPL-2.1-only */ /* * The Rin Library – various compatibility constructs * * Copyright (C) 2019 Gediminas Jakutis */ #ifndef LIBRIN_COMPAT_INCLUDED #define LIBRIN_COMPAT_INCLUDED #ifdef RIN_NEED_GETTID #include # ifdef __GLIBC__ # if __GLIBC__ > 2 || (__GLIBC__ == 2 && __GLIBC_MINOR__ > 29) # include # else # include # define gettid() (syscall(SYS_gettid)) # endif # endif #endif /* RIN_NEED_GETTID */ #endif /* LIBRIN_COMPAT_INCLUDED */