Revert "Always build the ANGLE test code. Always build ANGLE on windows and linux."

This reverts commit 238b820369c4b556c2e7c8277855e6950de3d9eb.

Reason for revert: breaks 32-bit bots, iOS bots, Google3 roll, -ASAN bot.

Original change's description:
> Always build the ANGLE test code. Always build ANGLE on windows and linux.
> 
> Make ANGLE test code independent of having ANGLE lib. Make ANGLE test code not include EGL headers.
> 
> GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=4040
> 
> DOCS_PREVIEW= https://skia.org/?cl=4040
> 
> Change-Id: I7b857e9785246743f53fb969647b1162ce7419ab
> Reviewed-on: https://skia-review.googlesource.com/4040
> Commit-Queue: Brian Salomon <bsalomon@google.com>
> Reviewed-by: Mike Klein <mtklein@chromium.org>
> 

TBR=mtklein@chromium.org,mtklein@google.com,bsalomon@google.com,reviews@skia.org
NOPRESUBMIT=true
NOTREECHECKS=true
NOTRY=true

Change-Id: I19bab8c93baebf032f8a4cefbedfe7359317e806
Reviewed-on: https://skia-review.googlesource.com/4758
Commit-Queue: Mike Klein <mtklein@chromium.org>
Reviewed-by: Mike Klein <mtklein@chromium.org>
diff --git a/BUILD.gn b/BUILD.gn
index 64e69e7..dab8918 100644
--- a/BUILD.gn
+++ b/BUILD.gn
@@ -11,6 +11,7 @@
 }
 
 declare_args() {
+  skia_use_angle = false
   skia_use_expat = true
   skia_use_fontconfig = is_linux
   skia_use_freetype = is_android || is_fuchsia || is_linux
@@ -754,7 +755,6 @@
         "tools/gpu/GrTest.cpp",
         "tools/gpu/TestContext.cpp",
         "tools/gpu/gl/GLTestContext.cpp",
-        "tools/gpu/gl/angle/GLTestContext_angle.cpp",
         "tools/gpu/gl/command_buffer/GLTestContext_command_buffer.cpp",
         "tools/gpu/gl/debug/DebugGLTestContext.cpp",
         "tools/gpu/gl/debug/GrBufferObj.cpp",
@@ -774,7 +774,6 @@
         libs += [ "OpenGLES.framework" ]
       } else if (is_linux) {
         sources += [ "tools/gpu/gl/glx/CreatePlatformGLTestContext_glx.cpp" ]
-        deps += [ "//third_party/angle2" ]
       } else if (is_mac) {
         sources += [ "tools/gpu/gl/mac/CreatePlatformGLTestContext_mac.cpp" ]
       } else if (is_win) {
@@ -783,9 +782,13 @@
           "Gdi32.lib",
           "OpenGL32.lib",
         ]
-        deps += [ "//third_party/angle2" ]
       }
 
+      if (skia_use_angle) {
+        public_defines += [ "SK_ANGLE" ]
+        deps += [ "//third_party/angle2" ]
+        sources += [ "tools/gpu/gl/angle/GLTestContext_angle.cpp" ]
+      }
       if (skia_use_mesa) {
         public_defines += [ "SK_MESA" ]
         sources += [ "tools/gpu/gl/mesa/GLTestContext_mesa.cpp" ]
@@ -1100,6 +1103,9 @@
         ":tool_utils",
         ":views",
       ]
+      if (skia_use_angle) {
+        deps += [ "//third_party/angle2" ]
+      }
       testonly = true
     }
   }