mirror of
https://github.com/Evolution-X/hardware_interfaces
synced 2026-02-01 16:50:18 +00:00
Merge "Use std::filesystem when libc++ is new enough" into main am: 37d5948144 am: 608781cfd7 am: 81bff7712e am: 85adb929d3
Original change: https://android-review.googlesource.com/c/platform/hardware/interfaces/+/2758145 Change-Id: I8fd69afb24840a54a631fb9bd65f3bb6d5fcbc8d Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
This commit is contained in:
@@ -9,6 +9,18 @@
|
|||||||
//===----------------------------------------------------------------------===//
|
//===----------------------------------------------------------------------===//
|
||||||
#ifndef _LIBAUTO_FILESYSTEM
|
#ifndef _LIBAUTO_FILESYSTEM
|
||||||
#define _LIBAUTO_FILESYSTEM
|
#define _LIBAUTO_FILESYSTEM
|
||||||
|
|
||||||
|
// TODO(152067309): Remove this once the libc++ upgrade is complete.
|
||||||
|
#include <__config>
|
||||||
|
#if defined(_LIBCPP_VERSION) && _LIBCPP_VERSION > 8000
|
||||||
|
|
||||||
|
#include <filesystem>
|
||||||
|
namespace android::hardware::automotive {
|
||||||
|
namespace filesystem = std::filesystem;
|
||||||
|
}
|
||||||
|
|
||||||
|
#else
|
||||||
|
|
||||||
/*
|
/*
|
||||||
filesystem synopsis
|
filesystem synopsis
|
||||||
|
|
||||||
@@ -2696,4 +2708,6 @@ end(const recursive_directory_iterator&) noexcept {
|
|||||||
|
|
||||||
_LIBCPP_POP_MACROS
|
_LIBCPP_POP_MACROS
|
||||||
|
|
||||||
|
#endif // defined(_LIBCPP_VERSION) && _LIBCPP_VERSION > 8000
|
||||||
|
|
||||||
#endif // _LIBAUTO_FILESYSTEM
|
#endif // _LIBAUTO_FILESYSTEM
|
||||||
|
|||||||
@@ -6,9 +6,15 @@
|
|||||||
// Source Licenses. See LICENSE.TXT for details.
|
// Source Licenses. See LICENSE.TXT for details.
|
||||||
//
|
//
|
||||||
//===----------------------------------------------------------------------===//
|
//===----------------------------------------------------------------------===//
|
||||||
|
|
||||||
|
// TODO(152067309): Remove this once the libc++ upgrade is complete.
|
||||||
|
#include <__config>
|
||||||
|
#if defined(_LIBCPP_VERSION) && _LIBCPP_VERSION <= 8000
|
||||||
|
|
||||||
/* clang-format off */
|
/* clang-format off */
|
||||||
#include "automotive/filesystem"
|
#include "automotive/filesystem"
|
||||||
#include <__config>
|
#include <__config>
|
||||||
|
|
||||||
#if defined(_LIBCPP_WIN32API)
|
#if defined(_LIBCPP_WIN32API)
|
||||||
#define WIN32_LEAN_AND_MEAN
|
#define WIN32_LEAN_AND_MEAN
|
||||||
#include <Windows.h>
|
#include <Windows.h>
|
||||||
@@ -395,3 +401,5 @@ bool recursive_directory_iterator::__try_recursion(error_code* ec) {
|
|||||||
|
|
||||||
} // namespace android::hardware::automotive::filesystem
|
} // namespace android::hardware::automotive::filesystem
|
||||||
/* clang-format on */
|
/* clang-format on */
|
||||||
|
|
||||||
|
#endif // defined(_LIBCPP_VERSION) && _LIBCPP_VERSION <= 8000
|
||||||
|
|||||||
@@ -6,6 +6,11 @@
|
|||||||
// Source Licenses. See LICENSE.TXT for details.
|
// Source Licenses. See LICENSE.TXT for details.
|
||||||
//
|
//
|
||||||
//===----------------------------------------------------------------------===//
|
//===----------------------------------------------------------------------===//
|
||||||
|
|
||||||
|
// TODO(152067309): Remove this once the libc++ upgrade is complete.
|
||||||
|
#include <__config>
|
||||||
|
#if defined(_LIBCPP_VERSION) && _LIBCPP_VERSION <= 8000
|
||||||
|
|
||||||
/* clang-format off */
|
/* clang-format off */
|
||||||
#include "automotive/filesystem"
|
#include "automotive/filesystem"
|
||||||
#include <array>
|
#include <array>
|
||||||
@@ -1771,3 +1776,5 @@ error_code directory_entry::__do_refresh() noexcept {
|
|||||||
#endif
|
#endif
|
||||||
} // namespace android::hardware::automotive::filesystem
|
} // namespace android::hardware::automotive::filesystem
|
||||||
/* clang-format on */
|
/* clang-format on */
|
||||||
|
|
||||||
|
#endif // defined(_LIBCPP_VERSION) && _LIBCPP_VERSION <= 8000
|
||||||
|
|||||||
Reference in New Issue
Block a user