Reland "Gyp file changes for the android framework."

Relands https://codereview.chromium.org/153093003/, which was reverted
with https://skia.googlesource.com/skia.git/+/eb6295044b97db05ec40625dcebc2459b2a38a98

This reverts commit 6b32be1402eb6c549d5ba1db71860e24f9de2991.

BUG=skia:1975
R=djsollen@google.com

Review URL: https://codereview.chromium.org/154053002

git-svn-id: http://skia.googlecode.com/svn/trunk@13321 2bbb7eff-a529-9590-31e7-b0007b416f81
diff --git a/gyp/android_deps.gyp b/gyp/android_deps.gyp
index cd5b1b0..1669b2b 100644
--- a/gyp/android_deps.gyp
+++ b/gyp/android_deps.gyp
@@ -14,7 +14,68 @@
 # This is due to the fact that we cannot use variables in an includes as the
 # variable expansion step for gyp happens after the includes are processed.
 {
-  'includes': [
-    '../platform_tools/android/gyp/dependencies.gypi',
+  'conditions': [
+    [ 'skia_android_framework == 0',
+      {
+        'includes': [
+          '../platform_tools/android/gyp/dependencies.gypi',
+        ],
+      }, { # else skia_android_framework
+        'cflags': [
+          '-Wno-error'
+        ],
+        'targets': [
+          {
+            'target_name': 'expat',
+            'type': 'none',
+            'direct_dependent_settings': {
+              'libraries' : [
+                '-lexpat',
+              ],
+            },
+          },
+          {
+            'target_name': 'gif',
+            'type': 'none',
+            'direct_dependent_settings': {
+              'libraries' : [
+                'libgif.a',
+              ],
+              'include_dirs': [
+                'external/giflib',
+              ],
+            },
+          },
+          {
+            'target_name': 'png',
+            'type': 'none',
+            'direct_dependent_settings': {
+              'libraries' : [
+                '-lpng',
+              ],
+              'include_dirs': [
+                'external/libpng',
+              ],
+            },
+          },
+          {
+            'target_name': 'jpeg',
+            'type': 'none',
+            'direct_dependent_settings': {
+              'libraries' : [
+                '-ljpeg',
+              ],
+              'include_dirs': [
+                'external/jpeg',
+              ],
+            },
+          },
+          {
+            'target_name': 'cpu_features',
+            'type': 'none',
+          },
+        ],
+      }
+    ],
   ],
 }