summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSasha Smundak <asmundak@google.com>2019-01-08 14:33:14 -0800
committerSasha Smundak <asmundak@google.com>2019-01-10 10:32:28 -0800
commit35ff6fbf695df506f0e42705ced40d3ce5e41af8 (patch)
tree7c0764d46d1f1218efc9f01308f58c31f9cb22e4
parentbaf1738747e5db125b0e3c8bf43c3101f80b5e25 (diff)
downloadCallLogProvider-35ff6fbf695df506f0e42705ced40d3ce5e41af8.tar.gz
Convert Android.mk file to Android.bp.
See build/soong/README.md for more information. Bug: 122333223 Test: treehugger Change-Id: I9171a0348eeb49567d32daa7ee10225edfcf14fd
-rw-r--r--Android.bp21
-rw-r--r--Android.mk26
-rw-r--r--tests/Android.bp16
-rw-r--r--tests/Android.mk22
4 files changed, 37 insertions, 48 deletions
diff --git a/Android.bp b/Android.bp
new file mode 100644
index 0000000..9da72a0
--- /dev/null
+++ b/Android.bp
@@ -0,0 +1,21 @@
+android_app {
+ name: "CallLogBackup",
+ // Only compile source java files in this apk.
+ srcs: ["src/**/*.java"],
+
+ // The Jacoco tool analyzes code coverage when running unit tests on the
+ // application. This configuration line selects which packages will be analyzed,
+ // leaving out code which is tested by other means (e.g. static libraries) that
+ // would dilute the coverage results. These options do not affect regular
+ // production builds.
+ jacoco: {
+ include_filter: ["com.android.calllogbackup.*"],
+ },
+ platform_apis: true,
+ certificate: "shared",
+ privileged: true,
+ optimize: {
+ proguard_flags_files: ["proguard.flags"],
+ },
+
+}
diff --git a/Android.mk b/Android.mk
deleted file mode 100644
index 0191d87..0000000
--- a/Android.mk
+++ /dev/null
@@ -1,26 +0,0 @@
-LOCAL_PATH:= $(call my-dir)
-include $(CLEAR_VARS)
-
-LOCAL_MODULE_TAGS := optional
-
-# Only compile source java files in this apk.
-LOCAL_SRC_FILES := $(call all-java-files-under, src)
-
-# The Jacoco tool analyzes code coverage when running unit tests on the
-# application. This configuration line selects which packages will be analyzed,
-# leaving out code which is tested by other means (e.g. static libraries) that
-# would dilute the coverage results. These options do not affect regular
-# production builds.
-LOCAL_JACK_COVERAGE_INCLUDE_FILTER := com.android.calllogbackup.*
-
-LOCAL_PACKAGE_NAME := CallLogBackup
-LOCAL_PRIVATE_PLATFORM_APIS := true
-LOCAL_CERTIFICATE := shared
-LOCAL_PRIVILEGED_MODULE := true
-
-LOCAL_PROGUARD_FLAG_FILES := proguard.flags
-
-include $(BUILD_PACKAGE)
-
-# Use the following include to make our test apk.
-include $(call all-makefiles-under,$(LOCAL_PATH))
diff --git a/tests/Android.bp b/tests/Android.bp
new file mode 100644
index 0000000..a9944dd
--- /dev/null
+++ b/tests/Android.bp
@@ -0,0 +1,16 @@
+android_test {
+ name: "CallLogBackupTests",
+ static_libs: ["mockito-target"],
+ libs: [
+ "android.test.runner",
+ "android.test.base",
+ ],
+ // Only compile source java files in this apk.
+ srcs: ["src/**/*.java"],
+ platform_apis: true,
+ instrumentation_for: "CallLogBackup",
+ certificate: "shared",
+ optimize: {
+ enabled: false,
+ },
+}
diff --git a/tests/Android.mk b/tests/Android.mk
deleted file mode 100644
index 8741795..0000000
--- a/tests/Android.mk
+++ /dev/null
@@ -1,22 +0,0 @@
-LOCAL_PATH:= $(call my-dir)
-include $(CLEAR_VARS)
-
-# We only want this apk build for tests.
-LOCAL_MODULE_TAGS := tests
-
-LOCAL_STATIC_JAVA_LIBRARIES := mockito-target
-
-LOCAL_JAVA_LIBRARIES := android.test.runner android.test.base
-
-# Only compile source java files in this apk.
-LOCAL_SRC_FILES := $(call all-java-files-under, src)
-
-LOCAL_PACKAGE_NAME := CallLogBackupTests
-LOCAL_PRIVATE_PLATFORM_APIS := true
-
-LOCAL_INSTRUMENTATION_FOR := CallLogBackup
-LOCAL_CERTIFICATE := shared
-
-LOCAL_PROGUARD_ENABLED := disabled
-
-include $(BUILD_PACKAGE)