[libc] [llvm] [libc][c11] Add stdio.h's rename() function (PR #85068)

Nick Desaulniers via llvm-commits llvm-commits at lists.llvm.org
Thu Mar 21 08:30:31 PDT 2024


nickdesaulniers wrote:

Looks like the aarch64 buildbot [is failing](https://lab.llvm.org/buildbot/#/builders/138/builds/62609/steps/4/logs/stdio) with:
```
llvm-project/libc/src/stdio/linux/rename.cpp:18:47: error: use of undeclared identifier 'SYS_rename'
  int ret = LIBC_NAMESPACE::syscall_impl<int>(SYS_rename, oldpath, newpath);
                                              ^
```
The the fullbuild buildbots [are failing to build the test](https://lab.llvm.org/buildbot/#/builders/163/builds/53432/steps/8/logs/stdio):
```
llvm-project/libc/test/src/stdio/rename_test.cpp:27:69: error: use of undeclared identifier 'S_IRWXU'
  int fd = LIBC_NAMESPACE::open(TEST_FILEPATH0, O_WRONLY | O_CREAT, S_IRWXU);
                                                                    ^
/home/llvm-libc-buildbot/buildbot-worker/libc-x86_64-debian-fullbuild/libc-x86_64-debian-fullbuild-dbg/llvm-project/libc/test/src/stdio/rename_test.cpp:31:54: error: use of undeclared identifier 'F_OK'
  ASSERT_THAT(LIBC_NAMESPACE::access(TEST_FILEPATH0, F_OK), Succeeds(0));
                                                     ^
/home/llvm-libc-buildbot/buildbot-worker/libc-x86_64-debian-fullbuild/libc-x86_64-debian-fullbuild-dbg/llvm-project/libc/test/src/stdio/rename_test.cpp:37:54: error: use of undeclared identifier 'F_OK'
  ASSERT_THAT(LIBC_NAMESPACE::access(TEST_FILEPATH1, F_OK), Succeeds(0));
                                                     ^
/home/llvm-libc-buildbot/buildbot-worker/libc-x86_64-debian-fullbuild/libc-x86_64-debian-fullbuild-dbg/llvm-project/libc/test/src/stdio/rename_test.cpp:38:54: error: use of undeclared identifier 'F_OK'
  ASSERT_THAT(LIBC_NAMESPACE::access(TEST_FILEPATH0, F_OK), Fails(ENOENT));
                                                     ^
```

https://github.com/llvm/llvm-project/pull/85068


More information about the llvm-commits mailing list