• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1// List of clang-tidy checks that are reported as errors.
2// Please keep this list ordered lexicographically.
3package {
4    default_applicable_licenses: ["Android-Apache-2.0"],
5}
6
7tidy_errors = [
8  "android-*",
9  "bugprone-infinite-loop",
10  "bugprone-macro-parentheses",
11  "bugprone-misplaced-widening-cast",
12  "bugprone-move-forwarding-reference",
13  "bugprone-sizeof-container",
14  "bugprone-sizeof-expression",
15  "bugprone-string-constructor",
16  "bugprone-terminating-continue",
17  "bugprone-undefined-memory-manipulation",
18  "bugprone-undelegated-constructor",
19  // "bugprone-unhandled-self-assignment", // found in apex_manifest.proto
20  "bugprone-unused-raii",
21  "cert-err34-c",
22  "google-default-arguments",
23  // "google-explicit-constructor", // found in com_android_apex.h
24  "google-readability-avoid-underscore-in-googletest-name",
25  "google-readability-todo",
26  "google-runtime-int",
27  "google-runtime-member-string-references",
28  "misc-move-const-arg",
29  "misc-move-forwarding-reference",
30  // "misc-unused-parameters", // found in apexd_utils.h
31  "misc-unused-using-decls",
32  "misc-use-after-move",
33  // "modernize-pass-by-value", // found in apex_database.h
34  "performance-faster-string-find",
35  "performance-for-range-copy",
36  "performance-implicit-conversion-in-loop",
37  "performance-inefficient-vector-operation",
38  "performance-move-const-arg",
39  // "performance-move-constructor-init", // found in apexd_loop.h
40  "performance-noexcept-move-constructor",
41  "performance-unnecessary-copy-initialization",
42  "performance-unnecessary-value-param",
43  // "readability-avoid-const-params-in-decls", // found in apexd.h
44]
45
46cc_defaults {
47  name: "apex_flags_defaults",
48  cflags: [
49    "-Wall",
50    "-Wextra",
51    "-Werror",
52    "-Wno-unused-parameter",
53
54    // Some extra flags.
55    "-fstrict-aliasing",
56    "-Wredundant-decls",
57    "-Wshadow",
58    "-Wstrict-aliasing",
59    "-Wthread-safety",
60    "-Wthread-safety-negative",
61    "-Wunreachable-code",
62    "-Wunreachable-code-break",
63    "-Wunreachable-code-return",
64    "-Wunused",
65    "-Wused-but-marked-unused",
66  ],
67  tidy: true,
68  tidy_checks: tidy_errors,
69  tidy_checks_as_errors: tidy_errors,
70  tidy_flags: [
71    "-format-style=file",
72    "-header-filter=system/apex/",
73  ],
74}
75
76
77cc_defaults {
78  name: "libapexd-deps",
79  defaults: ["libapex-deps"],
80  shared_libs: [
81    "liblog",
82    "liblogwrap",
83  ],
84  static_libs: [
85    "libapex",
86    "libavb",
87    "libdm",
88    "libext2_uuid",
89    "libsigningutils",
90    "libtinyxml2",
91    "libverity_tree",
92    "libvold_binder",
93  ],
94  whole_static_libs: ["libcom.android.sysprop.apex"],
95}
96
97aidl_interface {
98  name: "apex_aidl_interface",
99  unstable: true,
100  srcs: [
101    "aidl/android/apex/ApexInfo.aidl",
102    "aidl/android/apex/ApexInfoList.aidl",
103    "aidl/android/apex/ApexSessionInfo.aidl",
104    "aidl/android/apex/ApexSessionParams.aidl",
105    "aidl/android/apex/CompressedApexInfo.aidl",
106    "aidl/android/apex/CompressedApexInfoList.aidl",
107    "aidl/android/apex/IApexService.aidl",
108  ],
109  local_include_dir: "aidl",
110  backend: {
111      java: {
112          sdk_version: "28",
113      },
114      ndk: {
115          enabled: false,
116      },
117  },
118}
119
120cc_binary {
121  name: "apexd",
122  defaults: [
123    "apex_flags_defaults",
124    "libapex-deps",
125    "libapexd-deps",
126    "libapexservice-deps",
127  ],
128  srcs: [
129    "apexd_main.cpp",
130  ],
131  static_libs: [
132    "libapex",
133    "libapexd",
134    "libapexd_checkpoint_vold",
135    "libapexservice",
136  ],
137  init_rc: ["apexd.rc"],
138  // Just like the init, apexd should be able to run without
139  // any APEX activated. To do so, it uses the bootstrap linker
140  // and the bootstrap bionic libraries.
141  bootstrap: true,
142}
143
144cc_binary {
145  name: "apexd.microdroid",
146  defaults: [
147    "apex_flags_defaults",
148    "libapex-deps",
149    "libapexd-deps",
150  ],
151  srcs: [
152    "apexd_microdroid.cpp",
153  ],
154  static_libs: [
155    "libapex",
156    "libapexd",
157    // Prefer static-link as, in microdroid, apexd is the only client.
158    // Using the -ndk variant since libprotobuf-cpp-full is supposed to be
159    // used as a shared lib in general in Android.
160    "libprotobuf-cpp-full-ndk",
161  ],
162  exclude_shared_libs: [
163    "libprotobuf-cpp-full",
164  ],
165  // Just like the init, apexd should be able to run without
166  // any APEX activated. To do so, it uses the bootstrap linker
167  // and the bootstrap bionic libraries.
168  bootstrap: true,
169  // This variant is for microdroid.
170  installable: false,
171  // init depends on the name "apexd".
172  stem: "apexd",
173}
174
175cc_library_static {
176  name: "libapexd",
177  defaults: [
178    "apex_flags_defaults",
179    "libapexd-deps",
180  ],
181  srcs: [
182    "apex_classpath.cpp",
183    "apex_database.cpp",
184    "apexd.cpp",
185    "apexd_lifecycle.cpp",
186    "apexd_loop.cpp",
187    "apexd_private.cpp",
188    "apexd_session.cpp",
189    "apexd_verity.cpp",
190  ],
191  export_include_dirs: ["."],
192  generated_sources: ["apex-info-list-tinyxml"],
193  // Don't add shared/static libs here; add to libapexd_defaults instead.
194}
195
196cc_library_static {
197  name: "libapexd_checkpoint_vold",
198  defaults: ["apex_flags_defaults"],
199  srcs: [ "apexd_checkpoint_vold.cpp" ],
200  static_libs: [
201    "libbase",
202    "libutils",
203    "libvold_binder",
204  ],
205  export_include_dirs: ["."],
206}
207
208cc_defaults {
209  name: "libapexservice-deps",
210  shared_libs: [
211    "apex_aidl_interface-cpp",
212    "libbinder",
213    "libutils",
214  ],
215}
216
217cc_library_static {
218  name: "libapexservice",
219  defaults: [
220    "apex_flags_defaults",
221    "libapexd-deps",
222    "libapexservice-deps",
223  ],
224  srcs: ["apexservice.cpp"],
225  static_libs: [
226    "libapexd",
227  ],
228  cflags: [
229    "-DANDROID_UTILS_REF_BASE_DISABLE_IMPLICIT_CONSTRUCTION",
230  ],
231}
232
233cc_defaults {
234  name: "libapex-deps",
235  shared_libs: [
236    "libbase",
237    "libcrypto",
238    "libcutils",
239    "libprotobuf-cpp-full",
240    "libziparchive",
241    "libselinux",
242  ],
243  static_libs: [
244    "lib_apex_session_state_proto",
245    "lib_apex_manifest_proto",
246    "lib_microdroid_metadata_proto",
247    "libavb",
248    "libverity_tree",
249  ],
250  static: {
251    whole_static_libs: ["libc++fs"],
252  },
253  cpp_std: "experimental",
254  shared: {
255    static_libs: ["libc++fs"],
256  },
257}
258
259cc_library_static {
260  name: "libapex",
261  defaults: [
262    "apex_flags_defaults",
263    "libapex-deps"
264  ],
265  srcs: [
266    "apex_file.cpp",
267    "apex_file_repository.cpp",
268    "apex_manifest.cpp",
269    "apex_shim.cpp",
270    "apexd_verity.cpp",
271  ],
272  host_supported: true,
273  target: {
274    darwin: {
275      enabled: false,
276    },
277  },
278  header_libs: [
279    "libutils_headers",
280  ],
281  export_header_lib_headers: [
282    "libutils_headers",
283  ],
284  export_include_dirs: ["."],
285}
286
287cc_binary_host {
288  name: "dump_apex_info",
289  defaults: [
290    "apex_flags_defaults",
291    "libapex-deps",
292  ],
293  static_libs: [
294    "libapex",
295  ],
296  srcs: [
297    "dump_apex_info.cpp",
298  ],
299  shared_libs: [
300    "libtinyxml2",
301  ],
302  generated_sources: ["apex-info-list-tinyxml"],
303}
304
305genrule {
306  // Generates an apex which has a different manifest outside the filesystem
307  // image.
308  name: "gen_manifest_mismatch_apex",
309  out: ["apex.apexd_test_manifest_mismatch.apex"],
310  srcs: [":apex.apexd_test"],
311  tools: ["soong_zip", "zipalign", "conv_apex_manifest"],
312  cmd: "unzip -q $(in) -d $(genDir) && " +
313       "$(location conv_apex_manifest) setprop version 137 $(genDir)/apex_manifest.pb && " +
314       "$(location soong_zip) -d -C $(genDir) -D $(genDir) " +
315       "-s apex_manifest.pb -s apex_payload.img -s apex_pubkey " +
316       "-o $(genDir)/unaligned.apex && " +
317       "$(location zipalign) -f 4096 $(genDir)/unaligned.apex " +
318       "$(genDir)/apex.apexd_test_manifest_mismatch.apex"
319}
320
321genrule {
322  // Generates an apex which has a different manifest outside the filesystem
323  // image.
324  name: "gen_manifest_mismatch_apex_no_hashtree",
325  out: ["apex.apexd_test_no_hashtree_manifest_mismatch.apex"],
326  srcs: [":apex.apexd_test_no_hashtree"],
327  tools: ["soong_zip", "zipalign", "conv_apex_manifest"],
328  cmd: "unzip -q $(in) -d $(genDir) && " +
329       "$(location conv_apex_manifest) setprop version 137 $(genDir)/apex_manifest.pb && " +
330       "$(location soong_zip) -d -C $(genDir) -D $(genDir) " +
331       "-s apex_manifest.pb -s apex_payload.img -s apex_pubkey " +
332       "-o $(genDir)/unaligned.apex && " +
333       "$(location zipalign) -f 4096 $(genDir)/unaligned.apex " +
334       "$(genDir)/apex.apexd_test_no_hashtree_manifest_mismatch.apex"
335}
336
337genrule {
338  // Generates an apex with a corrupted filesystem superblock, which should cause
339  // Apex::Open to fail
340  name: "gen_corrupt_superblock_apex",
341  out: ["apex.apexd_test_corrupt_superblock_apex.apex"],
342  srcs: [":apex.apexd_test"],
343  tools: ["soong_zip", "zipalign"],
344  cmd: "unzip -q $(in) -d $(genDir) && " +
345       "dd if=/dev/zero of=$(genDir)/apex_payload.img conv=notrunc bs=1024 seek=1 count=1 && " +
346       "$(location soong_zip) -d -C $(genDir) -D $(genDir) " +
347       "-s apex_manifest.pb -s apex_payload.img -s apex_pubkey " +
348       "-o $(genDir)/unaligned.apex && " +
349       "$(location zipalign) -f 4096 $(genDir)/unaligned.apex " +
350       "$(genDir)/apex.apexd_test_corrupt_superblock_apex.apex"
351}
352
353genrule {
354  // Generates an apex with a corrupted filesystem image, which should cause
355  // dm-verity verification to fail
356  name: "gen_corrupt_apex",
357  out: ["apex.apexd_test_corrupt_apex.apex"],
358  srcs: [":apex.apexd_test"],
359  tools: ["soong_zip", "zipalign"],
360  cmd: "unzip -q $(in) -d $(genDir) && " +
361       "dd if=/dev/zero of=$(genDir)/apex_payload.img conv=notrunc bs=1024 seek=16 count=1 && " +
362       "$(location soong_zip) -d -C $(genDir) -D $(genDir) " +
363       "-s apex_manifest.pb -s apex_payload.img -s apex_pubkey " +
364       "-o $(genDir)/unaligned.apex && " +
365       "$(location zipalign) -f 4096 $(genDir)/unaligned.apex " +
366       "$(genDir)/apex.apexd_test_corrupt_apex.apex"
367}
368
369genrule {
370  // Extract the root digest with avbtool
371  name: "apex.apexd_test_digest",
372  out: ["apex.apexd_test_digest.txt"],
373  srcs: [":apex.apexd_test"],
374  tools: ["avbtool"],
375  cmd: "unzip -q $(in) -d $(genDir) apex_payload.img && " +
376       "$(location avbtool) print_partition_digests --image $(genDir)/apex_payload.img " +
377       "| cut -c 3-| tee $(out)"
378}
379
380genrule {
381  // Extract the root digest with avbtool
382  name: "apex.apexd_test_f2fs_digest",
383  out: ["apex.apexd_test_f2fs_digest.txt"],
384  srcs: [":apex.apexd_test_f2fs"],
385  tools: ["avbtool"],
386  cmd: "unzip -q $(in) -d $(genDir) apex_payload.img && " +
387       "$(location avbtool) print_partition_digests --image $(genDir)/apex_payload.img " +
388       "| cut -c 3-| tee $(out)"
389}
390
391genrule {
392  // Extract the root digest with avbtool
393  name: "apex.apexd_test_erofs_digest",
394  out: ["apex.apexd_test_erofs_digest.txt"],
395  srcs: [":apex.apexd_test_erofs"],
396  tools: ["avbtool"],
397  cmd: "unzip -q $(in) -d $(genDir) apex_payload.img && " +
398       "$(location avbtool) print_partition_digests --image $(genDir)/apex_payload.img " +
399       "| cut -c 3-| tee $(out)"
400}
401
402genrule {
403  // Generates an apex which has same module name as apex.apexd_test.apex, but
404  // is actually signed with a different key.
405  name: "gen_key_mismatch_apex",
406  out: ["apex.apexd_test_different_key.apex"],
407  srcs: [":apex.apexd_test_no_inst_key"],
408  tools: ["soong_zip", "zipalign", "conv_apex_manifest"],
409  cmd: "unzip -q $(in) -d $(genDir) && " +
410       "$(location conv_apex_manifest) setprop name com.android.apex.test_package $(genDir)/apex_manifest.pb && " +
411       "$(location soong_zip) -d -C $(genDir) -D $(genDir) " +
412       "-s apex_manifest.pb -s apex_payload.img -s apex_pubkey " +
413       "-o $(genDir)/unaligned.apex && " +
414       "$(location zipalign) -f 4096 $(genDir)/unaligned.apex " +
415       "$(genDir)/apex.apexd_test_different_key.apex"
416}
417
418genrule {
419  // Generates an apex which has same module name as apex.apexd_test.apex, but
420  // is actually signed with a different key.
421  name: "gen_key_mismatch_apex_v2",
422  out: ["apex.apexd_test_different_key_v2.apex"],
423  srcs: [":apex.apexd_test_no_inst_key"],
424  tools: ["soong_zip", "zipalign", "conv_apex_manifest"],
425  cmd: "unzip -q $(in) -d $(genDir) && " +
426       "$(location conv_apex_manifest) setprop name com.android.apex.test_package $(genDir)/apex_manifest.pb && " +
427       "$(location conv_apex_manifest) setprop version 2 $(genDir)/apex_manifest.pb && " +
428       "$(location soong_zip) -d -C $(genDir) -D $(genDir) " +
429       "-s apex_manifest.pb -s apex_payload.img -s apex_pubkey " +
430       "-o $(genDir)/unaligned.apex && " +
431       "$(location zipalign) -f 4096 $(genDir)/unaligned.apex " +
432       "$(genDir)/apex.apexd_test_different_key_v2.apex"
433}
434
435genrule {
436  // Generates an apex which has a different manifest outside the filesystem
437  // image.
438  name: "gen_manifest_mismatch_rebootless_apex",
439  out: ["test.rebootless_apex_manifest_mismatch.apex"],
440  srcs: [":test.rebootless_apex_v1"],
441  tools: ["soong_zip", "zipalign", "conv_apex_manifest"],
442  cmd: "unzip -q $(in) -d $(genDir) && " +
443       "$(location conv_apex_manifest) setprop version 137 $(genDir)/apex_manifest.pb && " +
444       "$(location soong_zip) -d -C $(genDir) -D $(genDir) " +
445       "-s apex_manifest.pb -s apex_payload.img -s apex_pubkey " +
446       "-o $(genDir)/unaligned.apex && " +
447       "$(location zipalign) -f 4096 $(genDir)/unaligned.apex " +
448       "$(genDir)/test.rebootless_apex_manifest_mismatch.apex"
449}
450
451genrule {
452  // Generates an apex with a corrupted filesystem image, which should cause
453  // dm-verity verification to fail
454  name: "gen_corrupt_rebootless_apex",
455  out: ["test.rebootless_apex_corrupted.apex"],
456  srcs: [":test.rebootless_apex_v1"],
457  tools: ["soong_zip", "zipalign"],
458  cmd: "unzip -q $(in) -d $(genDir) && " +
459       "dd if=/dev/zero of=$(genDir)/apex_payload.img conv=notrunc bs=1024 seek=16 count=1 && " +
460       "$(location soong_zip) -d -C $(genDir) -D $(genDir) " +
461       "-s apex_manifest.pb -s apex_payload.img -s apex_pubkey " +
462       "-o $(genDir)/unaligned.apex && " +
463       "$(location zipalign) -f 4096 $(genDir)/unaligned.apex " +
464       "$(genDir)/test.rebootless_apex_corrupted.apex"
465}
466
467cc_test {
468  name: "ApexTestCases",
469  defaults: [
470    "apex_flags_defaults",
471    "libapex-deps",
472    "libapexd-deps"
473  ],
474  require_root: true,
475  cflags: [
476    // Otherwise libgmock won't compile.
477    "-Wno-used-but-marked-unused",
478  ],
479  data: [
480    ":apex.apexd_test",
481    ":apex.apexd_test_erofs",
482    ":apex.apexd_test_f2fs",
483    ":apex.apexd_test_digest",
484    ":apex.apexd_test_erofs_digest",
485    ":apex.apexd_test_f2fs_digest",
486    ":apex.apexd_test_classpath",
487    ":apex.apexd_test_different_app",
488    ":apex.apexd_test_no_hashtree",
489    ":apex.apexd_test_no_hashtree_2",
490    ":apex.apexd_test_no_inst_key",
491    ":apex.apexd_test_f2fs_no_inst_key",
492    ":apex.apexd_test_nocode",
493    ":apex.apexd_test_v2",
494    ":apex.corrupted_b146895998",
495    ":apex.banned_name",
496    ":gen_key_mismatch_apex",
497    ":gen_key_mismatch_apex_v2",
498    ":gen_key_mismatch_capex",
499    ":gen_manifest_mismatch_apex",
500    ":gen_manifest_mismatch_apex_no_hashtree",
501    ":gen_corrupt_superblock_apex",
502    ":gen_corrupt_apex",
503    ":gen_capex_not_decompressible",
504    ":gen_capex_without_apex",
505    ":gen_capex_with_v2_apex",
506    ":gen_key_mismatch_with_original_capex",
507    ":com.android.apex.cts.shim.v1_prebuilt",
508    ":com.android.apex.cts.shim.v2_prebuilt",
509    ":com.android.apex.cts.shim.v2_wrong_sha_prebuilt",
510    ":com.android.apex.cts.shim.v2_additional_file_prebuilt",
511    ":com.android.apex.cts.shim.v2_additional_folder_prebuilt",
512    ":com.android.apex.cts.shim.v2_with_pre_install_hook_prebuilt",
513    ":com.android.apex.cts.shim.v2_with_post_install_hook_prebuilt",
514    ":com.android.apex.compressed_sharedlibs",
515    ":com.android.apex.compressed.v1",
516    ":com.android.apex.compressed.v1_different_digest",
517    ":com.android.apex.compressed.v1_different_digest_original",
518    ":com.android.apex.compressed.v1_original",
519    ":com.android.apex.compressed.v2",
520    ":com.android.apex.compressed.v2_original",
521    ":com.android.sepolicy",
522    ":gen_manifest_mismatch_compressed_apex_v2",
523    "apexd_testdata/com.android.apex.test_package.avbpubkey",
524    "apexd_testdata/com.android.apex.compressed.avbpubkey",
525    ":com.android.apex.test.sharedlibs_generated.v1.libvX_prebuilt",
526    ":com.android.apex.test.sharedlibs_generated.v2.libvY_prebuilt",
527    ":test.rebootless_apex_v1",
528    ":test.rebootless_apex_v2",
529    ":test.rebootless_apex_v2_no_hashtree",
530    ":test.rebootless_apex_service_v1",
531    ":test.rebootless_apex_service_v2",
532    ":gen_manifest_mismatch_rebootless_apex",
533    ":gen_corrupt_rebootless_apex",
534    ":test.rebootless_apex_provides_sharedlibs",
535    ":test.rebootless_apex_provides_native_libs",
536    ":test.rebootless_apex_requires_shared_apex_libs",
537    ":test.rebootless_apex_jni_libs",
538    ":test.rebootless_apex_add_native_lib",
539    ":test.rebootless_apex_remove_native_lib",
540    ":test.rebootless_apex_app_in_apex",
541    ":test.rebootless_apex_priv_app_in_apex",
542  ],
543  srcs: [
544    "apex_classpath_test.cpp",
545    "apex_database_test.cpp",
546    "apex_file_test.cpp",
547    "apex_file_repository_test.cpp",
548    "apex_manifest_test.cpp",
549    "apexd_test.cpp",
550    "apexd_session_test.cpp",
551    "apexd_verity_test.cpp",
552    "apexd_utils_test.cpp",
553  ],
554  host_supported: false,
555  compile_multilib: "first",
556  static_libs: [
557    "apex_aidl_interface-cpp",
558    "libapex",
559    "libapexd",
560    "libfstab",
561    "libgmock",
562  ],
563  shared_libs: [
564    "libbinder",
565    "libfs_mgr",
566    "libutils",
567  ],
568  generated_sources: ["apex-info-list-tinyxml"],
569  test_suites: ["device-tests"],
570  test_config: "ApexTestCases.xml",
571}
572
573cc_test {
574  name: "ApexServiceTestCases",
575  defaults: [
576    "apex_flags_defaults",
577    "libapex-deps",
578    "libapexd-deps"
579  ],
580  require_root: true,
581  cflags: [
582    // Otherwise libgmock won't compile.
583    "-Wno-used-but-marked-unused",
584  ],
585  data: [
586    ":apex.apexd_test",
587    ":apex.apexd_test_erofs",
588    ":apex.apexd_test_f2fs",
589    ":apex.apexd_test_digest",
590    ":apex.apexd_test_erofs_digest",
591    ":apex.apexd_test_f2fs_digest",
592    ":apex.apexd_test_classpath",
593    ":apex.apexd_test_different_app",
594    ":apex.apexd_test_no_hashtree",
595    ":apex.apexd_test_no_hashtree_2",
596    ":apex.apexd_test_no_inst_key",
597    ":apex.apexd_test_f2fs_no_inst_key",
598    ":apex.apexd_test_nocode",
599    ":apex.apexd_test_v2",
600    ":apex.corrupted_b146895998",
601    ":apex.banned_name",
602    ":gen_key_mismatch_apex",
603    ":gen_key_mismatch_apex_v2",
604    ":gen_key_mismatch_capex",
605    ":gen_manifest_mismatch_apex",
606    ":gen_manifest_mismatch_apex_no_hashtree",
607    ":gen_corrupt_superblock_apex",
608    ":gen_corrupt_apex",
609    ":gen_capex_not_decompressible",
610    ":gen_capex_without_apex",
611    ":gen_capex_with_v2_apex",
612    ":gen_key_mismatch_with_original_capex",
613    ":com.android.apex.cts.shim.v1_prebuilt",
614    ":com.android.apex.cts.shim.v2_prebuilt",
615    ":com.android.apex.cts.shim.v2_wrong_sha_prebuilt",
616    ":com.android.apex.cts.shim.v2_additional_file_prebuilt",
617    ":com.android.apex.cts.shim.v2_additional_folder_prebuilt",
618    ":com.android.apex.cts.shim.v2_with_pre_install_hook_prebuilt",
619    ":com.android.apex.cts.shim.v2_with_post_install_hook_prebuilt",
620    ":com.android.apex.compressed_sharedlibs",
621    ":com.android.apex.compressed.v1",
622    ":com.android.apex.compressed.v1_different_digest",
623    ":com.android.apex.compressed.v1_different_digest_original",
624    ":com.android.apex.compressed.v1_original",
625    ":com.android.apex.compressed.v2",
626    ":com.android.apex.compressed.v2_original",
627    ":com.android.sepolicy",
628    ":gen_manifest_mismatch_compressed_apex_v2",
629    "apexd_testdata/com.android.apex.test_package.avbpubkey",
630    "apexd_testdata/com.android.apex.compressed.avbpubkey",
631    ":com.android.apex.test.sharedlibs_generated.v1.libvX_prebuilt",
632    ":com.android.apex.test.sharedlibs_generated.v2.libvY_prebuilt",
633    ":test.rebootless_apex_v1",
634    ":test.rebootless_apex_v2",
635    ":test.rebootless_apex_v2_no_hashtree",
636    ":test.rebootless_apex_service_v1",
637    ":test.rebootless_apex_service_v2",
638    ":gen_manifest_mismatch_rebootless_apex",
639    ":gen_corrupt_rebootless_apex",
640    ":test.rebootless_apex_provides_sharedlibs",
641    ":test.rebootless_apex_provides_native_libs",
642    ":test.rebootless_apex_requires_shared_apex_libs",
643    ":test.rebootless_apex_jni_libs",
644    ":test.rebootless_apex_add_native_lib",
645    ":test.rebootless_apex_remove_native_lib",
646    ":test.rebootless_apex_app_in_apex",
647    ":test.rebootless_apex_priv_app_in_apex",
648  ],
649  srcs: [
650    "apexservice_test.cpp",
651  ],
652  host_supported: false,
653  compile_multilib: "first",
654  static_libs: [
655    "apex_aidl_interface-cpp",
656    "libapex",
657    "libapexd",
658    "libfstab",
659    "libgmock",
660  ],
661  shared_libs: [
662    "libbinder",
663    "libfs_mgr",
664    "libutils",
665  ],
666  generated_sources: ["apex-info-list-tinyxml"],
667  test_suites: ["device-tests"],
668  test_config: "ApexServiceTestCases.xml",
669}
670
671cc_test {
672  name: "flattened_apex_test",
673  defaults: [
674    "apex_flags_defaults",
675    "libapex-deps",
676    "libapexd-deps"
677  ],
678  srcs: ["flattened_apex_test.cpp"],
679  host_supported: false,
680  compile_multilib: "first",
681  static_libs: [
682    "libapex",
683    "libapexd",
684  ],
685  test_suites: ["device-tests"],
686  test_config: "flattened_apex_test_config.xml",
687}
688
689xsd_config {
690  name: "apex-info-list",
691  srcs: ["ApexInfoList.xsd"],
692  package_name: "com.android.apex",
693  api_dir: "apex-info-list-api",
694  gen_writer: true,
695  root_elements: ["apex-info-list"],
696}
697
698xsd_config {
699  name: "apex-info-list-tinyxml",
700  srcs: ["ApexInfoList.xsd"],
701  package_name: "com.android.apex",
702  api_dir: "apex-info-list-api",
703  gen_writer: true,
704  tinyxml: true,
705  root_elements: ["apex-info-list"],
706}
707