File tree Expand file tree Collapse file tree 3 files changed +25
-2
lines changed Expand file tree Collapse file tree 3 files changed +25
-2
lines changed Original file line number Diff line number Diff line change 1+ //===-- Definition of macros from sys/ioctl.h -----------------------------===//
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_HDR_SYS_IOCTL_MACROS_H
10+ #define LLVM_LIBC_HDR_SYS_IOCTL_MACROS_H
11+
12+ #ifdef LIBC_FULL_BUILD
13+
14+ #include "include/llvm-libc-macros/sys-ioctl-macros.h"
15+
16+ #else // Overlay mode
17+
18+ #include <sys/ioctl.h>
19+
20+ #endif // LLVM_LIBC_FULL_BUILD
21+
22+ #endif // LLVM_LIBC_HDR_SYS_IOCTL_MACROS_H
Original file line number Diff line number Diff line change @@ -9,7 +9,7 @@ add_libc_unittest(
99 SRCS
1010 ioctl_test.cpp
1111 DEPENDS
12- libc.include .sys_ioctl
12+ libc.hdr.ioctl_macros
1313 libc.src.sys.ioctl.ioctl
1414 libc.src.errno.errno
1515 libc.src.fcntl.open
Original file line number Diff line number Diff line change 55// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
66//
77// ===----------------------------------------------------------------------===//
8+
89#include " src/errno/libc_errno.h"
910#include " src/fcntl/open.h"
1011#include " src/sys/ioctl/ioctl.h"
1112#include " src/unistd/close.h"
1213#include " src/unistd/read.h"
1314#include " test/UnitTest/ErrnoSetterMatcher.h"
1415
15- #include < sys/ioctl.h >
16+ #include " hdr/sys_ioctl_macros.h "
1617
1718using LIBC_NAMESPACE::testing::ErrnoSetterMatcher::Fails;
1819using LIBC_NAMESPACE::testing::ErrnoSetterMatcher::Succeeds;
You can’t perform that action at this time.
0 commit comments