blob: 3e0afb8f25126691f07a5e0624d93701f4b4df5d [file] [log] [blame]
Pig02f678a2020-10-15 02:58:37 +08001// Bliss soong configs
2
Simon Shields4ed46052017-08-23 12:03:36 +10003bootstrap_go_package {
Jackeagled6811aa2019-09-24 08:26:40 +02004 name: "soong-bliss-generator",
5 pkgPath: "bliss/soong/generator",
Sam Mortimer80381b72018-09-18 15:56:14 -07006 deps: [
7 "blueprint",
8 "blueprint-pathtools",
9 "soong",
10 "soong-android",
11 "soong-shared",
12 ],
13 srcs: [
14 "generator/generator.go",
Rashed Abdel-Tawab9fa7e802018-09-18 21:53:24 -070015 "generator/variables.go",
Sam Mortimer80381b72018-09-18 15:56:14 -070016 ],
17 pluginFor: ["soong_build"],
18}
Rashed Abdel-Tawab9fa7e802018-09-18 21:53:24 -070019
Jackeagled6811aa2019-09-24 08:26:40 +020020bliss_generator {
Rashed Abdel-Tawab9fa7e802018-09-18 21:53:24 -070021 name: "generated_kernel_includes",
22
23 // The headers make command
Rashed Abdel-Tawabba5ea352019-09-07 17:01:13 -070024 cmd: "$(PATH_OVERRIDE_SOONG) $(KERNEL_MAKE_CMD) $(KERNEL_MAKE_FLAGS) -C $(TARGET_KERNEL_SOURCE) O=$(KERNEL_BUILD_OUT_PREFIX)$(genDir) ARCH=$(KERNEL_ARCH) $(KERNEL_CROSS_COMPILE) headers_install",
Rashed Abdel-Tawab9fa7e802018-09-18 21:53:24 -070025
26 // Directories that can be imported by a cc_* module generated_headers property
dianlujitao9dfd5f72020-03-03 17:26:32 +080027 export_include_dirs: [
dianlujitao83d2fa42020-06-28 22:16:44 +080028 "usr/audio/include/uapi",
dianlujitao9dfd5f72020-03-03 17:26:32 +080029 "usr/include",
30 "usr/include/audio/include/uapi",
Pigf6e0a852020-10-15 02:58:37 +080031 "usr/techpack/audio/include",
dianlujitao9dfd5f72020-03-03 17:26:32 +080032 ],
Rashed Abdel-Tawab9fa7e802018-09-18 21:53:24 -070033
34 // Sources for dependency tracking
35 dep_root: "$(TARGET_KERNEL_SOURCE)",
Pigf6e0a852020-10-15 02:58:37 +080036 dep_files: [
37 "Makefile",
38 "include/**/*",
39 "arch/$(KERNEL_ARCH)/include/**/*",
40 "techpack/audio/include/**/*",
41 ],
Rashed Abdel-Tawab9fa7e802018-09-18 21:53:24 -070042}
43
44cc_library_headers {
45 name: "generated_kernel_headers",
46 generated_headers: ["generated_kernel_includes"],
47 export_generated_headers: ["generated_kernel_includes"],
48 vendor_available: true,
LuK133743442c22019-09-09 21:58:19 +020049 recovery_available: true,
Rashed Abdel-Tawab9fa7e802018-09-18 21:53:24 -070050}
Pig02f678a2020-10-15 02:58:37 +080051
52// Target platform agnostic config modules
53soong_config_module_type {
54 name: "gralloc_10_usage_bits",
55 module_type: "cc_defaults",
56 config_namespace: "blissGlobalVars",
57 value_variables: ["additional_gralloc_10_usage_bits"],
58 properties: ["cppflags"],
59}
60
61gralloc_10_usage_bits {
62 name: "gralloc_10_usage_bits_defaults",
63 soong_config_variables: {
64 additional_gralloc_10_usage_bits: {
65 cppflags: ["-DADDNL_GRALLOC_10_USAGE_BITS=%s"],
66 },
67 },
68}
69
70soong_config_module_type {
71 name: "target_process_sdk_version_overrides",
72 module_type: "cc_defaults",
73 config_namespace: "blissGlobalVars",
74 value_variables: ["target_process_sdk_version_override"],
75 properties: ["cppflags"],
76}
77
78target_process_sdk_version_overrides {
79 name: "process_sdk_version_overrides_defaults",
80 soong_config_variables: {
81 target_process_sdk_version_override: {
82 cppflags: ["-DSDK_VERSION_OVERRIDES=\"%s\""],
83 },
84 },
85}
86
87soong_config_module_type {
88 name: "target_shim_libs",
89 module_type: "cc_defaults",
90 config_namespace: "blissGlobalVars",
91 value_variables: ["target_ld_shim_libs"],
92 properties: ["cppflags"],
93}
94
95target_shim_libs {
96 name: "shim_libs_defaults",
97 soong_config_variables: {
98 target_ld_shim_libs: {
99 cppflags: ["-DLD_SHIM_LIBS=\"%s\""],
100 },
101 },
102}
103
104soong_config_module_type {
105 name: "vendor_init",
106 module_type: "cc_defaults",
107 config_namespace: "blissGlobalVars",
108 value_variables: ["target_init_vendor_lib"],
109 properties: ["whole_static_libs"],
110}
111
112vendor_init {
113 name: "vendor_init_defaults",
114 soong_config_variables: {
115 target_init_vendor_lib: {
116 whole_static_libs: ["%s"],
117 },
118 },
119}
120
121soong_config_module_type {
122 name: "surfaceflinger_fod_lib",
123 module_type: "cc_defaults",
124 config_namespace: "blissGlobalVars",
125 value_variables: ["target_surfaceflinger_fod_lib"],
126 properties: [
127 "cppflags",
128 "whole_static_libs",
129 ],
130}
131
132surfaceflinger_fod_lib {
133 name: "surfaceflinger_fod_lib_defaults",
134 soong_config_variables: {
135 target_surfaceflinger_fod_lib: {
136 cppflags: ["-DTARGET_PROVIDES_FOD_LIB"],
137 whole_static_libs: ["%s"],
138 },
139 },
140}
141
142soong_config_module_type {
143 name: "ignores_ftp_pptp_conntrack_failure_defaults",
144 module_type: "cc_defaults",
145 config_namespace: "blissGlobalVars",
146 bool_variables: ["ignores_ftp_pptp_conntrack_failure"],
147 properties: ["cppflags"],
148}
149
150ignores_ftp_pptp_conntrack_failure_defaults {
151 name: "ignores_ftp_pptp_conntrack_failure",
152 soong_config_variables: {
153 ignores_ftp_pptp_conntrack_failure: {
Aayush Gupta3f8f66c2020-10-21 16:29:53 +0530154 cppflags: ["-DIGNORES_FTP_PPTP_CONNTRACK_FAILURE"],
Pig02f678a2020-10-15 02:58:37 +0800155 },
156 },
157}
158
159soong_config_module_type {
160 name: "needs_netd_direct_connect_rule",
161 module_type: "cc_defaults",
162 config_namespace: "blissGlobalVars",
163 bool_variables: ["needs_netd_direct_connect_rule"],
164 properties: ["cppflags"],
165}
166
167needs_netd_direct_connect_rule {
168 name: "needs_netd_direct_connect_rule_defaults",
169 soong_config_variables: {
170 needs_netd_direct_connect_rule: {
171 cppflags: ["-DNEEDS_NETD_DIRECT_CONNECT_RULE"],
172 },
173 },
174}
175
176soong_config_module_type {
177 name: "no_cameraserver",
178 module_type: "cc_defaults",
179 config_namespace: "blissGlobalVars",
180 bool_variables: ["has_legacy_camera_hal1"],
181 properties: [
182 "cppflags",
183 ],
184}
185
186no_cameraserver {
187 name: "no_cameraserver_defaults",
188 soong_config_variables: {
189 has_legacy_camera_hal1: {
190 cppflags: [
191 "-DNO_CAMERA_SERVER",
192 "-Wno-overloaded-virtual",
193 ],
194 },
195 },
196}
197
198soong_config_module_type {
199 name: "camera_in_mediaserver",
200 module_type: "cc_defaults",
201 config_namespace: "blissGlobalVars",
202 bool_variables: ["has_legacy_camera_hal1"],
203 properties: [
204 "overrides",
205 "shared_libs",
206 ],
207}
208
209camera_in_mediaserver {
210 name: "camera_in_mediaserver_defaults",
211 defaults: ["no_cameraserver_defaults"],
212 soong_config_variables: {
213 has_legacy_camera_hal1: {
214 overrides: ["cameraserver"],
215 shared_libs: [
216 "android.hardware.camera.common@1.0",
217 "android.hardware.camera.device@3.4",
218 "android.hardware.camera.provider@2.6",
219 "libcameraservice",
220 "libgui",
221 ],
222 },
223 },
224}
225
226soong_config_module_type {
227 name: "bootloader_message_offset",
228 module_type: "cc_defaults",
229 config_namespace: "blissGlobalVars",
230 value_variables: ["bootloader_message_offset"],
Alessandro Astonebe38c0a2020-10-01 13:01:36 +0200231 properties: [
232 "cflags",
233 "export_cflags",
234 ],
Pig02f678a2020-10-15 02:58:37 +0800235}
236
237bootloader_message_offset {
238 name: "bootloader_message_offset_defaults",
239 soong_config_variables: {
240 bootloader_message_offset: {
241 cflags: ["-DBOARD_RECOVERY_BLDRMSG_OFFSET=%s"],
Alessandro Astonebe38c0a2020-10-01 13:01:36 +0200242 export_cflags: ["-DBOARD_RECOVERY_BLDRMSG_OFFSET=%s"],
Pig02f678a2020-10-15 02:58:37 +0800243 },
244 },
245}
246
247soong_config_module_type {
248 name: "camera_parameter_library",
249 module_type: "cc_defaults",
250 config_namespace: "blissGlobalVars",
251 value_variables: ["uses_camera_parameter_lib"],
252 properties: ["whole_static_libs"],
253}
254
255camera_parameter_library {
256 name: "camera_parameter_library_defaults",
257 soong_config_variables: {
258 uses_camera_parameter_lib: {
259 whole_static_libs: ["%s"],
260 },
261 },
262}
263
264// NVIDIA specific config modules
265soong_config_module_type {
266 name: "nvidia_enhancements",
267 module_type: "cc_defaults",
268 config_namespace: "blissNvidiaVars",
269 bool_variables: ["uses_nvidia_enhancements"],
270 properties: ["cppflags"],
271}
272
273nvidia_enhancements {
274 name: "nvidia_enhancements_defaults",
275 soong_config_variables: {
276 uses_nvidia_enhancements: {
277 cppflags: ["-DNV_ANDROID_FRAMEWORK_ENHANCEMENTS"],
278 },
279 },
280}
281
282// QCOM specific config modules
283soong_config_module_type {
284 name: "librmnetctl_pre_uplink",
285 module_type: "cc_defaults",
286 config_namespace: "blissQcomVars",
287 bool_variables: ["uses_pre_uplink_features_netmgrd"],
288 properties: ["cflags"],
289}
290
291librmnetctl_pre_uplink {
292 name: "librmnetctl_pre_uplink_defaults",
293 soong_config_variables: {
294 uses_pre_uplink_features_netmgrd: {
295 cflags: ["-DNO_UPLINK_FEATURES"],
296 },
297 },
298}
299
300soong_config_module_type {
301 name: "qti_camera_device",
302 module_type: "cc_defaults",
303 config_namespace: "blissQcomVars",
304 bool_variables: ["uses_qti_camera_device"],
305 properties: [
306 "cppflags",
307 "shared_libs",
308 ],
309}
310
311qti_camera_device {
312 name: "qti_camera_device_defaults",
313 soong_config_variables: {
314 uses_qti_camera_device: {
315 cppflags: ["-DQTI_CAMERA_DEVICE"],
316 shared_libs: ["vendor.qti.hardware.camera.device@1.0"],
317 },
318 },
319}
320
321soong_config_module_type {
322 name: "extended_compress_format",
323 module_type: "cc_defaults",
324 config_namespace: "blissQcomVars",
325 bool_variables: ["supports_extended_compress_format"],
326 properties: ["cflags"],
327}
328
329extended_compress_format {
330 name: "extended_compress_format_defaults",
331 soong_config_variables: {
332 supports_extended_compress_format: {
333 cflags: ["-DENABLE_EXTENDED_COMPRESS_FORMAT"],
334 },
335 },
336}
337
338soong_config_module_type {
339 name: "vold_hw_fde",
340 module_type: "cc_defaults",
341 config_namespace: "blissQcomVars",
342 bool_variables: ["supports_hw_fde"],
343 properties: [
344 "cflags",
345 "header_libs",
346 "shared_libs",
347 ],
348}
349
350vold_hw_fde {
351 name: "vold_hw_fde_defaults",
352 soong_config_variables: {
353 supports_hw_fde: {
354 cflags: ["-DCONFIG_HW_DISK_ENCRYPTION"],
355 header_libs: ["libcryptfs_hw_headers"],
356 shared_libs: ["libcryptfs_hw"],
357 },
358 },
359}
360
361soong_config_module_type {
362 name: "vold_hw_fde_perf",
363 module_type: "cc_defaults",
364 config_namespace: "blissQcomVars",
365 bool_variables: ["supports_hw_fde_perf"],
366 properties: [
367 "cflags",
368 "shared_libs",
369 ],
370}
371
372vold_hw_fde_perf {
373 name: "vold_hw_fde_perf_defaults",
374 soong_config_variables: {
375 supports_hw_fde_perf: {
376 cflags: ["-DCONFIG_HW_DISK_ENCRYPT_PERF"],
377 shared_libs: ["libcryptfs_hw"],
378 },
379 },
380}
381
382soong_config_module_type {
383 name: "qti_cryptfshw_qsee",
384 module_type: "cc_defaults",
385 config_namespace: "blissQcomVars",
386 bool_variables: ["should_wait_for_qsee"],
387 properties: ["cflags"],
388}
389
390qti_cryptfshw_qsee {
391 name: "qti_cryptfshw_qsee_defaults",
392 soong_config_variables: {
393 should_wait_for_qsee: {
394 cflags: ["-DWAIT_FOR_QSEE"],
395 },
396 },
397}
398
399soong_config_module_type {
400 name: "surfaceflinger_qcom_extensions",
401 module_type: "cc_defaults",
402 config_namespace: "blissQcomVars",
403 value_variables: ["qcom_soong_namespace"],
404 properties: [
405 "cppflags",
406 "header_libs",
407 ],
408}
409
410surfaceflinger_qcom_extensions {
411 name: "surfaceflinger_qcom_ext_defaults",
412 soong_config_variables: {
413 qcom_soong_namespace: {
414 cppflags: ["-DQCOM_UM_FAMILY"],
415 header_libs: ["//%s/display:display_intf_headers"],
416 },
417 },
418}
419
420soong_config_module_type {
421 name: "stagefright_qcom_legacy",
422 module_type: "cc_defaults",
423 config_namespace: "blissQcomVars",
424 bool_variables: ["uses_qcom_bsp_legacy"],
425 properties: ["cppflags"],
426}
427
428stagefright_qcom_legacy {
429 name: "stagefright_qcom_legacy_defaults",
430 soong_config_variables: {
431 uses_qcom_bsp_legacy: {
432 cppflags: ["-DQCOM_BSP_LEGACY"],
433 },
434 },
435}