blob: 9c278bc81d150e31dbe76eae8867d256654b02fb [file] [log] [blame]
# Copyright 2020 The Chromium OS Authors. All rights reserved.
# Use of this source code is governed by a BSD-style license that can be
# found in the LICENSE file.
EAPI=7
CROS_WORKON_COMMIT="c8222960422eb2bc872a727b170a6a9941a01354"
CROS_WORKON_TREE=("a01b9c0b9a6d0a8fa284370087f1ceae19b93260" "dd4323fe3640909500f29f7acde8c0868024c48a" "8bfca2f1ed038e0e416fc64153834ad974b30e7b" "b4c91bd8531e62cea50ef9ca4369fffaed3239fe" "e7dba8c91c1f3257c34d4a7ffff0ea2537aeb6bb")
CROS_WORKON_INCREMENTAL_BUILD=1
CROS_WORKON_LOCALNAME="platform2"
CROS_WORKON_PROJECT="chromiumos/platform2"
CROS_WORKON_OUTOFTREE_BUILD=1
CROS_WORKON_SUBTREE="attestation common-mk hwsec-test-utils trunks .gn"
PLATFORM_SUBDIR="hwsec-test-utils"
inherit cros-workon platform
DESCRIPTION="Hwsec-related test-only features. This package resides in test images only."
HOMEPAGE="https://chromium.googlesource.com/chromiumos/platform2/+/master/hwsec-test-utils/"
LICENSE="BSD-Google"
KEYWORDS="*"
IUSE="test tpm tpm2"
REQUIRED_USE="tpm2? ( !tpm )"
RDEPEND="
tpm2? (
chromeos-base/trunks:=
)
!tpm2? (
app-crypt/trousers:=
)
"
DEPEND="${RDEPEND}
tpm2? (
chromeos-base/trunks:=[test?]
)
chromeos-base/attestation:=
chromeos-base/system_api:=
dev-libs/openssl:=
dev-libs/protobuf:=
"
src_install() {
# Installs attestation-injected-keys
dobin "${OUT}/attestation-injected-keys"
# Installs hwsec-test-va
dobin "${OUT}/hwsec-test-va"
# Install fake pca agent
insinto /etc/init
doins fake_pca_agent/fake_pca_agentd.conf
dobin "${OUT}"/fake_pca_agentd
}
platform_pkg_test() {
platform_test "run" "${OUT}/hwsec-test-utils_testrunner"
}