blob: 4381c1a4935f0c667bfaa26e86068a8ed791bc9d [file] [log] [blame]
# Copyright 2016 The Chromium OS Authors. All rights reserved.
# Distributed under the terms of the GNU General Public License v2
EAPI=7
inherit appid cros-audio-configs udev
DESCRIPTION="Ebuild which pulls in any necessary ebuilds as dependencies
or portage actions."
LICENSE="BSD-Google"
SLOT="0" # TODO(b/144948221): convert this to cros-workon
KEYWORDS="-* arm64 arm"
IUSE="hana-kernelnext"
S="${WORKDIR}"
# Add dependencies on other ebuilds from within this board overlay
DEPEND=""
RDEPEND="${DEPEND}
chromeos-base/chromeos-accelerometer-init
chromeos-base/chromeos-bsp-baseboard-oak
sys-apps/ethtool
"
src_install() {
if use hana-kernelnext; then
doappid "{3C72E98C-09C7-11EA-801F-3B16A88ADBE8}" "CHROMEBOOK"
else
doappid "{AAE972E1-A913-C860-B7AB-BF7F267F199B}" "CHROMEBOOK"
fi
# Install audio config files.
local audio_config_dir="${FILESDIR}/audio-config"
install_audio_configs hana "${audio_config_dir}"
# Install platform specific config files for power_manager.
insinto "/usr/share/power_manager/board_specific"
doins "${FILESDIR}"/powerd_prefs/*
# The 4.19 kernel uses a new non linear backlight scale.
# To match the battery default backlight level we change the
# target % using file internal_backlight_no_als_battery_brightness.
# Note the intention is to have the same resulting real world brightness.
# b/149870759
# This should be moved to the main value after kernelnext is merged back.
if use hana-kernelnext; then
doins "${FILESDIR}"/powerd_prefs_kernelnext/*
fi
# Install rules to enable WoWLAN on startup.
udev_dorules "${FILESDIR}/99-mwifiex-wowlan.rules"
# Install rules to detect when DRM HDMI driver is loaded
udev_dorules "${FILESDIR}/99-mtk_drm_hdmi_load.rules"
# Install script called by 99-mtk_drm_hdmi_load.rules
dosbin "${FILESDIR}"/hdcp_pass_key.sh
}