| # Copyright 2019 The Chromium OS Authors. All rights reserved. |
| # Distributed under the terms of the GNU General Public License v2 |
| |
| EAPI=7 |
| |
| CROS_WORKON_INCREMENTAL_BUILD=1 |
| CROS_WORKON_LOCALNAME="platform2" |
| CROS_WORKON_PROJECT="chromiumos/platform2" |
| CROS_WORKON_OUTOFTREE_BUILD=1 |
| CROS_WORKON_SUBTREE="common-mk chromeos-config hardware_verifier metrics .gn" |
| |
| PLATFORM_SUBDIR="hardware_verifier" |
| |
| inherit cros-workon platform user |
| |
| DESCRIPTION="Hardware Verifier Tool/Lib for Chrome OS" |
| HOMEPAGE="https://chromium.googlesource.com/chromiumos/platform2/+/master/hardware_verifier/" |
| |
| LICENSE="BSD-Google" |
| KEYWORDS="~*" |
| IUSE="generated_cros_config unibuild" |
| |
| DEPEND=" |
| unibuild? ( |
| !generated_cros_config? ( chromeos-base/chromeos-config:= ) |
| generated_cros_config? ( chromeos-base/chromeos-config-bsp:= ) |
| ) |
| chromeos-base/chromeos-config-tools:= |
| >=chromeos-base/metrics-0.0.1-r3152:= |
| chromeos-base/system_api:= |
| chromeos-base/vboot_reference:= |
| " |
| |
| pkg_preinst() { |
| # Create user and group for hardware_verifier |
| enewuser "hardware_verifier" |
| enewgroup "hardware_verifier" |
| } |
| |
| src_install() { |
| dobin "${OUT}/hardware_verifier" |
| |
| insinto /etc/init |
| doins init/hardware-verifier.conf |
| } |
| |
| platform_pkg_test() { |
| platform_test "run" "${OUT}/unittest_runner" |
| } |