• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1// Copyright (C) 2022 The Android Open Source Project
2//
3// Licensed under the Apache License, Version 2.0 (the "License");
4// you may not use this file except in compliance with the License.
5// You may obtain a copy of the License at
6//
7//      http://www.apache.org/licenses/LICENSE-2.0
8//
9// Unless required by applicable law or agreed to in writing, software
10// distributed under the License is distributed on an "AS IS" BASIS,
11// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12// See the License for the specific language governing permissions and
13// limitations under the License.
14//
15// This file is automatically generated by gen_android_bp.py. Do not edit.
16
17// GN: Package-Artificial
18package {
19    default_applicable_licenses: [
20        "external_cronet_license",
21    ],
22}
23
24// GN: //build/rust/tests/bindgen_test:bindgen_test_lib__testing
25rust_ffi_static {
26    name: "libbuild_srust_stests_sbindgen_utest_cbindgen_utest_ulib__6e1c0e1e958383cd",
27    srcs: [
28        "src/lib.rs",
29    ],
30    host_cross_supported: false,
31    apex_available: [
32        "com.android.tethering",
33    ],
34    min_sdk_version: "30",
35    visibility: [
36        "//external/cronet:__subpackages__",
37    ],
38    crate_name: "build_srust_stests_sbindgen_utest_cbindgen_utest_ulib",
39    crate_root: "src/lib.rs",
40    rustlibs: [
41        "libbuild_srust_stests_sbindgen_utest_cc_ulib_ubindgen__c13d9fc7f8c267c3",
42        "libchromium__eb6193a5492aad4d",
43    ],
44    target: {
45        android_arm: {
46            edition: "2021",
47            cfgs: [
48                "cr_rustc_revision=\"a522d78598415cdd614ccc6d961160f192f64b5c-1-llvmorg-20-init-13894-g8cb44859\"",
49            ],
50            flags: [
51                "-Dunsafe_op_in_unsafe_fn",
52                "-Dwarnings",
53                "-Aunused-imports",
54                "-Cforce-unwind-tables=yes",
55                "-Crelocation-model=pic",
56                "-Coverflow-checks=on",
57                "-Cdefault-linker-libraries",
58                "-Clto=no",
59                "-Ccodegen-units=1",
60                "-Copt-level=s",
61                "-Cdebuginfo=1",
62            ],
63        },
64        android_arm64: {
65            edition: "2021",
66            cfgs: [
67                "cr_rustc_revision=\"a522d78598415cdd614ccc6d961160f192f64b5c-1-llvmorg-20-init-13894-g8cb44859\"",
68            ],
69            flags: [
70                "-Dunsafe_op_in_unsafe_fn",
71                "-Dwarnings",
72                "-Aunused-imports",
73                "-Cforce-unwind-tables=yes",
74                "-Crelocation-model=pic",
75                "-Coverflow-checks=on",
76                "-Cdefault-linker-libraries",
77                "-Clto=no",
78                "-Ccodegen-units=1",
79                "-Copt-level=3",
80                "-Cdebuginfo=1",
81            ],
82        },
83        android_riscv64: {
84            edition: "2021",
85            cfgs: [
86                "cr_rustc_revision=\"a522d78598415cdd614ccc6d961160f192f64b5c-1-llvmorg-20-init-13894-g8cb44859\"",
87            ],
88            flags: [
89                "-Dunsafe_op_in_unsafe_fn",
90                "-Dwarnings",
91                "-Aunused-imports",
92                "-Cforce-unwind-tables=yes",
93                "-Crelocation-model=pic",
94                "-Coverflow-checks=on",
95                "-Cdefault-linker-libraries",
96                "-Clto=no",
97                "-Ccodegen-units=1",
98                "-Copt-level=s",
99                "-Cdebuginfo=1",
100            ],
101        },
102        android_x86: {
103            edition: "2021",
104            cfgs: [
105                "cr_rustc_revision=\"a522d78598415cdd614ccc6d961160f192f64b5c-1-llvmorg-20-init-13894-g8cb44859\"",
106            ],
107            flags: [
108                "-Dunsafe_op_in_unsafe_fn",
109                "-Dwarnings",
110                "-Aunused-imports",
111                "-Cforce-unwind-tables=yes",
112                "-Crelocation-model=pic",
113                "-Coverflow-checks=on",
114                "-Cdefault-linker-libraries",
115                "-Clto=no",
116                "-Ccodegen-units=1",
117                "-Copt-level=s",
118                "-Cdebuginfo=1",
119            ],
120        },
121        android_x86_64: {
122            edition: "2021",
123            cfgs: [
124                "cr_rustc_revision=\"a522d78598415cdd614ccc6d961160f192f64b5c-1-llvmorg-20-init-13894-g8cb44859\"",
125            ],
126            flags: [
127                "-Dunsafe_op_in_unsafe_fn",
128                "-Dwarnings",
129                "-Aunused-imports",
130                "-Cforce-unwind-tables=yes",
131                "-Crelocation-model=pic",
132                "-Coverflow-checks=on",
133                "-Cdefault-linker-libraries",
134                "-Clto=no",
135                "-Ccodegen-units=1",
136                "-Copt-level=3",
137                "-Cdebuginfo=1",
138            ],
139        },
140        host: {
141            compile_multilib: "64",
142        },
143    },
144}
145
146// GN: //build/rust/tests/bindgen_test:c_lib_bindgen_generator__testing
147rust_bindgen {
148    name: "libstable_cronet_build_rust_tests_bindgen_test_c_lib_bindgen_generator__testing",
149    host_cross_supported: false,
150    header_libs: [
151        "stable_cronet_repository_root_include_dirs_anchor",
152    ],
153    apex_available: [
154        "com.android.tethering",
155    ],
156    min_sdk_version: "30",
157    visibility: [
158        "//external/cronet:__subpackages__",
159    ],
160    crate_name: "stable_cronet_build_rust_tests_bindgen_test_c_lib_bindgen_generator__testing",
161    source_stem: "bindings",
162    wrapper_src: "lib.h",
163    target: {
164        host: {
165            compile_multilib: "64",
166        },
167    },
168}
169
170// GN: //build/rust/tests/bindgen_test:bindgen_test__testing
171rust_binary {
172    name: "stable_cronet_build_rust_tests_bindgen_test_bindgen_test__testing",
173    srcs: [
174        "main.rs",
175    ],
176    whole_static_libs: [
177        "stable_cronet_build_rust_tests_bindgen_test_c_lib__testing",
178        "stable_cronet_buildtools_third_party_libc___libc____testing",
179        "stable_cronet_buildtools_third_party_libc__abi_libc__abi__testing",
180    ],
181    apex_available: [
182        "com.android.tethering",
183    ],
184    min_sdk_version: "30",
185    visibility: [
186        "//external/cronet:__subpackages__",
187        "//packages/modules/Connectivity:__subpackages__",
188    ],
189    crate_name: "bindgen_test",
190    crate_root: "main.rs",
191    rustlibs: [
192        "libbuild_srust_stests_sbindgen_utest_cbindgen_utest_ulib__6e1c0e1e958383cd",
193        "libbuild_srust_stests_sbindgen_utest_cc_ulib_ubindgen__c13d9fc7f8c267c3",
194        "libchromium__eb6193a5492aad4d",
195    ],
196    target: {
197        android_arm: {
198            edition: "2021",
199            cfgs: [
200                "cr_rustc_revision=\"a522d78598415cdd614ccc6d961160f192f64b5c-1-llvmorg-20-init-13894-g8cb44859\"",
201            ],
202            flags: [
203                "-Dunsafe_op_in_unsafe_fn",
204                "-Dwarnings",
205                "-Aunused-imports",
206                "-Cforce-unwind-tables=yes",
207                "-Crelocation-model=pic",
208                "-Coverflow-checks=on",
209                "-Cdefault-linker-libraries",
210                "-Clto=no",
211                "-Ccodegen-units=1",
212                "-Copt-level=s",
213                "-Cdebuginfo=1",
214                "-Funsafe_code",
215            ],
216        },
217        android_arm64: {
218            edition: "2021",
219            cfgs: [
220                "cr_rustc_revision=\"a522d78598415cdd614ccc6d961160f192f64b5c-1-llvmorg-20-init-13894-g8cb44859\"",
221            ],
222            flags: [
223                "-Dunsafe_op_in_unsafe_fn",
224                "-Dwarnings",
225                "-Aunused-imports",
226                "-Cforce-unwind-tables=yes",
227                "-Crelocation-model=pic",
228                "-Coverflow-checks=on",
229                "-Cdefault-linker-libraries",
230                "-Clto=no",
231                "-Ccodegen-units=1",
232                "-Copt-level=3",
233                "-Cdebuginfo=1",
234                "-Funsafe_code",
235            ],
236        },
237        android_riscv64: {
238            edition: "2021",
239            cfgs: [
240                "cr_rustc_revision=\"a522d78598415cdd614ccc6d961160f192f64b5c-1-llvmorg-20-init-13894-g8cb44859\"",
241            ],
242            flags: [
243                "-Dunsafe_op_in_unsafe_fn",
244                "-Dwarnings",
245                "-Aunused-imports",
246                "-Cforce-unwind-tables=yes",
247                "-Crelocation-model=pic",
248                "-Coverflow-checks=on",
249                "-Cdefault-linker-libraries",
250                "-Clto=no",
251                "-Ccodegen-units=1",
252                "-Copt-level=s",
253                "-Cdebuginfo=1",
254                "-Funsafe_code",
255            ],
256        },
257        android_x86: {
258            edition: "2021",
259            cfgs: [
260                "cr_rustc_revision=\"a522d78598415cdd614ccc6d961160f192f64b5c-1-llvmorg-20-init-13894-g8cb44859\"",
261            ],
262            flags: [
263                "-Dunsafe_op_in_unsafe_fn",
264                "-Dwarnings",
265                "-Aunused-imports",
266                "-Cforce-unwind-tables=yes",
267                "-Crelocation-model=pic",
268                "-Coverflow-checks=on",
269                "-Cdefault-linker-libraries",
270                "-Clto=no",
271                "-Ccodegen-units=1",
272                "-Copt-level=s",
273                "-Cdebuginfo=1",
274                "-Funsafe_code",
275            ],
276        },
277        android_x86_64: {
278            edition: "2021",
279            cfgs: [
280                "cr_rustc_revision=\"a522d78598415cdd614ccc6d961160f192f64b5c-1-llvmorg-20-init-13894-g8cb44859\"",
281            ],
282            flags: [
283                "-Dunsafe_op_in_unsafe_fn",
284                "-Dwarnings",
285                "-Aunused-imports",
286                "-Cforce-unwind-tables=yes",
287                "-Crelocation-model=pic",
288                "-Coverflow-checks=on",
289                "-Cdefault-linker-libraries",
290                "-Clto=no",
291                "-Ccodegen-units=1",
292                "-Copt-level=3",
293                "-Cdebuginfo=1",
294                "-Funsafe_code",
295            ],
296        },
297        host: {
298            compile_multilib: "64",
299        },
300    },
301}
302
303// GN: //build/rust/tests/bindgen_test:c_lib__testing
304cc_library_static {
305    name: "stable_cronet_build_rust_tests_bindgen_test_c_lib__testing",
306    srcs: [
307        "lib.c",
308    ],
309    host_cross_supported: false,
310    defaults: [
311        "stable_cronet_cc_defaults",
312    ],
313    cflags: [
314        "-DANDROID",
315        "-DANDROID_NDK_VERSION_ROLL=r27_1",
316        "-DCOMPONENT_IMPLEMENTATION",
317        "-DCR_CLANG_REVISION=\"llvmorg-20-init-13894-g8cb44859-1\"",
318        "-DCR_LIBCXX_REVISION=6a91009985a46122b061d36bb27f2c94f99126df",
319        "-DDYNAMIC_ANNOTATIONS_ENABLED=0",
320        "-DHAVE_SYS_UIO_H",
321        "-DNDEBUG",
322        "-DNVALGRIND",
323        "-DOFFICIAL_BUILD",
324        "-DTMP_REBUILD_HACK",
325        "-D_GNU_SOURCE",
326        "-D_LIBCPP_DISABLE_VISIBILITY_ANNOTATIONS",
327        "-D_LIBCPP_HARDENING_MODE=_LIBCPP_HARDENING_MODE_EXTENSIVE",
328        "-D_LIBCPP_INSTRUMENTED_WITH_ASAN=0",
329        "-D_LIBCXXABI_DISABLE_VISIBILITY_ANNOTATIONS",
330        "-D__ANDROID_UNAVAILABLE_SYMBOLS_ARE_WEAK__",
331        "-D__STDC_CONSTANT_MACROS",
332        "-D__STDC_FORMAT_MACROS",
333        "-fdata-sections",
334        "-ffunction-sections",
335        "-fstack-protector",
336        "-fvisibility-inlines-hidden",
337        "-fvisibility=hidden",
338        "-g1",
339    ],
340    include_dirs: [
341        "external/cronet/stable/",
342        "external/cronet/stable/buildtools/third_party/libc++/",
343        "external/cronet/stable/third_party/libc++/src/include",
344        "external/cronet/stable/third_party/libc++abi/src/include",
345    ],
346    cpp_std: "c++20",
347    ldflags: [
348        "-Wl,--as-needed",
349        "-Wl,--gc-sections",
350        "-Wl,--icf=all",
351    ],
352    visibility: [
353        "//external/cronet:__subpackages__",
354    ],
355    target: {
356        android_arm: {
357            cflags: [
358                "-D_FORTIFY_SOURCE=2",
359            ],
360        },
361        android_arm64: {
362            cflags: [
363                "-D_FORTIFY_SOURCE=2",
364                "-D__ARM_NEON__=1",
365                "-O2",
366                "-mno-outline",
367            ],
368        },
369        android_x86: {
370            cflags: [
371                "-D_FORTIFY_SOURCE=2",
372                "-msse3",
373            ],
374        },
375        android_x86_64: {
376            cflags: [
377                "-D_FORTIFY_SOURCE=2",
378                "-O2",
379                "-msse3",
380            ],
381        },
382    },
383}
384