Revert "Reland: [infra] Roll buildtools to c72a1c5aadde06505b7bb4641720880f3db28ff9"

This reverts commit 03ff9509220a228544c8ad2667eb3d091f96b98b.

Reason for revert: Race in update script.

Original change's description:
> Reland: [infra] Roll buildtools to c72a1c5aadde06505b7bb4641720880f3db28ff9
> 
> Fixes Android build
> 
> Change-Id: Ifcdf492a636bd2c683be8f37bcad4a2af09fb822
> Reviewed-on: https://dart-review.googlesource.com/c/85404
> Reviewed-by: Ryan Macnak <rmacnak@google.com>
> Commit-Queue: Zach Anderson <zra@google.com>

TBR=rmacnak@google.com,zra@google.com

Change-Id: I030425cba496d17383cdda37b0e67dff55f1f7fd
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Reviewed-on: https://dart-review.googlesource.com/c/85409
Reviewed-by: Zach Anderson <zra@google.com>
Commit-Queue: Zach Anderson <zra@google.com>
diff --git a/DEPS b/DEPS
index 717b628..b83815d 100644
--- a/DEPS
+++ b/DEPS
@@ -42,7 +42,7 @@
   # Fuchsia. This revision should be kept up to date with the revision pulled
   # by the Flutter engine. If there are problems with the toolchain, contact
   # fuchsia-toolchain@.
-  "buildtools_revision": "9e69ccfa6c1d3d9d3d0498c2b73338c169ed4377",
+  "buildtools_revision": "446d5b1019dcbe7835236dc85261e91cf29a9239",
 
   # Scripts that make 'git cl format' work.
   "clang_format_scripts_rev": "c09c8deeac31f05bd801995c475e7c8070f9ecda",
diff --git a/build/config/android/config.gni b/build/config/android/config.gni
index d59c7ee..a6dcf78 100644
--- a/build/config/android/config.gni
+++ b/build/config/android/config.gni
@@ -63,18 +63,18 @@
   # Subdirectories inside android_ndk_root that contain the sysroot for the
   # associated platform.
   if (current_cpu == "x64" || current_cpu == "arm64") {
-    android_api_level = 22
+    _android_api_level = 22
   } else {
-    android_api_level = 16
+    _android_api_level = 16
   }
   x86_android_sysroot_subdir =
-      "platforms/android-${android_api_level}/arch-x86"
+      "platforms/android-${_android_api_level}/arch-x86"
   arm_android_sysroot_subdir =
-      "platforms/android-${android_api_level}/arch-arm"
+      "platforms/android-${_android_api_level}/arch-arm"
   x86_64_android_sysroot_subdir =
-      "platforms/android-${android_api_level}/arch-x86_64"
+      "platforms/android-${_android_api_level}/arch-x86_64"
   arm64_android_sysroot_subdir =
-      "platforms/android-${android_api_level}/arch-arm64"
+      "platforms/android-${_android_api_level}/arch-arm64"
 
   # Toolchain root directory for each build. The actual binaries are inside
   # a "bin" directory inside of these.
@@ -90,29 +90,25 @@
   # like the toolchain roots.
   if (current_cpu == "x86") {
     android_prebuilt_arch = "android-x86"
-    android_target_triple = "i686-linux-android"
+    _binary_prefix = "i686-linux-android"
     android_toolchain_root = "$x86_android_toolchain_root"
-    android_sysroot_subdir = "$x86_android_sysroot_subdir"
   } else if (current_cpu == "arm") {
     android_prebuilt_arch = "android-arm"
-    android_target_triple = "arm-linux-androideabi"
+    _binary_prefix = "arm-linux-androideabi"
     android_toolchain_root = "$arm_android_toolchain_root"
-    android_sysroot_subdir = "$arm_android_sysroot_subdir"
   } else if (current_cpu == "x64") {
     android_prebuilt_arch = "android-x86_64"
-    android_target_triple = "x86_64-linux-android"
+    _binary_prefix = "x86_64-linux-android"
     android_toolchain_root = "$x86_64_android_toolchain_root"
-    android_sysroot_subdir = "$x86_64_android_sysroot_subdir"
   } else if (current_cpu == "arm64") {
     android_prebuilt_arch = "android-arm64"
-    android_target_triple = "aarch64-linux-android"
+    _binary_prefix = "aarch64-linux-android"
     android_toolchain_root = "$arm64_android_toolchain_root"
-    android_sysroot_subdir = "$arm64_android_sysroot_subdir"
   } else {
     assert(false, "Need android libgcc support for your target arch.")
   }
 
