[libc-commits] [libc] [libc] Add the get and set sys/xattr.h entrypoints. (PR #224729)
Alex Strelnikov via libc-commits
libc-commits at lists.llvm.org
Tue Sep 22 07:38:14 PDT 2026
================
@@ -0,0 +1,20 @@
+//===----------------------------------------------------------------------===//
+//
+// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
+// See https://llvm.org/LICENSE.txt for license information.
+// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
+//
+//===----------------------------------------------------------------------===//
+///
+/// \file
+/// Linux specific declarations of macros from sys/xattr.h.
+///
+//===----------------------------------------------------------------------===//
+
+#ifndef LLVM_LIBC_MACROS_LINUX_SYS_XATTR_MACROS_H
+#define LLVM_LIBC_MACROS_LINUX_SYS_XATTR_MACROS_H
+
+#define XATTR_CREATE 1
----------------
strel-12 wrote:
Could you please help me better understand the intended setup?
Do you mean adding `macro_value` in include/sys/xattr.yaml or creating an include/llvm-libc-proxy/xattr_proxy.yaml instead of this header? If the former, what is the expected way to use these macros in a unit test, including <sys/xattr.h>?
I tried looking around for existing `macro_value` usage, and I saw include/llvm-libc-proxy/elf_proxy.yaml and uses in top level include/ yaml files, but I could not yet find one that is also used in a unit test.
https://github.com/llvm/llvm-project/pull/224729
More information about the libc-commits
mailing list