blob: f1669fde1909885adec4b11c89eaa2d108a97e77 [file] [log] [blame]
Pawin Vongmasa36653902018-11-15 00:10:25 -08001// DO NOT DEPEND ON THIS DIRECTLY
Pawin Vongmasad0f0e142018-11-15 03:36:28 -08002// use libcodec2_soft-defaults instead
Bob Badour56786ac2021-02-25 15:24:36 -08003package {
4 // See: http://go/android-license-faq
5 // A large-scale-change added 'default_applicable_licenses' to import
6 // all of the 'license_kinds' from "frameworks_av_license"
7 // to get the below license kinds:
8 // SPDX-license-identifier-Apache-2.0
9 default_applicable_licenses: ["frameworks_av_license"],
10}
11
S Vasudev Prasadee173172020-11-23 12:17:14 +053012cc_library {
Pawin Vongmasad0f0e142018-11-15 03:36:28 -080013 name: "libcodec2_soft_common",
14 defaults: ["libcodec2-impl-defaults"],
Pawin Vongmasa36653902018-11-15 00:10:25 -080015 vendor_available: true,
16
17 srcs: [
18 "SimpleC2Component.cpp",
19 "SimpleC2Interface.cpp",
20 ],
21
22 export_include_dirs: [
23 "include",
24 ],
25
26 export_shared_lib_headers: [
Pawin Vongmasad0f0e142018-11-15 03:36:28 -080027 "libsfplugin_ccodec_utils",
Pawin Vongmasa36653902018-11-15 00:10:25 -080028 ],
29
30 shared_libs: [
31 "libcutils", // for properties
Cindy Zhou544fc2b2020-12-03 06:24:18 -080032 "liblog", // for ALOG
Pawin Vongmasad0f0e142018-11-15 03:36:28 -080033 "libsfplugin_ccodec_utils", // for ImageCopy
Pawin Vongmasa36653902018-11-15 00:10:25 -080034 "libstagefright_foundation", // for Mutexed
35 ],
36
Ray Essickef519d72022-01-30 19:34:35 -080037 min_sdk_version: "29",
38 apex_available: [
39 "//apex_available:platform",
40 "com.android.media.swcodec",
41 ],
42
Pawin Vongmasa36653902018-11-15 00:10:25 -080043 sanitize: {
44 misc_undefined: [
45 "unsigned-integer-overflow",
46 "signed-integer-overflow",
47 ],
48 cfi: true,
Pawin Vongmasa36653902018-11-15 00:10:25 -080049 },
50
51 ldflags: ["-Wl,-Bsymbolic"],
52}
53
Harish Mahendrakarc76cdae2019-03-12 10:56:36 -070054filegroup {
55 name: "codec2_soft_exports",
Cindy Zhou544fc2b2020-12-03 06:24:18 -080056 srcs: ["exports.lds"],
Harish Mahendrakarc76cdae2019-03-12 10:56:36 -070057}
58
Pawin Vongmasa36653902018-11-15 00:10:25 -080059// public dependency for software codec implementation
60// to be used by code under media/codecs/* only as its stability is not guaranteed
61cc_defaults {
Pawin Vongmasad0f0e142018-11-15 03:36:28 -080062 name: "libcodec2_soft-defaults",
63 defaults: ["libcodec2-impl-defaults"],
Pawin Vongmasa36653902018-11-15 00:10:25 -080064 vendor_available: true,
Harish Mahendrakarc76cdae2019-03-12 10:56:36 -070065 version_script: ":codec2_soft_exports",
Pawin Vongmasa36653902018-11-15 00:10:25 -080066 export_shared_lib_headers: [
Pawin Vongmasad0f0e142018-11-15 03:36:28 -080067 "libsfplugin_ccodec_utils",
Pawin Vongmasa36653902018-11-15 00:10:25 -080068 ],
69
70 shared_libs: [
Pawin Vongmasad0f0e142018-11-15 03:36:28 -080071 "libcodec2_soft_common",
Pawin Vongmasa36653902018-11-15 00:10:25 -080072 "libcutils", // for properties
73 "liblog", // for ALOG
Pawin Vongmasad0f0e142018-11-15 03:36:28 -080074 "libsfplugin_ccodec_utils", // for ImageCopy
Pawin Vongmasa36653902018-11-15 00:10:25 -080075 "libstagefright_foundation", // for ColorUtils and MIME
Pawin Vongmasa36653902018-11-15 00:10:25 -080076 ],
77
78 cflags: [
79 "-Wall",
80 "-Werror",
81 ],
82
83 ldflags: ["-Wl,-Bsymbolic"],
Ray Essickef519d72022-01-30 19:34:35 -080084
85 min_sdk_version: "29",
86 apex_available: [
87 "//apex_available:platform",
88 "com.android.media.swcodec",
89 ],
Pawin Vongmasa36653902018-11-15 00:10:25 -080090}
91
92// public dependency for software codec implementation
93// to be used by code under media/codecs/* only
94cc_defaults {
Pawin Vongmasad0f0e142018-11-15 03:36:28 -080095 name: "libcodec2_soft_sanitize_all-defaults",
Pawin Vongmasa36653902018-11-15 00:10:25 -080096
97 sanitize: {
98 misc_undefined: [
99 "unsigned-integer-overflow",
100 "signed-integer-overflow",
101 ],
102 cfi: true,
Pawin Vongmasa36653902018-11-15 00:10:25 -0800103 },
104}
105
106// public dependency for software codec implementation
107// to be used by code under media/codecs/* only
108cc_defaults {
Pawin Vongmasad0f0e142018-11-15 03:36:28 -0800109 name: "libcodec2_soft_sanitize_signed-defaults",
Pawin Vongmasa36653902018-11-15 00:10:25 -0800110
111 sanitize: {
112 misc_undefined: [
113 "signed-integer-overflow",
114 ],
Cindy Zhou544fc2b2020-12-03 06:24:18 -0800115 },
116}
117
118cc_defaults {
119 name: "libcodec2_soft_sanitize_cfi-defaults",
120
121 sanitize: {
Pawin Vongmasa36653902018-11-15 00:10:25 -0800122 cfi: true,
Cindy Zhou544fc2b2020-12-03 06:24:18 -0800123 config: {
124 cfi_assembly_support: true,
125 },
Pawin Vongmasa36653902018-11-15 00:10:25 -0800126 },
127}
128
129// TEMP: used by cheets2 project - remove when no longer used
S Vasudev Prasadee173172020-11-23 12:17:14 +0530130cc_library {
Pawin Vongmasad0f0e142018-11-15 03:36:28 -0800131 name: "libcodec2_simple_component",
Pawin Vongmasa36653902018-11-15 00:10:25 -0800132 vendor_available: true,
133
134 srcs: [
135 "SimpleC2Interface.cpp",
136 ],
137
138 local_include_dirs: [
139 "include",
140 ],
141
142 export_include_dirs: [
143 "include",
144 ],
145
146 shared_libs: [
Pawin Vongmasad0f0e142018-11-15 03:36:28 -0800147 "libcodec2",
148 "libcodec2_vndk",
Pawin Vongmasa36653902018-11-15 00:10:25 -0800149 "libcutils",
150 "liblog",
Pawin Vongmasa36653902018-11-15 00:10:25 -0800151 "libstagefright_foundation",
152 "libutils",
153 ],
154
155 sanitize: {
156 misc_undefined: [
157 "unsigned-integer-overflow",
158 "signed-integer-overflow",
159 ],
160 cfi: true,
Pawin Vongmasa36653902018-11-15 00:10:25 -0800161 },
162
163 ldflags: ["-Wl,-Bsymbolic"],
164}