Update android_make to support both --gcc and --clang options.

This CL also fixes all the errors that resulted from compiling
with clang and ccache.

BUG=skia:4948
GOLD_TRYBOT_URL= https://gold.skia.org/search2?unt=true&query=source_type%3Dgm&master=false&issue=1774503004

Review URL: https://codereview.chromium.org/1774503004
diff --git a/gyp/codec.gyp b/gyp/codec.gyp
index e96aaed..81b28fe 100644
--- a/gyp/codec.gyp
+++ b/gyp/codec.gyp
@@ -24,7 +24,7 @@
       ],
       'cflags':[   
         # FIXME: This gets around a warning: "Argument might be clobbered by longjmp". 
-        '-Wno-clobbered -Wno-error',   
+        '-Wno-clobbered -Wno-error',
       ],
       'include_dirs': [
         '../include/codec',
diff --git a/gyp/common_conditions.gypi b/gyp/common_conditions.gypi
index 2c04ea3..bfdbb9e 100644
--- a/gyp/common_conditions.gypi
+++ b/gyp/common_conditions.gypi
@@ -656,6 +656,15 @@
           [ 'skia_profile_enabled == 1', {
             'cflags': ['-g', '-fno-omit-frame-pointer', '-marm', '-mapcs'],
           }],
+          [ 'skia_clang_build', {
+            'cflags': [
+                '-Wno-unknown-warning-option', # Allows unknown warnings
+                # These flags that are on by default for only the android
+                # toolchain and no other platforms.
+                '-Wno-tautological-compare',
+                '-Wno-unused-command-line-argument',
+            ],
+          }],
         ],
       },
     ],
diff --git a/gyp/freetype.gyp b/gyp/freetype.gyp
index 94ab94c..f282f77 100644
--- a/gyp/freetype.gyp
+++ b/gyp/freetype.gyp
@@ -102,6 +102,11 @@
             '-O2',
           ],
         }],
+        [ 'skia_clang_build == 1', {
+          'cflags':[
+            '-Wno-error',
+          ],
+        }],
       ],
     },
   ],
diff --git a/gyp/lua.gyp b/gyp/lua.gyp
index e030ffe..5b160eb 100644
--- a/gyp/lua.gyp
+++ b/gyp/lua.gyp
@@ -67,6 +67,11 @@
             ],
           }
         ],
+        [ 'skia_clang_build == 1', {
+          'cflags':[
+            '-Wno-error',
+          ],
+        }],
       ],
     },
   ],