blob: 3da6fe7c4bc62d0daa9c0e864a08e93b63da1dbb [file] [log] [blame]
Alex Deymoe8ed6942017-01-11 16:54:52 -08001// Copyright 2015 The Android Open Source Project
2
Tianjie Xud5e379c2020-03-06 12:30:18 -08003cc_defaults {
4 name: "libfec_default",
5
6 cflags: [
7 "-Wall",
8 "-Werror",
9 "-O3",
10 "-D_LARGEFILE64_SOURCE",
11 ],
12
Alex Deymoe8ed6942017-01-11 16:54:52 -080013 srcs: [
14 "fec_open.cpp",
15 "fec_read.cpp",
16 "fec_verity.cpp",
17 "fec_process.cpp",
18 ],
Tianjie Xud5e379c2020-03-06 12:30:18 -080019
Alex Deymoe8ed6942017-01-11 16:54:52 -080020 export_include_dirs: ["include"],
21 // Exported header include/fec/io.h includes crypto_utils headers.
Tao Bao3882cf72018-08-13 22:42:55 -070022 export_shared_lib_headers: ["libcrypto_utils"],
23
24 shared_libs: [
25 "libbase",
26 "libcrypto",
27 "libcrypto_utils",
28 "libcutils",
29 "libext4_utils",
30 "libsquashfs_utils",
31 ],
Alex Deymoe8ed6942017-01-11 16:54:52 -080032
33 static_libs: [
Alex Deymoe8ed6942017-01-11 16:54:52 -080034 "libfec_rs",
Alex Deymoe8ed6942017-01-11 16:54:52 -080035 ],
36
37 target: {
38 host: {
Tianjie Xud5e379c2020-03-06 12:30:18 -080039 cflags: [
40 "-D_GNU_SOURCE",
41 "-DFEC_NO_KLOG",
42 ],
Alex Deymoe8ed6942017-01-11 16:54:52 -080043 },
Dan Willemsen2bfbe942017-10-02 10:41:11 -070044 linux_glibc: {
Romain Guyc1386d32017-06-07 17:05:03 -070045 sanitize: {
46 misc_undefined: ["integer"],
47 },
48 },
Alex Deymoe8ed6942017-01-11 16:54:52 -080049 },
Alex Deymoe8ed6942017-01-11 16:54:52 -080050}
Tianjie Xud5e379c2020-03-06 12:30:18 -080051
52cc_library {
53 name: "libfec",
54 defaults: ["libfec_default"],
55 host_supported: true,
56 recovery_available: true,
57
58 target: {
59 linux: {
60 srcs: [
61 "avb_utils.cpp",
62 ],
63 static_libs: [
64 "libavb",
65 ],
66 },
67
68 // libavb isn't available on mac.
69 darwin: {
70 srcs: [
71 "avb_utils_stub.cpp",
72 ],
73 },
74 },
75}