blob: 21e5861880152201a9a65599d64fba2bf6ae5671 [file] [log] [blame]
Bob Badour228c8542021-02-11 17:35:17 -08001package {
2 default_applicable_licenses: ["external_tinyxml2_license"],
3}
4
5license {
6 name: "external_tinyxml2_license",
7 visibility: [":__subpackages__"],
8 license_kinds: [
9 "SPDX-license-identifier-BSD",
10 "SPDX-license-identifier-MIT",
11 "SPDX-license-identifier-Zlib",
12 "legacy_unencumbered",
13 ],
14 license_text: [
15 "LICENSE.txt",
16 "NOTICE",
17 ],
18}
19
20// The jquery stuff in docs/ is a bit ambiguous with its use of and/or when talking about the GPL,
21// so let's just make it clear that we don't use any of that stuff anyway...
22license {
23 name: "external_tinyxml2_docs_license",
24 license_kinds: ["SPDX-license-identifier-GPL"],
25 license_text: [
26 "LICENSE.txt",
27 "NOTICE",
28 ],
29}
30// ...and prevent anyone from trying to do so:
31filegroup {
32 name: "external_tinyxml2_docs",
33 srcs: ["docs/**/*"],
34 visibility: ["//visibility:private"],
35}
36
Jaekyun Seok4aef71b2016-11-29 06:50:26 +090037cc_library {
Colin Crossda559c72016-07-12 11:12:29 -070038 name: "libtinyxml2",
39 host_supported: true,
Jayant Chowdhary5c495c42017-05-16 14:22:14 -070040 vendor_available: true,
Justin Yuna5642532020-11-11 18:26:17 +090041 product_available: true,
Yifan Honga3503842018-07-16 15:20:06 -070042 recovery_available: true,
Justin Yund3ab2742017-07-24 15:19:44 +090043 vndk: {
44 enabled: true,
45 },
Colin Crossda559c72016-07-12 11:12:29 -070046
47 srcs: ["tinyxml2.cpp"],
48
Elliott Hughes5e6f75e2018-01-12 13:01:08 -080049 cflags: [
50 "-Wall",
51 "-Werror",
Chih-Hung Hsiehf6dd7be2018-09-04 14:33:39 -070052 "-Wno-implicit-fallthrough",
53 // tinyxml2.cpp line 436, 441, 446 have -Wimplicit-fallthrough.
Elliott Hughes5e6f75e2018-01-12 13:01:08 -080054 ],
Chih-Hung Hsieh664df7a2017-09-29 11:31:57 -070055
Steven Morelande5ae2992017-07-14 11:54:16 -070056 shared_libs: ["liblog"],
57
Colin Crossda559c72016-07-12 11:12:29 -070058 target: {
59 android: {
60 cflags: [
61 // LOG_TO_ANDROID_LOGCAT
62 "-DDEBUG",
63 "-DANDROID_NDK",
64 ],
65 },
66 },
Elliott Hughes657af2b2016-09-12 15:34:42 -070067
68 export_include_dirs: ["."],
Sorin Basca6c0d2ff2021-05-27 12:35:35 +000069
70 min_sdk_version: "S",
71
72 apex_available: [
73 "com.android.art",
74 "com.android.art.debug",
William Escandeae08b202022-03-02 20:25:45 +010075 "com.android.bluetooth",
Sorin Basca6c0d2ff2021-05-27 12:35:35 +000076 "//apex_available:platform", // For odsign.
77 ],
Colin Crossda559c72016-07-12 11:12:29 -070078}
Elliott Hughes5e6f75e2018-01-12 13:01:08 -080079
80cc_test {
Elliott Hughes5bd35122020-10-22 16:48:49 -070081 name: "tinyxml2-xmltest",
Elliott Hughes5e6f75e2018-01-12 13:01:08 -080082 srcs: ["xmltest.cpp"],
83 shared_libs: ["libtinyxml2"],
Elliott Hughes5e6f75e2018-01-12 13:01:08 -080084 data: [
Elliott Hughesfc1d7242018-04-25 12:19:39 -070085 "resources/**/*",
Elliott Hughes5e6f75e2018-01-12 13:01:08 -080086 ],
87}
Elliott Hughes5bd35122020-10-22 16:48:49 -070088
89sh_test {
90 name: "tinyxml2-tests",
91 src: "run-tinyxml2-tests-on-android.sh",
92 filename: "run-tinyxml2-tests-on-android.sh",
93 test_suites: ["general-tests"],
94 host_supported: true,
95 device_supported: false,
96 require_root: true,
97 target_required: ["tinyxml2-xmltest"],
98}