-  android_tool_prefix = "$android_toolchain_root/bin/$android_target_triple-"
+  android_tool_prefix = "$android_toolchain_root/bin/$_binary_prefix-"
   android_readelf = "${android_tool_prefix}readelf"
   android_objcopy = "${android_tool_prefix}objcopy"
   android_gdbserver =
diff --git a/build/config/compiler/BUILD.gn b/build/config/compiler/BUILD.gn
index b8f4c62..4bdcda6 100644
--- a/build/config/compiler/BUILD.gn
+++ b/build/config/compiler/BUILD.gn
@@ -246,14 +246,11 @@
     ldflags += [ "-pthread" ]
     if (is_clang) {
       if (current_cpu == "arm") {
-        cflags += [ "--target=armv7-linux-gnueabihf" ]
-        ldflags += [ "--target=armv7-linux-gnueabihf" ]
+        cflags += [ "--target=arm-linux-gnueabihf" ]
+        ldflags += [ "--target=arm-linux-gnueabihf" ]
       } else if (current_cpu == "arm64") {
         cflags += [ "--target=aarch64-linux-gnu" ]
         ldflags += [ "--target=aarch64-linux-gnu" ]
-      } else if (current_cpu == "x86") {
-        cflags += [ "--target=i386-linux-gnu" ]
-        ldflags += [ "--target=i386-linux-gnu" ]
       }
     }
   }
@@ -281,7 +278,6 @@
       "-ffunction-sections",
       "-funwind-tables",
       "-fno-short-enums",
-      "-nostdinc++",
     ]
     if (!is_clang) {
       # Clang doesn't support these flags.
@@ -448,17 +444,14 @@
     # strange errors. The include ordering here is important; change with
     # caution.
     cflags += [
-      "-isystem" + rebase_path("$android_libcpp_root/include", root_build_dir),
+      "-isystem" +
+          rebase_path("$android_libcpp_root/libcxx/include", root_build_dir),
       "-isystem" + rebase_path(
-              "$android_ndk_root/sources/cxx-stl/llvm-libc++abi/include",
+              "$android_ndk_root/sources/cxx-stl/llvm-libc++abi/libcxxabi/include",
               root_build_dir),
       "-isystem" +
           rebase_path("$android_ndk_root/sources/android/support/include",
                       root_build_dir),
-      "-isystem" + rebase_path(
-              "$android_ndk_root/sysroot/usr/include/$android_target_triple",
-              root_build_dir),
-      "-D__ANDROID_API__=$android_api_level",
     ]
 
     lib_dirs += [ "$android_libcpp_root/libs/$android_app_abi" ]
@@ -699,7 +692,7 @@
       "-Wl,--gc-sections",
     ]
 
-    if (is_clang && !using_sanitizer) {
+    if (is_clang) {
       # Identical code folding to reduce size.
       # Warning: This changes C/C++ semantics of function pointer comparison.
       common_optimize_on_ldflags += [ "-Wl,--icf=all" ]
diff --git a/tools/buildtools/update.py b/tools/buildtools/update.py
index 63de42b..5cae6a8 100755
--- a/tools/buildtools/update.py
+++ b/tools/buildtools/update.py
@@ -24,7 +24,7 @@
 
 def Update():
   path = os.path.join(BUILDTOOLS, 'update.sh')
-  command = ['/bin/bash', path, '--clang', '--gn', '--ninja']
+  command = ['/bin/bash', path, '--clang', '--gn']
   return subprocess.call(command, cwd=DART_ROOT)