blob: 5b845f9f89d74f49aa0f2fe93cc5dad41a01a67e
1 | # Copyright (C) 2011 Amlogic Inc |
2 | # |
3 | # Licensed under the Apache License, Version 2.0 (the "License"); |
4 | # you may not use this file except in compliance with the License. |
5 | # You may obtain a copy of the License at |
6 | # |
7 | # http://www.apache.org/licenses/LICENSE-2.0 |
8 | # |
9 | # Unless required by applicable law or agreed to in writing, software |
10 | # distributed under the License is distributed on an "AS IS" BASIS, |
11 | # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
12 | # See the License for the specific language governing permissions and |
13 | # limitations under the License. |
14 | |
15 | # |
16 | # This file is the build configuration for a full Android |
17 | # build for Meson reference board. |
18 | # |
19 | |
20 | # Dynamic enable start/stop zygote_secondary in 64bits |
21 | # and 32bit system, default closed |
22 | #TARGET_DYNAMIC_ZYGOTE_SECONDARY_ENABLE := true |
23 | |
24 | # Inherit from those products. Most specific first. |
25 | ifeq ($(ANDROID_BUILD_TYPE), 64) |
26 | ifeq ($(TARGET_DYNAMIC_ZYGOTE_SECONDARY_ENABLE), true) |
27 | $(call inherit-product, device/amlogic/common/dynamic_zygote_seondary/dynamic_zygote_64_bit.mk) |
28 | else |
29 | $(call inherit-product, build/target/product/core_64_bit.mk) |
30 | endif |
31 | endif |
32 | |
33 | $(call inherit-product, device/amlogic/common/products/mbox/product_mbox.mk) |
34 | $(call inherit-product, device/amlogic/braun/device.mk) |
35 | $(call inherit-product-if-exists, vendor/google/products/gms.mk) |
36 | $(call inherit-product, device/amlogic/braun/vendor_prop.mk) |
37 | TARGET_WITH_MEDIA_EXT_LEVEL := 3 |
38 | |
39 | ######################################################################### |
40 | # |
41 | # media ext |
42 | # |
43 | ######################################################################### |
44 | ifeq ($(TARGET_WITH_MEDIA_EXT_LEVEL), 1) |
45 | TARGET_WITH_MEDIA_EXT :=true |
46 | TARGET_WITH_SWCODEC_EXT :=true |
47 | else |
48 | ifeq ($(TARGET_WITH_MEDIA_EXT_LEVEL), 2) |
49 | TARGET_WITH_MEDIA_EXT :=true |
50 | TARGET_WITH_CODEC_EXT := true |
51 | else |
52 | ifeq ($(TARGET_WITH_MEDIA_EXT_LEVEL), 3) |
53 | TARGET_WITH_MEDIA_EXT :=true |
54 | TARGET_WITH_SWCODEC_EXT := true |
55 | TARGET_WITH_CODEC_EXT := true |
56 | TARGET_WITH_PLAYERS_EXT :=true |
57 | endif |
58 | endif |
59 | endif |
60 | |
61 | # braun: |
62 | |
63 | PRODUCT_PROPERTY_OVERRIDES += \ |
64 | ro.hdmi.device_type=4 \ |
65 | persist.sys.hdmi.keep_awake=false |
66 | |
67 | PRODUCT_NAME := braun |
68 | PRODUCT_DEVICE := braun |
69 | PRODUCT_BRAND := Amlogic |
70 | PRODUCT_MODEL := braun |
71 | PRODUCT_MANUFACTURER := Amlogic |
72 | |
73 | TARGET_KERNEL_BUILT_FROM_SOURCE := false |
74 | |
75 | PRODUCT_TYPE := mbox |
76 | |
77 | WITH_LIBPLAYER_MODULE := false |
78 | |
79 | OTA_UP_PART_NUM_CHANGED := true |
80 | |
81 | BOARD_AML_VENDOR_PATH := vendor/amlogic/common/ |
82 | |
83 | BOARD_WIDEVINE_TA_PATH := vendor/amlogic/ |
84 | |
85 | AB_OTA_UPDATER :=true |
86 | BUILD_WITH_AVB := true |
87 | |
88 | ifeq ($(BUILD_WITH_AVB),true) |
89 | #BOARD_AVB_ENABLE := true |
90 | BOARD_BUILD_DISABLED_VBMETAIMAGE := true |
91 | BOARD_AVB_ALGORITHM := SHA256_RSA2048 |
92 | BOARD_AVB_KEY_PATH := device/amlogic/common/security/testkey_rsa2048.pem |
93 | BOARD_AVB_ROLLBACK_INDEX := 0 |
94 | endif |
95 | |
96 | ifeq ($(AB_OTA_UPDATER),true) |
97 | AB_OTA_PARTITIONS := \ |
98 | boot \ |
99 | system \ |
100 | vendor \ |
101 | odm |
102 | |
103 | TARGET_BOOTLOADER_CONTROL_BLOCK := true |
104 | TARGET_NO_RECOVERY := true |
105 | ifneq ($(BUILD_WITH_AVB),true) |
106 | TARGET_PARTITION_DTSI := partition_mbox_ab.dtsi |
107 | else |
108 | TARGET_PARTITION_DTSI := partition_mbox_ab_avb.dtsi |
109 | endif |
110 | else |
111 | TARGET_NO_RECOVERY := false |
112 | |
113 | BOARD_BUILD_SYSTEM_ROOT_IMAGE := true |
114 | |
115 | ifeq ($(ANDROID_BUILD_TYPE), 64) |
116 | TARGET_PARTITION_DTSI := partition_mbox_normal_P_64.dtsi |
117 | else |
118 | TARGET_PARTITION_DTSI := partition_mbox_normal_P_32.dtsi |
119 | endif |
120 | |
121 | ifneq ($(BUILD_WITH_AVB),true) |
122 | TARGET_FIRMWARE_DTSI := firmware_normal.dtsi |
123 | else |
124 | ifeq ($(BOARD_BUILD_SYSTEM_ROOT_IMAGE), true) |
125 | ifeq ($(BOARD_BUILD_DISABLED_VBMETAIMAGE), true) |
126 | TARGET_FIRMWARE_DTSI := firmware_system.dtsi |
127 | else |
128 | TARGET_FIRMWARE_DTSI := firmware_avb_system.dtsi |
129 | endif |
130 | else |
131 | ifeq ($(BOARD_BUILD_DISABLED_VBMETAIMAGE), true) |
132 | TARGET_FIRMWARE_DTSI := firmware_normal.dtsi |
133 | else |
134 | TARGET_FIRMWARE_DTSI := firmware_avb.dtsi |
135 | endif |
136 | endif |
137 | endif |
138 | |
139 | BOARD_CACHEIMAGE_PARTITION_SIZE := 69206016 |
140 | BOARD_CACHEIMAGE_FILE_SYSTEM_TYPE := ext4 |
141 | endif |
142 | |
143 | #########Support compiling out encrypted zip/aml_upgrade_package.img directly |
144 | #PRODUCT_BUILD_SECURE_BOOT_IMAGE_DIRECTLY := true |
145 | PRODUCT_AML_SECUREBOOT_USERKEY := ./uboot/board/amlogic/p230_v1/aml-user-key.sig |
146 | PRODUCT_AML_SECUREBOOT_SIGNTOOL := ./uboot/fip/gxl/aml_encrypt_gxl |
147 | PRODUCT_AML_SECUREBOOT_SIGNBOOTLOADER := $(PRODUCT_AML_SECUREBOOT_SIGNTOOL) --bootsig \ |
148 | --amluserkey $(PRODUCT_AML_SECUREBOOT_USERKEY) \ |
149 | --aeskey enable |
150 | PRODUCT_AML_SECUREBOOT_SIGNIMAGE := $(PRODUCT_AML_SECUREBOOT_SIGNTOOL) --imgsig \ |
151 | --amluserkey $(PRODUCT_AML_SECUREBOOT_USERKEY) |
152 | PRODUCT_AML_SECUREBOOT_SIGBIN := $(PRODUCT_AML_SECUREBOOT_SIGNTOOL) --binsig \ |
153 | --amluserkey $(PRODUCT_AML_SECUREBOOT_USERKEY) |
154 | |
155 | ######################################################################## |
156 | # |
157 | # ATV |
158 | # |
159 | ######################################################################## |
160 | ifneq ($(BOARD_COMPILE_ATV),false) |
161 | BOARD_COMPILE_CTS := true |
162 | TARGET_BUILD_GOOGLE_ATV:= true |
163 | DONT_DEXPREOPT_PREBUILTS:= true |
164 | endif |
165 | ######################################################################## |
166 | |
167 | ######################################################################## |
168 | # |
169 | # CTS |
170 | # |
171 | ######################################################################## |
172 | ifeq ($(BOARD_COMPILE_CTS),true) |
173 | BOARD_WIDEVINE_OEMCRYPTO_LEVEL := 1 |
174 | BOARD_PLAYREADY_LEVEL := 1 |
175 | TARGET_BUILD_CTS:= true |
176 | TARGET_BUILD_NETFLIX:= true |
177 | endif |
178 | ######################################################################## |
179 | |
180 | ######################################################################### |
181 | # |
182 | # Dm-Verity |
183 | # |
184 | ######################################################################### |
185 | #BUILD_WITH_DM_VERITY := true |
186 | #TARGET_USE_SECURITY_DM_VERITY_MODE_WITH_TOOL := true |
187 | ifeq ($(TARGET_USE_SECURITY_DM_VERITY_MODE_WITH_TOOL), true) |
188 | BUILD_WITH_DM_VERITY := true |
189 | endif # ifeq ($(TARGET_USE_SECURITY_DM_VERITY_MODE_WITH_TOOL), true) |
190 | ifeq ($(BUILD_WITH_DM_VERITY), true) |
191 | PRODUCT_PACKAGES += \ |
192 | libfs_mgr \ |
193 | fs_mgr \ |
194 | slideshow |
195 | endif |
196 | |
197 | ifeq ($(BOARD_BUILD_SYSTEM_ROOT_IMAGE), true) |
198 | PRODUCT_COPY_FILES += \ |
199 | device/amlogic/braun/fstab.system.amlogic:$(TARGET_COPY_OUT_VENDOR)/etc/fstab.amlogic |
200 | else |
201 | ifneq ($(BOARD_USES_RECOVERY_AS_BOOT), true) |
202 | PRODUCT_COPY_FILES += \ |
203 | device/amlogic/braun/fstab.amlogic:root/fstab.amlogic |
204 | else |
205 | PRODUCT_COPY_FILES += \ |
206 | device/amlogic/braun/fstab.amlogic:recovery/root/fstab.amlogic |
207 | endif |
208 | endif |
209 | |
210 | ######################################################################### |
211 | # |
212 | # WiFi |
213 | # |
214 | ######################################################################### |
215 | |
216 | #MULTI_WIFI_SUPPORT := true |
217 | WIFI_MODULE := bcm4356 |
218 | WIFI_BUILD_IN := true |
219 | include device/amlogic/common/wifi.mk |
220 | |
221 | # Change this to match target country |
222 | # 11 North America; 14 Japan; 13 rest of world |
223 | PRODUCT_DEFAULT_WIFI_CHANNELS := 11 |
224 | |
225 | |
226 | ######################################################################### |
227 | # |
228 | # Bluetooth |
229 | # |
230 | ######################################################################### |
231 | |
232 | BOARD_HAVE_BLUETOOTH := true |
233 | BLUETOOTH_MODULE := bcm4356 |
234 | #MULTI_BLUETOOTH_SUPPORT := true |
235 | BCM_BLUETOOTH_LPM_ENABLE := true |
236 | include device/amlogic/common/bluetooth.mk |
237 | |
238 | |
239 | ######################################################################### |
240 | # |
241 | # ConsumerIr |
242 | # |
243 | ######################################################################### |
244 | |
245 | #PRODUCT_PACKAGES += \ |
246 | # consumerir.amlogic \ |
247 | # SmartRemote |
248 | #PRODUCT_COPY_FILES += \ |
249 | # frameworks/native/data/etc/android.hardware.consumerir.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/android.hardware.consumerir.xml |
250 | |
251 | |
252 | #PRODUCT_PACKAGES += libbt-vendor |
253 | |
254 | ifeq ($(SUPPORT_HDMIIN),true) |
255 | PRODUCT_PACKAGES += \ |
256 | libhdmiin \ |
257 | HdmiIn |
258 | endif |
259 | |
260 | PRODUCT_COPY_FILES += \ |
261 | frameworks/native/data/etc/android.hardware.ethernet.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/android.hardware.ethernet.xml |
262 | |
263 | # Audio |
264 | # |
265 | BOARD_ALSA_AUDIO=tiny |
266 | include device/amlogic/common/audio.mk |
267 | |
268 | ######################################################################### |
269 | # |
270 | # Camera |
271 | # |
272 | ######################################################################### |
273 | |
274 | ifneq ($(TARGET_BUILD_CTS), true) |
275 | PRODUCT_COPY_FILES += \ |
276 | frameworks/native/data/etc/android.hardware.camera.front.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/android.hardware.camera.front.xml \ |
277 | frameworks/native/data/etc/android.hardware.camera.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/android.hardware.camera.xml |
278 | endif |
279 | |
280 | |
281 | |
282 | ######################################################################### |
283 | # |
284 | # PlayReady DRM |
285 | # |
286 | ######################################################################### |
287 | #export BOARD_PLAYREADY_LEVEL=3 for PlayReady+NOTVP |
288 | #export BOARD_PLAYREADY_LEVEL=1 for PlayReady+OPTEE+TVP |
289 | ######################################################################### |
290 | # |
291 | # Verimatrix DRM |
292 | ########################################################################## |
293 | #verimatrix web |
294 | BUILD_WITH_VIEWRIGHT_WEB := false |
295 | #verimatrix stb |
296 | BUILD_WITH_VIEWRIGHT_STB := false |
297 | ######################################################################### |
298 | |
299 | |
300 | #DRM Widevine |
301 | ifeq ($(BOARD_WIDEVINE_OEMCRYPTO_LEVEL),) |
302 | BOARD_WIDEVINE_OEMCRYPTO_LEVEL := 3 |
303 | endif |
304 | |
305 | ifeq ($(BOARD_WIDEVINE_OEMCRYPTO_LEVEL), 1) |
306 | TARGET_USE_OPTEEOS := true |
307 | TARGET_USE_HW_KEYMASTER := true |
308 | endif |
309 | |
310 | $(call inherit-product, device/amlogic/common/media.mk) |
311 | |
312 | ######################################################################### |
313 | # |
314 | # Languages |
315 | # |
316 | ######################################################################### |
317 | |
318 | # For all locales, $(call inherit-product, build/target/product/languages_full.mk) |
319 | PRODUCT_LOCALES := en_US en_AU en_IN fr_FR it_IT es_ES et_EE de_DE nl_NL cs_CZ pl_PL ja_JP \ |
320 | zh_TW zh_CN zh_HK ru_RU ko_KR nb_NO es_US da_DK el_GR tr_TR pt_PT pt_BR rm_CH sv_SE bg_BG \ |
321 | ca_ES en_GB fi_FI hi_IN hr_HR hu_HU in_ID iw_IL lt_LT lv_LV ro_RO sk_SK sl_SI sr_RS uk_UA \ |
322 | vi_VN tl_PH ar_EG fa_IR th_TH sw_TZ ms_MY af_ZA zu_ZA am_ET hi_IN en_XA ar_XB fr_CA km_KH \ |
323 | lo_LA ne_NP si_LK mn_MN hy_AM az_AZ ka_GE my_MM mr_IN ml_IN is_IS mk_MK ky_KG eu_ES gl_ES \ |
324 | bn_BD ta_IN kn_IN te_IN uz_UZ ur_PK kk_KZ |
325 | |
326 | ################################################################################# |
327 | # |
328 | # PPPOE |
329 | # |
330 | ################################################################################# |
331 | ifneq ($(TARGET_BUILD_GOOGLE_ATV), true) |
332 | #BUILD_WITH_PPPOE := true |
333 | endif |
334 | |
335 | ifeq ($(BUILD_WITH_PPPOE),true) |
336 | PRODUCT_PACKAGES += \ |
337 | PPPoE \ |
338 | libpppoejni \ |
339 | libpppoe \ |
340 | pppoe_wrapper \ |
341 | pppoe \ |
342 | droidlogic.frameworks.pppoe \ |
343 | droidlogic.external.pppoe \ |
344 | droidlogic.software.pppoe.xml |
345 | PRODUCT_PROPERTY_OVERRIDES += \ |
346 | ro.platform.has.pppoe=true |
347 | endif |
348 | |
349 | ################################################################################# |
350 | # |
351 | # DEFAULT LOWMEMORYKILLER CONFIG |
352 | # |
353 | ################################################################################# |
354 | BUILD_WITH_LOWMEM_COMMON_CONFIG := true |
355 | |
356 | BOARD_USES_USB_PM := true |
357 | |
358 | |
359 | include device/amlogic/common/software.mk |
360 | ifeq ($(TARGET_BUILD_GOOGLE_ATV),true) |
361 | PRODUCT_PROPERTY_OVERRIDES += \ |
362 | ro.sf.lcd_density=320 |
363 | else |
364 | PRODUCT_PROPERTY_OVERRIDES += \ |
365 | ro.sf.lcd_density=240 |
366 | endif |
367 | |
368 | |
369 | ######################################################################### |
370 | # |
371 | # A/B update |
372 | # |
373 | ######################################################################### |
374 | ifeq ($(BUILD_WITH_AVB),true) |
375 | PRODUCT_PACKAGES += \ |
376 | bootctrl.avb \ |
377 | libavb_user |
378 | endif |
379 | |
380 | ifeq ($(AB_OTA_UPDATER),true) |
381 | PRODUCT_PACKAGES += \ |
382 | bootctrl.amlogic \ |
383 | bootctl |
384 | |
385 | PRODUCT_PACKAGES += \ |
386 | update_engine \ |
387 | update_engine_client \ |
388 | update_verifier \ |
389 | delta_generator \ |
390 | brillo_update_payload \ |
391 | android.hardware.boot@1.0-impl \ |
392 | android.hardware.boot@1.0-service |
393 | endif |
394 | ######################################################################### |
395 | # |
396 | # OpenGLES Version |
397 | # |
398 | ######################################################################### |
399 | PRODUCT_PROPERTY_OVERRIDES += \ |
400 | ro.opengles.version=131072 |
401 |