diff --git a/runtime/bin/fdutils_android.cc b/runtime/bin/fdutils_android.cc index 8d946e68677..18b4ec39a52 100644 --- a/runtime/bin/fdutils_android.cc +++ b/runtime/bin/fdutils_android.cc @@ -2,10 +2,13 @@ // for details. All rights reserved. Use of this source code is governed by a // BSD-style license that can be found in the LICENSE file. -#include -#include -#include -#include +#include "platform/globals.h" +#if defined(TARGET_OS_ANDROID) + +#include // NOLINT +#include // NOLINT +#include // NOLINT +#include // NOLINT #include "bin/fdutils.h" @@ -132,3 +135,5 @@ ssize_t FDUtils::WriteToBlocking(int fd, const void* buffer, size_t count) { } return count; } + +#endif // defined(TARGET_OS_ANDROID) diff --git a/runtime/bin/fdutils_linux.cc b/runtime/bin/fdutils_linux.cc index 8d946e68677..84c21941b07 100644 --- a/runtime/bin/fdutils_linux.cc +++ b/runtime/bin/fdutils_linux.cc @@ -2,10 +2,13 @@ // for details. All rights reserved. Use of this source code is governed by a // BSD-style license that can be found in the LICENSE file. -#include -#include -#include -#include +#include "platform/globals.h" +#if defined(TARGET_OS_LINUX) + +#include // NOLINT +#include // NOLINT +#include // NOLINT +#include // NOLINT #include "bin/fdutils.h" @@ -132,3 +135,5 @@ ssize_t FDUtils::WriteToBlocking(int fd, const void* buffer, size_t count) { } return count; } + +#endif // defined(TARGET_OS_LINUX) diff --git a/runtime/bin/fdutils_macos.cc b/runtime/bin/fdutils_macos.cc index 92e63fcefd5..7087add7b2e 100644 --- a/runtime/bin/fdutils_macos.cc +++ b/runtime/bin/fdutils_macos.cc @@ -2,10 +2,13 @@ // for details. All rights reserved. Use of this source code is governed by a // BSD-style license that can be found in the LICENSE file. -#include -#include -#include -#include +#include "platform/globals.h" +#if defined(TARGET_OS_MACOS) + +#include // NOLINT +#include // NOLINT +#include // NOLINT +#include // NOLINT #include "bin/fdutils.h" @@ -133,3 +136,5 @@ ssize_t FDUtils::WriteToBlocking(int fd, const void* buffer, size_t count) { } return count; } + +#endif // defined(TARGET_OS_MACOS)