Merge "ATest: Add atest as a build target"
diff --git a/atest/Android.bp b/atest/Android.bp
index 5080f5f..a53d3f9 100644
--- a/atest/Android.bp
+++ b/atest/Android.bp
@@ -27,6 +27,22 @@
     },
 }
 
+// Remove this defaults after python3 migration is finished.
+python_defaults {
+    name: "atest_py2_default",
+    pkg_path: "atest",
+    version: {
+        py2: {
+            enabled: true,
+            embedded_launcher: false,
+        },
+        py3: {
+            enabled: false,
+            embedded_launcher: false,
+        },
+    },
+}
+
 python_binary_host {
     name: "atest",
     main: "atest.py",
@@ -37,7 +53,7 @@
         "*_unittest.py",
         "*/*_unittest.py",
     ],
-    defaults: ["py2_only"],
+    defaults: ["atest_py2_default"],
 }
 
 python_library_host {
diff --git a/atest/Android.mk b/atest/Android.mk
new file mode 100644
index 0000000..09c1b05
--- /dev/null
+++ b/atest/Android.mk
@@ -0,0 +1,16 @@
+#
+# Copyright 2018 - The Android Open Source Project
+#
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+#     http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+
+$(call dist-for-goals,droidcore,$(HOST_OUT_EXECUTABLES)/atest)