• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1// This file is generated by cargo2android.py --config cargo2android.json.
2// Do not modify this file as changes will be overridden on upgrade.
3
4package {
5    default_applicable_licenses: ["external_rust_crates_ryu_license"],
6}
7
8// Added automatically by a large-scale-change that took the approach of
9// 'apply every license found to every target'. While this makes sure we respect
10// every license restriction, it may not be entirely correct.
11//
12// e.g. GPL in an MIT project might only apply to the contrib/ directory.
13//
14// Please consider splitting the single license below into multiple licenses,
15// taking care not to lose any license_kind information, and overriding the
16// default license using the 'licenses: [...]' property on targets as needed.
17//
18// For unused files, consider creating a 'fileGroup' with "//visibility:private"
19// to attach the license to, and including a comment whether the files may be
20// used in the current project.
21//
22// large-scale-change included anything that looked like it might be a license
23// text as a license_text. e.g. LICENSE, NOTICE, COPYING etc.
24//
25// Please consider removing redundant or irrelevant files from 'license_text:'.
26// See: http://go/android-license-faq
27license {
28    name: "external_rust_crates_ryu_license",
29    visibility: [":__subpackages__"],
30    license_kinds: [
31        "SPDX-license-identifier-Apache-2.0",
32        "SPDX-license-identifier-BSL-1.0",
33        "SPDX-license-identifier-MIT",
34    ],
35    license_text: [
36        "LICENSE",
37        "LICENSE-APACHE",
38        "LICENSE-BOOST",
39    ],
40}
41
42rust_library {
43    name: "libryu",
44    host_supported: true,
45    crate_name: "ryu",
46    cargo_env_compat: true,
47    cargo_pkg_version: "1.0.9",
48    srcs: ["src/lib.rs"],
49    edition: "2018",
50    apex_available: [
51        "//apex_available:platform",
52        "com.android.virt",
53    ],
54}
55
56rust_defaults {
57    name: "ryu_test_defaults",
58    crate_name: "ryu",
59    cargo_env_compat: true,
60    cargo_pkg_version: "1.0.9",
61    test_suites: ["general-tests"],
62    auto_gen_config: true,
63    edition: "2018",
64    rustlibs: [
65        "libnum_cpus",
66        "librand",
67        "librand_xorshift",
68        "libryu",
69    ],
70}
71
72rust_test {
73    name: "ryu_test_tests_common_test",
74    defaults: ["ryu_test_defaults"],
75    host_supported: true,
76    srcs: ["tests/common_test.rs"],
77    test_options: {
78        unit_test: true,
79    },
80}
81
82rust_test {
83    name: "ryu_test_tests_d2s_table_test",
84    defaults: ["ryu_test_defaults"],
85    host_supported: true,
86    srcs: ["tests/d2s_table_test.rs"],
87    test_options: {
88        unit_test: true,
89    },
90}
91
92rust_test {
93    name: "ryu_test_tests_d2s_test",
94    defaults: ["ryu_test_defaults"],
95    host_supported: true,
96    srcs: ["tests/d2s_test.rs"],
97    test_options: {
98        unit_test: true,
99    },
100}
101
102rust_test {
103    name: "ryu_test_tests_f2s_test",
104    defaults: ["ryu_test_defaults"],
105    host_supported: true,
106    srcs: ["tests/f2s_test.rs"],
107    test_options: {
108        unit_test: true,
109    },
110}
111
112rust_test {
113    name: "ryu_test_tests_s2d_test",
114    defaults: ["ryu_test_defaults"],
115    host_supported: true,
116    srcs: ["tests/s2d_test.rs"],
117    test_options: {
118        unit_test: true,
119    },
120}
121
122rust_test {
123    name: "ryu_test_tests_s2f_test",
124    defaults: ["ryu_test_defaults"],
125    host_supported: true,
126    srcs: ["tests/s2f_test.rs"],
127    test_options: {
128        unit_test: true,
129    },
130}
131