1package { 2 default_team: "trendy_team_fwk_core_networking", 3 default_applicable_licenses: ["Android-Apache-2.0"], 4} 5 6cc_library { 7 name: "libnetdutils", 8 srcs: [ 9 "DumpWriter.cpp", 10 "Fd.cpp", 11 "InternetAddresses.cpp", 12 "Log.cpp", 13 "Netfilter.cpp", 14 "Netlink.cpp", 15 "NetlinkListener.cpp", 16 "Slice.cpp", 17 "Socket.cpp", 18 "SocketOption.cpp", 19 "Status.cpp", 20 "Syscalls.cpp", 21 "UniqueFd.cpp", 22 "UniqueFile.cpp", 23 "Utils.cpp", 24 ], 25 defaults: ["netd_defaults"], 26 cflags: [ 27 "-Wall", 28 "-Werror", 29 ], 30 shared_libs: [ 31 "libbase", 32 "liblog", 33 ], 34 export_shared_lib_headers: [ 35 "libbase", 36 ], 37 export_include_dirs: ["include"], 38 sanitize: { 39 cfi: true, 40 }, 41 42 apex_available: [ 43 "//apex_available:platform", 44 "com.android.resolv", 45 "com.android.tethering", 46 ], 47 min_sdk_version: "30", 48} 49 50cc_test { 51 name: "netdutils_test", 52 srcs: [ 53 "BackoffSequenceTest.cpp", 54 "FdTest.cpp", 55 "InternetAddressesTest.cpp", 56 "LogTest.cpp", 57 "MemBlockTest.cpp", 58 "SliceTest.cpp", 59 "StatusTest.cpp", 60 "SyscallsTest.cpp", 61 "ThreadUtilTest.cpp", 62 ], 63 defaults: ["netd_defaults"], 64 test_suites: ["device-tests"], 65 static_libs: [ 66 "libgmock", 67 "libnetdutils", 68 ], 69 shared_libs: [ 70 "libbase", 71 ], 72} 73 74cc_library_headers { 75 name: "libnetd_utils_headers", 76 export_include_dirs: ["include"], 77} 78