Robin Lee | 4fd4d39 | 2017-03-14 14:03:05 +0000 | [diff] [blame] | 1 | cc_library_headers { |
| 2 | name: "libnetd_client_headers", |
| 3 | export_include_dirs: ["include"], |
Jiyong Park | 965a1ed | 2020-04-08 23:40:11 +0900 | [diff] [blame^] | 4 | apex_available: [ |
| 5 | "//apex_available:platform", |
| 6 | "com.android.resolv", |
| 7 | ], |
Robin Lee | 4fd4d39 | 2017-03-14 14:03:05 +0000 | [diff] [blame] | 8 | } |
| 9 | |
Bernie Innocenti | 0c53274 | 2018-06-11 14:12:08 +0900 | [diff] [blame] | 10 | cc_defaults { |
| 11 | name: "netd_defaults", |
Bernie Innocenti | 9895179 | 2018-06-26 17:13:44 +0900 | [diff] [blame] | 12 | cflags: [ |
| 13 | "-Wall", |
| 14 | "-Werror", |
Bernie Innocenti | 11cd020 | 2018-10-12 21:27:45 +0900 | [diff] [blame] | 15 | // Override -Wno-error=implicit-fallthrough from soong |
| 16 | "-Werror=implicit-fallthrough", |
Bernie Innocenti | e630555 | 2019-10-30 17:26:00 +0900 | [diff] [blame] | 17 | "-Werror=sometimes-uninitialized", |
| 18 | "-Werror=conditional-uninitialized", |
Bernie Innocenti | 9895179 | 2018-06-26 17:13:44 +0900 | [diff] [blame] | 19 | "-Wnullable-to-nonnull-conversion", |
Bernie Innocenti | 45238a1 | 2018-12-04 14:57:48 +0900 | [diff] [blame] | 20 | "-Wsign-compare", |
Bernie Innocenti | 9895179 | 2018-06-26 17:13:44 +0900 | [diff] [blame] | 21 | "-Wthread-safety", |
| 22 | "-Wunused-parameter", |
waynema | 71a0b59 | 2018-11-21 13:31:34 +0800 | [diff] [blame] | 23 | "-Wuninitialized", |
Bernie Innocenti | 9895179 | 2018-06-26 17:13:44 +0900 | [diff] [blame] | 24 | ], |
Bernie Innocenti | 0c53274 | 2018-06-11 14:12:08 +0900 | [diff] [blame] | 25 | tidy: true, |
Bernie Innocenti | df2640a | 2019-11-07 16:42:58 +0900 | [diff] [blame] | 26 | cpp_std: "experimental", |
Bernie Innocenti | 0c53274 | 2018-06-11 14:12:08 +0900 | [diff] [blame] | 27 | tidy_checks: [ |
| 28 | "android-*", |
| 29 | "cert-*", |
Bernie Innocenti | 2a008c5 | 2018-10-12 22:30:22 +0900 | [diff] [blame] | 30 | "clang-analyzer-security*", |
Bernie Innocenti | a5161a0 | 2019-01-30 22:40:53 +0900 | [diff] [blame] | 31 | "google-*", |
| 32 | "misc-*", |
| 33 | "performance-*", |
| 34 | "-cert-err34-c", // TODO: re-enable after removing atoi() and sscanf() calls |
| 35 | "-google-readability-*", // Too pedantic |
| 36 | "-google-runtime-int", // Too many unavoidable warnings due to strtol() |
| 37 | "-google-runtime-references", // Grandfathered usage of pass by non-const reference |
| 38 | "-misc-non-private-member-variables-in-classes", // Also complains about structs |
Bernie Innocenti | 2a008c5 | 2018-10-12 22:30:22 +0900 | [diff] [blame] | 39 | ], |
| 40 | tidy_flags: [ |
Bernie Innocenti | a5161a0 | 2019-01-30 22:40:53 +0900 | [diff] [blame] | 41 | "-warnings-as-errors=" |
| 42 | + "'android-*'" |
| 43 | + ",'clang-analyzer-security*'" |
| 44 | + ",'cert-*'" |
| 45 | + ",'google-*'" |
| 46 | + ",'performance-*'" |
| 47 | + ",'misc-*'" |
Bernie Innocenti | 0c53274 | 2018-06-11 14:12:08 +0900 | [diff] [blame] | 48 | ], |
| 49 | } |