Index: platform_tools/android/gyp/viewer.gypi |
diff --git a/platform_tools/android/gyp/viewer.gypi b/platform_tools/android/gyp/viewer.gypi |
new file mode 100644 |
index 0000000000000000000000000000000000000000..6d2659b2cbe1f05b810ae84476a99dffa4a7d51c |
--- /dev/null |
+++ b/platform_tools/android/gyp/viewer.gypi |
@@ -0,0 +1,65 @@ |
+# Copyright 2015 Google Inc. |
+# |
+# Use of this source code is governed by a BSD-style license that can be |
+# found in the LICENSE file. |
+{ |
+ 'targets': [ |
+ { |
+ 'target_name': 'CopyViewerDeps', |
+ 'type': 'none', |
+ 'dependencies': [ |
+ 'skia_lib.gyp:skia_lib', |
+ 'viewer.gyp:viewer', |
+ ], |
+ 'copies': [ |
+ { |
+ 'destination': '<(android_base)/apps/viewer/src/main/libs/<(android_arch)', |
+ 'conditions': [ |
+ [ 'skia_shared_lib', { |
+ 'files': [ |
+ '<(SHARED_LIB_DIR)/libskia_android.so', |
+ '<(SHARED_LIB_DIR)/libviewer.so', |
+ ]}, { |
+ 'files': [ |
+ '<(SHARED_LIB_DIR)/libviewer.so', |
+ ]} |
+ ], |
+ ], |
+ }, |
+ ], |
+ }, |
+ { |
+ 'target_name': 'Viewer_APK', |
+ 'type': 'none', |
+ 'dependencies': [ 'CopyViewerDeps', ], |
+ 'actions': [ |
+ { |
+ 'action_name': 'SkiaViewer_apk', |
+ 'inputs': [ |
+ '<(android_base)/apps/viewer/src/main/AndroidManifest.xml', |
+ '<(android_base)/apps/viewer/src/main/java/org/skia/viewer/ViewerActivity.java', |
+ '<(android_base)/apps/viewer/src/main/libs/<(android_arch)/libviewer.so', |
+ |
+ ], |
+ 'conditions': [ |
+ [ 'skia_shared_lib', { |
+ 'inputs': [ |
+ '<(android_base)/apps/viewer/src/main/libs/<(android_arch)/libskia_android.so', |
+ ], |
+ }], |
+ ], |
+ 'outputs': [ |
+ '../apps/viewer/build/outputs/apk/', |
+ ], |
+ 'action': [ |
+ '<(android_base)/apps/gradlew', |
+ ':viewer:assemble<(android_variant)<(android_buildtype)', |
+ '-p<(android_base)/apps/viewer', |
+ '-PsuppressNativeBuild', |
+ '--daemon', |
+ ], |
+ }, |
+ ], |
+ }, |
+ ], |
+} |