blob: 78a631f02eeb049f3303068eec757ea2c2b56723 [file] [log] [blame]
Bob Badour601ebb42021-02-03 23:07:40 -08001package {
2 // http://go/android-license-faq
3 // A large-scale-change added 'default_applicable_licenses' to import
4 // the below license kinds from "system_sepolicy_license":
5 // SPDX-license-identifier-Apache-2.0
6 default_applicable_licenses: ["system_sepolicy_license"],
7}
8
Jeff Vander Stoepbdfc0302017-05-25 09:53:47 -07009cc_library_host_shared {
10 name: "libsepolwrap",
11 srcs: ["sepol_wrap.cpp"],
Jeff Vander Stoepbdfc0302017-05-25 09:53:47 -070012 cflags: ["-Wall", "-Werror",],
13 export_include_dirs: ["include"],
Inseob Kim6fa8efd2021-12-29 13:56:14 +090014 stl: "c++_static",
Dan Willemsen948354a2017-09-01 14:08:46 -070015
16 // libsepolwrap gets loaded from the system python, which does not have the
17 // ASAN runtime. So turn off sanitization for ourself, and use static
18 // libraries, since the shared libraries will use ASAN.
Jeff Vander Stoep3ca843a2017-10-04 09:42:29 -070019 static_libs: [
20 "libbase",
21 "libsepol",
22 ],
Dan Willemsen948354a2017-09-01 14:08:46 -070023 sanitize: {
24 never: true,
25 },
Jeff Vander Stoepbdfc0302017-05-25 09:53:47 -070026}
Jeff Vander Stoep1fc06822017-05-31 15:36:07 -070027
Jeff Vander Stoepa7d2c5b2017-09-23 14:42:50 -070028python_binary_host {
29 name: "treble_sepolicy_tests",
30 srcs: [
Jeff Vander Stoep1ca7a4c2019-04-10 16:53:17 -070031 "fc_sort.py",
Dan Cashman91d398d2017-09-26 12:58:29 -070032 "mini_parser.py",
33 "policy.py",
Jeff Vander Stoep370a52f2018-02-08 09:54:59 -080034 "treble_sepolicy_tests.py",
Dan Cashman91d398d2017-09-26 12:58:29 -070035 ],
Inseob Kim6fa8efd2021-12-29 13:56:14 +090036 data: [":libsepolwrap"],
Dan Cashman91d398d2017-09-26 12:58:29 -070037}
38
39python_binary_host {
40 name: "sepolicy_tests",
41 srcs: [
Jeff Vander Stoep1ca7a4c2019-04-10 16:53:17 -070042 "fc_sort.py",
Dan Cashman91d398d2017-09-26 12:58:29 -070043 "policy.py",
Jeff Vander Stoep370a52f2018-02-08 09:54:59 -080044 "sepolicy_tests.py",
Dan Cashman91d398d2017-09-26 12:58:29 -070045 ],
Inseob Kim6fa8efd2021-12-29 13:56:14 +090046 data: [":libsepolwrap"],
Dan Cashman91d398d2017-09-26 12:58:29 -070047}
48
49python_binary_host {
50 name: "searchpolicy",
51 srcs: [
Jeff Vander Stoep1ca7a4c2019-04-10 16:53:17 -070052 "fc_sort.py",
Jeff Vander Stoepa7d2c5b2017-09-23 14:42:50 -070053 "policy.py",
Jeff Vander Stoep3a3756f2018-04-24 11:03:22 -070054 "searchpolicy.py",
Jeff Vander Stoepa7d2c5b2017-09-23 14:42:50 -070055 ],
56 required: ["libsepolwrap"],
Jeff Vander Stoep1fc06822017-05-31 15:36:07 -070057}
Tri Vo438684b2018-09-29 17:47:10 -070058
59python_binary_host {
60 name: "combine_maps",
61 srcs: [
62 "combine_maps.py",
63 "mini_parser.py",
64 ],
65}
Jeff Vander Stoep1ca7a4c2019-04-10 16:53:17 -070066
67python_binary_host {
68 name: "fc_sort",
69 srcs: [
70 "fc_sort.py",
71 ],
Jeff Vander Stoep1ca7a4c2019-04-10 16:53:17 -070072}
Inseob Kim2bcc0452020-12-21 13:16:44 +090073
ThiƩbaud Weksteenb75b4d22021-11-24 14:44:28 +110074python_test_host {
75 name: "fc_sort_test",
76 srcs: [
77 "fc_sort.py",
78 "fc_sort_test.py",
79 ],
ThiƩbaud Weksteenb75b4d22021-11-24 14:44:28 +110080 test_options: {
81 unit_test: true,
82 }
83}
84
Inseob Kim2bcc0452020-12-21 13:16:44 +090085python_binary_host {
86 name: "check_prop_prefix",
87 srcs: ["check_prop_prefix.py"],
88}