Add static python3 launchers for non-glibc targets
Build static versions of the python3 launchers for embedding into
par files that don't want to distribute additional shared library
dependencies.
Bug: 179809553
Test: m USE_HOST_MUSL=true BUILD_HOST_static=1 apexer deapexer
Change-Id: Ibb8baa9246c2edbb91335170a0111655546c4d20
diff --git a/Android.bp b/Android.bp
index db5d4c2..13e7096 100644
--- a/Android.bp
+++ b/Android.bp
@@ -446,6 +446,33 @@
cflags: ["-DANDROID_AUTORUN"],
}
+cc_binary_host {
+ name: "py3-launcher-static",
+ defaults: ["py3-launcher-defaults"],
+ srcs: ["android/launcher_main.cpp"],
+ static_libs: ["py3-launcher-lib"],
+ static_executable: true,
+ target: {
+ glibc: {
+ enabled: false,
+ },
+ },
+}
+
+cc_binary_host {
+ name: "py3-launcher-autorun-static",
+ defaults: ["py3-launcher-defaults"],
+ srcs: ["android/launcher_main.cpp"],
+ static_libs: ["py3-launcher-lib"],
+ static_executable: true,
+ cflags: ["-DANDROID_AUTORUN"],
+ target: {
+ glibc: {
+ enabled: false,
+ },
+ },
+}
+
python_binary_host {
name: "py3-cmd",
autorun: false,