summaryrefslogtreecommitdiff
path: root/Android.bp
diff options
context:
space:
mode:
authorDan Willemsen <dwillemsen@google.com>2016-07-26 15:29:22 -0700
committerDan Willemsen <dwillemsen@google.com>2016-07-26 15:29:22 -0700
commit83b10fcb4487b9cb3df87a5311637a3efc37ac86 (patch)
treeedbfaa0076b39d834ecbc6c153384886c8d8aa94 /Android.bp
parentb9805a57ce1ef5cd9c1668316a2c71e0aaa50291 (diff)
downloadexpat-83b10fcb4487b9cb3df87a5311637a3efc37ac86.tar.gz
Convert Android.mk to Android.bp
This also renames the host module name from libexpat-host to libexpat. The underlying library is still libexpat-host.so. Change-Id: I21eb727bc978ffff79b799b7cae049fddf803f3c
Diffstat (limited to 'Android.bp')
-rw-r--r--Android.bp37
1 files changed, 37 insertions, 0 deletions
diff --git a/Android.bp b/Android.bp
new file mode 100644
index 00000000..f2a6165d
--- /dev/null
+++ b/Android.bp
@@ -0,0 +1,37 @@
+// We need to build this for both the device (as a shared library)
+// and the host (as a static library for tools to use).
+
+cc_library {
+ name: "libexpat",
+ host_supported: true,
+ unique_host_soname: true,
+ sdk_version: "9",
+
+ srcs: [
+ "lib/xmlparse.c",
+ "lib/xmlrole.c",
+ "lib/xmltok.c",
+ ],
+ cflags: [
+ "-Wall",
+ "-Wmissing-prototypes",
+ "-Wstrict-prototypes",
+ "-Wno-unused-parameter",
+ "-Wno-missing-field-initializers",
+ "-fexceptions",
+ "-DHAVE_EXPAT_CONFIG_H",
+ ],
+
+ target: {
+ darwin: {
+ cflags: ["-fno-common"],
+ },
+
+ windows: {
+ enabled: true,
+ },
+ },
+
+ local_include_dirs: ["lib"],
+ export_include_dirs: ["lib"],
+}