Book a Demo!
CoCalc Logo Icon
StoreFeaturesDocsShareSupportNewsAboutPoliciesSign UpSign In
emscripten-core
GitHub Repository: emscripten-core/emscripten
Path: blob/main/system/lib/llvm-libc/shared/libc_common.h
6169 views
1
//===-- Common defines for sharing LLVM libc with LLVM projects -*- C++ -*-===//
2
//
3
// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
4
// See https://llvm.org/LICENSE.txt for license information.
5
// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
6
//
7
//===----------------------------------------------------------------------===//
8
9
#ifndef LLVM_LIBC_SHARED_LIBC_COMMON_H
10
#define LLVM_LIBC_SHARED_LIBC_COMMON_H
11
12
// Use system errno.
13
#ifdef LIBC_ERRNO_MODE
14
#if LIBC_ERRNO_MODE != LIBC_ERRNO_MODE_SYSTEM_INLINE
15
#error \
16
"LIBC_ERRNO_MODE was set to something different from LIBC_ERRNO_MODE_SYSTEM_INLINE."
17
#endif // LIBC_ERRNO_MODE != LIBC_ERRNO_MODE_SYSTEM_INLINE
18
#else
19
#define LIBC_ERRNO_MODE LIBC_ERRNO_MODE_SYSTEM_INLINE
20
#endif // LIBC_ERRNO_MODE
21
22
#ifndef LIBC_NAMESPACE
23
#define LIBC_NAMESPACE __llvm_libc
24
#endif // LIBC_NAMESPACE
25
26
#endif // LLVM_LIBC_SHARED_LIBC_COMMON_H
27
28