1 # 2 # Copyright 2013 The Android Open-Source Project 3 # 4 # Licensed under the Apache License, Version 2.0 (the "License"); 5 # you may not use this file except in compliance with the License. 6 # You may obtain a copy of the License at 7 # 8 # http://www.apache.org/licenses/LICENSE-2.0 9 # 10 # Unless required by applicable law or agreed to in writing, software 11 # distributed under the License is distributed on an "AS IS" BASIS, 12 # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 # See the License for the specific language governing permissions and 14 # limitations under the License. 15 # 16 17 KERNEL_SRC_DIR ?= linux/kernel-fugu 18 KERNEL_CFG_NAME ?= fugu 19 TARGET_KERNEL_ARCH ?= x86_64 20 21 22 # Check for availability of kernel source 23 ifneq ($(wildcard $(KERNEL_SRC_DIR)/Makefile),) 24 # Give precedence to TARGET_PREBUILT_KERNEL 25 ifeq ($(TARGET_PREBUILT_KERNEL),) 26 TARGET_KERNEL_BUILT_FROM_SOURCE := true 27 endif 28 endif 29 30 ifneq ($(TARGET_KERNEL_BUILT_FROM_SOURCE), true) 31 # Use prebuilt kernel 32 ifeq ($(TARGET_PREBUILT_KERNEL),) 33 LOCAL_KERNEL := device/asus/fugu-kernel/bzImage 34 else 35 LOCAL_KERNEL := $(TARGET_PREBUILT_KERNEL) 36 endif 37 38 PRODUCT_COPY_FILES += \ 39 $(LOCAL_KERNEL):kernel 40 41 endif #TARGET_KERNEL_BUILT_FROM_SOURCE 42 43 # Need AppWidget permission to prevent from Launcher's crash. 44 # TODO(pattjin): Remove this when the TV Launcher is used, which does not support AppWidget. 45 PRODUCT_COPY_FILES += \ 46 frameworks/native/data/etc/android.software.app_widgets.xml:system/etc/permissions/android.software.app_widgets.xml 47 48 PRODUCT_AAPT_CONFIG := normal large xlarge hdpi xhdpi 49 PRODUCT_AAPT_PREF_CONFIG := xhdpi 50 51 # xhdpi, while we are hardcoding the 1080 resolution. 52 # when we start doing 720 as well, will need to stop hardcoding this. 53 PRODUCT_PROPERTY_OVERRIDES += \ 54 ro.sf.lcd_density=320 55 56 # There may be a cleaner way to do this. 57 PRODUCT_PROPERTY_OVERRIDES += \ 58 dalvik.vm.heapstartsize=8m \ 59 dalvik.vm.heapgrowthlimit=128m \ 60 dalvik.vm.heapsize=174m 61 62 $(call inherit-product-if-exists, frameworks/native/build/tablet-10in-xhdpi-2048-dalvik-heap.mk) 63 64 PRODUCT_CHARACTERISTICS := nosdcard,tv 65 66 DEVICE_PACKAGE_OVERLAYS := \ 67 device/asus/fugu/overlay 68 69 PRODUCT_COPY_FILES += \ 70 device/asus/fugu/fstab.fugu:root/fstab.fugu \ 71 device/asus/fugu/init.fugu.rc:root/init.fugu.rc \ 72 device/asus/fugu/init.fugu.usb.rc:root/init.fugu.usb.rc \ 73 device/asus/fugu/ueventd.fugu.rc:root/ueventd.fugu.rc \ 74 device/asus/fugu/init.recovery.fugu.rc:root/init.recovery.fugu.rc 75 76 # Audio 77 PRODUCT_PACKAGES += \ 78 libtinyalsa \ 79 audio.primary.fugu \ 80 audio.stub.default \ 81 audio.usb.default \ 82 audio.a2dp.default \ 83 audio.r_submix.default \ 84 libaudio-resampler 85 86 PRODUCT_PACKAGES += \ 87 android.hardware.audio@2.0-impl \ 88 android.hardware.audio.effect@2.0-impl 89 90 # Keymaster HAL 91 PRODUCT_PACKAGES += \ 92 android.hardware.keymaster@3.0-impl 93 94 # Dumpstate HAL 95 PRODUCT_PACKAGES += \ 96 android.hardware.dumpstate@1.0-service.fugu 97 98 USE_CUSTOM_AUDIO_POLICY := 1 99 USE_XML_AUDIO_POLICY_CONF := 1 100 101 # specific management of audio_policy.conf 102 PRODUCT_COPY_FILES += \ 103 device/asus/fugu/audio_policy_configuration.xml:$(TARGET_COPY_OUT_VENDOR)/etc/audio_policy_configuration.xml \ 104 frameworks/av/services/audiopolicy/config/a2dp_audio_policy_configuration.xml:$(TARGET_COPY_OUT_VENDOR)/etc/a2dp_audio_policy_configuration.xml \ 105 frameworks/av/services/audiopolicy/config/r_submix_audio_policy_configuration.xml:$(TARGET_COPY_OUT_VENDOR)/etc/r_submix_audio_policy_configuration.xml \ 106 frameworks/av/services/audiopolicy/config/usb_audio_policy_configuration.xml:$(TARGET_COPY_OUT_VENDOR)/etc/usb_audio_policy_configuration.xml \ 107 frameworks/av/services/audiopolicy/config/default_volume_tables.xml:$(TARGET_COPY_OUT_VENDOR)/etc/default_volume_tables.xml \ 108 frameworks/av/services/audiopolicy/config/audio_policy_volumes.xml:$(TARGET_COPY_OUT_VENDOR)/etc/audio_policy_volumes.xml 109 110 # Hdmi CEC: Fugu works as a playback device (4). 111 PRODUCT_PROPERTY_OVERRIDES += ro.hdmi.device_type=4 112 113 # Hdmi CEC: Disable 'Set Menu Language' feature. 114 PRODUCT_PROPERTY_OVERRIDES += ro.hdmi.set_menu_language=false 115 116 # Keep secure decoders in mediaserver process 117 PRODUCT_PROPERTY_OVERRIDES += media.stagefright.less-secure=true 118 119 # Boot Animation 120 PRODUCT_COPY_FILES += \ 121 device/asus/fugu/bootanimation-580-256col.zip:system/media/bootanimation.zip 122 123 # Bluetooth 124 PRODUCT_PACKAGES += \ 125 bt_bcm4354 126 127 PRODUCT_COPY_FILES += \ 128 device/asus/fugu/bt_vendor.conf:system/etc/bluetooth/bt_vendor.conf 129 130 # Bluetooth HAL 131 PRODUCT_PACKAGES += \ 132 libbt-vendor \ 133 android.hardware.bluetooth@1.0-impl 134 135 # IMG graphics 136 PRODUCT_PACKAGES += \ 137 IMG_graphics \ 138 hwcomposer.moorefield 139 140 PRODUCT_PACKAGES += \ 141 android.hardware.graphics.allocator@2.0-impl \ 142 android.hardware.graphics.composer@2.1-impl \ 143 android.hardware.graphics.mapper@2.0-impl 144 145 # RenderScript HAL 146 PRODUCT_PACKAGES += \ 147 android.hardware.renderscript@1.0-impl 148 149 # Video 150 PRODUCT_COPY_FILES += \ 151 device/asus/fugu/media_profiles.xml:system/etc/media_profiles.xml \ 152 device/asus/fugu/wrs_omxil_components.list:system/etc/wrs_omxil_components.list \ 153 frameworks/av/media/libstagefright/data/media_codecs_google_audio.xml:system/etc/media_codecs_google_audio.xml \ 154 frameworks/av/media/libstagefright/data/media_codecs_google_tv.xml:system/etc/media_codecs_google_tv.xml \ 155 frameworks/av/media/libstagefright/data/media_codecs_google_video_le.xml:system/etc/media_codecs_google_video_le.xml \ 156 device/asus/fugu/media_codecs.xml:system/etc/media_codecs.xml \ 157 device/asus/fugu/media_codecs_performance.xml:system/etc/media_codecs_performance.xml \ 158 device/asus/fugu/mfx_omxil_core.conf:system/etc/mfx_omxil_core.conf \ 159 device/asus/fugu/video_isv_profile.xml:system/etc/video_isv_profile.xml \ 160 device/asus/fugu/codec_resources_limitation.xml:system/etc/codec_resources_limitation.xml 161 162 # Default OMX service to non-Treble 163 PRODUCT_PROPERTY_OVERRIDES += \ 164 persist.media.treble_omx=false 165 166 # psb video 167 PRODUCT_PACKAGES += \ 168 pvr_drv_video 169 170 # Media SDK and OMX IL components 171 PRODUCT_PACKAGES += \ 172 libmfxsw32 \ 173 libmfx_omx_core \ 174 libmfx_omx_components_sw \ 175 libgabi++-mfx \ 176 libstlport-mfx 177 178 #video firmware 179 PRODUCT_PACKAGES += \ 180 msvdx.bin.0008.0000.0000 \ 181 msvdx.bin.0008.0000.0001 \ 182 msvdx.bin.0008.0002.0001 \ 183 msvdx.bin.0008.0000.0002 \ 184 msvdx.bin.000c.0001.0001 \ 185 topaz.bin.0008.0000.0000 \ 186 topaz.bin.0008.0000.0001 \ 187 topaz.bin.0008.0000.0002 \ 188 topaz.bin.0008.0002.0001 \ 189 topaz.bin.000c.0001.0001 \ 190 vsp.bin.0008.0000.0000 \ 191 vsp.bin.0008.0000.0001 \ 192 vsp.bin.0008.0000.0002 \ 193 vsp.bin.0008.0002.0001 \ 194 vsp.bin.000c.0001.0001 195 # libva 196 PRODUCT_PACKAGES += \ 197 libva \ 198 libva-android \ 199 libva-tpi \ 200 vainfo 201 202 #libstagefrighthw 203 PRODUCT_PACKAGES += \ 204 libstagefrighthw 205 206 # libmix 207 PRODUCT_PACKAGES += \ 208 libmixvbp_mpeg4 \ 209 libmixvbp_h264 \ 210 libmixvbp_h264secure \ 211 libmixvbp_vc1 \ 212 libmixvbp_vp8 \ 213 libmixvbp_mpeg2 \ 214 libmixvbp \ 215 libva_videodecoder \ 216 libva_videoencoder 217 218 PRODUCT_PACKAGES += \ 219 libwrs_omxil_common \ 220 libwrs_omxil_core_pvwrapped \ 221 libOMXVideoDecoderAVC \ 222 libOMXVideoDecoderH263 \ 223 libOMXVideoDecoderMPEG4 \ 224 libOMXVideoDecoderWMV \ 225 libOMXVideoDecoderVP8 \ 226 libOMXVideoDecoderMPEG2 \ 227 libOMXVideoDecoderVP9HWR \ 228 libOMXVideoDecoderVP9Hybrid \ 229 libOMXVideoEncoderAVC \ 230 libOMXVideoEncoderH263 \ 231 libOMXVideoEncoderMPEG4 \ 232 libOMXVideoEncoderVP8 233 234 #libISV 235 PRODUCT_PACKAGES += libisv_omx_core 236 237 # pvr 238 PRODUCT_PACKAGES += \ 239 libpvr2d 240 241 # libdrm 242 PRODUCT_PACKAGES += \ 243 libdrm \ 244 dristat \ 245 drmstat 246 247 # libion 248 PRODUCT_PACKAGES += \ 249 libion 250 251 # Wifi 252 PRODUCT_PACKAGES += \ 253 libwpa_client \ 254 lib_driver_cmd_bcmdhd \ 255 hostapd \ 256 wificond \ 257 wifilogd \ 258 wpa_supplicant \ 259 bcmdhd.cal \ 260 bcmdhd_sr2.cal 261 262 PRODUCT_COPY_FILES += \ 263 device/asus/fugu/wpa_supplicant.conf:/system/etc/wifi/wpa_supplicant.conf 264 265 PRODUCT_COPY_FILES += \ 266 frameworks/native/data/etc/android.hardware.wifi.xml:system/etc/permissions/android.hardware.wifi.xml \ 267 frameworks/native/data/etc/android.hardware.wifi.direct.xml:system/etc/permissions/android.hardware.wifi.direct.xml \ 268 frameworks/native/data/etc/android.hardware.bluetooth_le.xml:system/etc/permissions/android.hardware.bluetooth_le.xml \ 269 frameworks/native/data/etc/android.hardware.bluetooth.xml:system/etc/permissions/android.hardware.bluetooth.xml \ 270 frameworks/native/data/etc/android.hardware.usb.host.xml:system/etc/permissions/android.hardware.usb.host.xml \ 271 frameworks/native/data/etc/android.hardware.hdmi.cec.xml:system/etc/permissions/android.hardware.hdmi.cec.xml \ 272 frameworks/native/data/etc/android.software.midi.xml:system/etc/permissions/android.software.midi.xml 273 274 # Key layout files 275 PRODUCT_COPY_FILES += \ 276 device/asus/fugu/Nexus_Remote.idc:system/usr/idc/Nexus_Remote.idc \ 277 device/asus/fugu/gpio-keys.idc:system/usr/idc/gpio-keys.idc \ 278 device/asus/fugu/gpio-keys.kl:system/usr/keylayout/gpio-keys.kl \ 279 device/asus/fugu/gpio-keys.kcm:system/usr/keychars/gpio-keys.kcm \ 280 device/asus/fugu/Spike.kl:system/usr/keylayout/Spike.kl \ 281 device/asus/fugu/Nexus_Remote.kl:system/usr/keylayout/Nexus_Remote.kl 282 283 #GFX Config 284 PRODUCT_COPY_FILES += \ 285 device/asus/fugu/powervr.ini:system/etc/powervr.ini \ 286 frameworks/native/data/etc/android.hardware.vulkan.level-0.xml:system/etc/permissions/android.hardware.vulkan.level-0.xml \ 287 frameworks/native/data/etc/android.hardware.vulkan.version-1_0_3.xml:system/etc/permissions/android.hardware.vulkan.version-1_0_3.xml 288 289 # Thermal itux 290 ENABLE_ITUXD := true 291 PRODUCT_PACKAGES += \ 292 ituxd 293 294 # Memtrack HAL 295 PRODUCT_PACKAGES += \ 296 android.hardware.memtrack@1.0-impl 297 298 # Power HAL 299 PRODUCT_PACKAGES += \ 300 power.fugu \ 301 android.hardware.power@1.0-impl \ 302 303 # TV Input HAL 304 PRODUCT_PACKAGES += \ 305 android.hardware.tv.input@1.0-impl 306 307 # HDMI CEC HAL 308 PRODUCT_PACKAGES += \ 309 android.hardware.tv.cec@1.0-impl 310 311 PRODUCT_PACKAGES += \ 312 android.hardware.drm@1.0-impl \ 313 314 # Debug rc files 315 ifneq (,$(filter userdebug eng, $(TARGET_BUILD_VARIANT))) 316 PRODUCT_COPY_FILES += \ 317 device/asus/fugu/init.fugu.diag.rc.userdebug:root/init.fugu.diag.rc 318 endif 319 320 # In userdebug, add minidebug info the the boot image and the system server to support 321 # diagnosing native crashes. 322 ifneq (,$(filter userdebug, $(TARGET_BUILD_VARIANT))) 323 # Boot image. 324 PRODUCT_DEX_PREOPT_BOOT_FLAGS += --generate-mini-debug-info 325 # System server and some of its services. This is just here for completeness and consistency, 326 # as we currently only compile the boot image. 327 # Note: we cannot use PRODUCT_SYSTEM_SERVER_JARS, as it has not been expanded at this point. 328 $(call add-product-dex-preopt-module-config,services,--generate-mini-debug-info) 329 $(call add-product-dex-preopt-module-config,wifi-service,--generate-mini-debug-info) 330 endif 331 332 $(call inherit-product-if-exists, vendor/asus/fugu/device-vendor.mk) 333 $(call inherit-product-if-exists, vendor/intel/PRIVATE/fugu/device-vendor.mk) 334 $(call inherit-product-if-exists, vendor/intel/moorefield/prebuilts/houdini/houdini.mk) 335 336 # Add WiFi Firmware 337 $(call inherit-product-if-exists, hardware/broadcom/wlan/bcmdhd/firmware/bcm4354/device-bcm.mk) 338 339 # specific management of sep_policy.conf 340 PRODUCT_COPY_FILES += \ 341 device/asus/fugu/sep_policy.conf:system/etc/security/sep_policy.conf 342 343 #PRODUCT_CHARACTERISTICS := tablet 344 345 # Wifi country code 346 PRODUCT_COPY_FILES += \ 347 device/asus/fugu/init.fugu.countrycode.sh:system/bin/init.fugu.countrycode.sh 348 349 # Vendor Interface Manifest 350 PRODUCT_COPY_FILES += \ 351 $(LOCAL_PATH)/manifest.xml:system/vendor/manifest.xml 352 353 # Some CTS tests will be skipped based on what the initial API level that 354 # shipped on device was. 355 PRODUCT_PROPERTY_OVERRIDES += \ 356 ro.product.first_api_level=21 357 358 PRODUCT_DEFAULT_PROPERTY_OVERRIDES += \ 359 ro.opengles.version=196609 \ 360 ro.hwui.drop_shadow_cache_size=4.0 \ 361 ro.hwui.gradient_cache_size=0.8 \ 362 ro.hwui.layer_cache_size=32.0 \ 363 ro.hwui.path_cache_size=24.0 \ 364 ro.hwui.text_large_cache_width=2048 \ 365 ro.hwui.text_large_cache_height=1024 \ 366 ro.hwui.text_small_cache_width=1024 \ 367 ro.hwui.text_small_cache_height=512 \ 368 ro.hwui.texture_cache_flushrate=0.4 \ 369 ro.hwui.texture_cache_size=48.0 \ 370 371 PRODUCT_DEFAULT_PROPERTY_OVERRIDES += \ 372 persist.intel.isv.vpp=1 \ 373 persist.intel.isv.frc=1 374