diff options
author | Jonathan Wakely <jwakely@redhat.com> | 2023-09-07 17:03:40 +0100 |
---|---|---|
committer | Jonathan Wakely <jwakely@redhat.com> | 2023-09-07 17:03:40 +0100 |
commit | 5435449be0eb9ca41824eb16f774db3ccc2a593b (patch) | |
tree | c9ccc4204c4e98e79474ae7ce87037ba48627db5 /gcc | |
parent | d295a5341d0cae95c199e0aabcbcde82c6fff0d1 (diff) | |
download | gcc-5435449be0eb9ca41824eb16f774db3ccc2a593b.zip gcc-5435449be0eb9ca41824eb16f774db3ccc2a593b.tar.gz gcc-5435449be0eb9ca41824eb16f774db3ccc2a593b.tar.bz2 |
libstdc++: Add autoconf checks for mkdir, chmod, chdir, and getcwd
The filesystem code was using these functions without checking for their
existence, assuming that any UNIX-like libc with <unistd.h> would always
provide them. That's not true for some newlib targets like arm-eabi.
libstdc++-v3/ChangeLog:
* acinclude.m4 (GLIBCXX_CHECK_FILESYSTEM_DEPS): Check for mkdir,
chmod, chdir, and getcwd.
* config.h.in: Regenerate.
* configure: Regenerate.
* src/c++17/fs_ops.cc (create_dir): Use USE_MKDIR macro.
(fs::current_path): Use USE_GETCWD and USE_CHDIR macros.
(fs::permissions): Use USE_CHMOD macro.
* src/filesystem/ops-common.h [FILESYSTEM_IS_WINDOWS]
(chmod, mkdir, getcwd, chdir): Define new macros.
[FILESYSTEM_IS_WINDOWS] (chmod, mkdir, getcwd, chdir): Use
new macros.
* src/filesystem/ops.cc (create_dir): Use USE_MKDIR macro.
(fs::current_path): Use USE_GETCWD and USE_CHDIR macros.
(fs::permissions): Use USE_CHMOD macro.
Diffstat (limited to 'gcc')
0 files changed, 0 insertions, 0 deletions