Convert bootanimation to Android.bp
See build/soong/README.md for more information.
Test: cd frameworks/base/cmds/bootanimation; mma
Change-Id: I7e023ffc42f61ce9a215a958fbbd158a6a8352d7
diff --git a/cmds/bootanimation/Android.bp b/cmds/bootanimation/Android.bp
new file mode 100644
index 0000000..31bd612
--- /dev/null
+++ b/cmds/bootanimation/Android.bp
@@ -0,0 +1,90 @@
+cc_defaults {
+ name: "bootanimation_defaults",
+
+ cflags: [
+ "-DGL_GLEXT_PROTOTYPES",
+ "-DEGL_EGLEXT_PROTOTYPES",
+
+ "-Wall",
+ "-Werror",
+ "-Wunused",
+ "-Wunreachable-code",
+ ],
+
+ shared_libs: [
+ "libandroidfw",
+ "libbase",
+ "libbinder",
+ "libcutils",
+ "liblog",
+ "libutils",
+ ],
+}
+
+// bootanimation executable
+// =========================================================
+
+cc_binary {
+ name: "bootanimation",
+ defaults: ["bootanimation_defaults"],
+
+ shared_libs: [
+ "libOpenSLES",
+ "libbootanimation",
+ ],
+
+ srcs: [
+ "BootAnimationUtil.cpp",
+
+ "bootanimation_main.cpp",
+ "audioplay.cpp",
+ ],
+
+ product_variables: {
+ product_is_iot: {
+ shared_libs: [
+ "libandroidthings",
+ "libandroidthings_protos",
+ "libchrome",
+ "libprotobuf-cpp-lite",
+ ],
+ static_libs: ["libjsoncpp"],
+ srcs: [
+ "iot/iotbootanimation_main.cpp",
+ "iot/BootAction.cpp",
+ "iot/BootParameters.cpp",
+ ],
+ exclude_srcs: [
+ "bootanimation_main.cpp",
+ "audioplay.cpp",
+ ],
+ },
+ },
+
+ init_rc: ["bootanim.rc"],
+}
+
+// libbootanimation
+// ===========================================================
+
+cc_library_shared {
+ name: "libbootanimation",
+ defaults: ["bootanimation_defaults"],
+
+ srcs: ["BootAnimation.cpp"],
+
+ shared_libs: [
+ "libui",
+ "libhwui",
+ "libEGL",
+ "libGLESv1_CM",
+ "libgui",
+ "libtinyalsa",
+ ],
+
+ product_variables: {
+ product_is_iot: {
+ init_rc: ["iot/bootanim_iot.rc"],
+ },
+ },
+}