Skip to content

Commit 182e059

Browse files
vonosmasgithub-actions[bot]
authored andcommitted
Automerge: [libc][bazel] Set LIBC_ERRNO_MODE_SYSTEM_INLINE by default. (#152946)
Bazel only supports overlay build currently, so there's always system libc (and system errno_ present. Use the new LIBC_ERRNO_MODE_SYSTEM_INLINE by default, instead of using thread-local one in the unit tests and system errno for "public packaging" (i.e. prod build). This way, we can ensure that we're testing the same configuration as the one that will be used in production. This is the second attempt to do that after f9146cc was reverted in 279e82f. Since then, many tests have been migrated to ErrnoCheckingTest so the change should be safe even for those downstream customers that clobber system errno value before unit tests are being called.
2 parents c564c25 + 5ccc734 commit 182e059

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

utils/bazel/llvm-project-overlay/libc/libc_configure_options.bzl

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -49,4 +49,7 @@ LIBC_CONFIGURE_OPTIONS = [
4949

5050
# Documentation in libc/docs/configure.rst
5151
"LIBC_THREAD_MODE=LIBC_THREAD_MODE_PLATFORM",
52+
53+
# Documentation in libc/src/__support/libc_errno.h
54+
"LIBC_ERRNO_MODE=LIBC_ERRNO_MODE_SYSTEM_INLINE",
5255
]

0 commit comments

Comments
 (0)