| # Copyright 2018 The ChromiumOS Authors |
| # Distributed under the terms of the GNU General Public License v2 |
| |
| EAPI="7" |
| |
| CROS_WORKON_COMMIT="10b13f4ee9f713f646450da83ba6ccb261873349" |
| CROS_WORKON_TREE=("a2cce5470dac5262b88bb59c5132c911a2aa4bd2" "5dc1d92f47d4349d65be5d202d93d68b50dbb662" "f91b6afd5f2ae04ee9a2c19109a3a4a36f7659e6") |
| CROS_WORKON_PROJECT="chromiumos/platform2" |
| CROS_WORKON_LOCALNAME="platform2" |
| CROS_WORKON_OUTOFTREE_BUILD=1 |
| CROS_WORKON_SUBTREE="common-mk chromeos-common-script .gn" |
| |
| PLATFORM_SUBDIR="chromeos-common-script" |
| WANT_LIBCHROME="no" |
| WANT_LIBBRILLO="no" |
| |
| inherit cros-workon platform |
| |
| DESCRIPTION="Chrome OS storage info tools" |
| HOMEPAGE="https://chromium.googlesource.com/chromiumos/platform2/+/HEAD/chromeos-common-script/" |
| SRC_URI="" |
| |
| LICENSE="BSD-Google" |
| SLOT="0" |
| KEYWORDS="*" |
| IUSE="direncryption fsverity prjquota" |
| # This package has no unittests. |
| RESTRICT="test" |
| |
| src_install() { |
| platform_src_install |
| |
| insinto /usr/share/misc |
| doins share/chromeos-common.sh |
| doins share/lvm-utils.sh |
| if use direncryption; then |
| sed -i '/local direncryption_enabled=/s/false/true/' \ |
| "${D}/usr/share/misc/chromeos-common.sh" || |
| die "Can not set directory encryption in common library" |
| fi |
| if use fsverity; then |
| sed -i '/local fsverity_enabled=/s/false/true/' \ |
| "${D}/usr/share/misc/chromeos-common.sh" || |
| die "Can not set fs-verity in common library" |
| fi |
| if use prjquota; then |
| sed -i '/local prjquota_enabled=/s/false/true/' \ |
| "${D}/usr/share/misc/chromeos-common.sh" || |
| die "Can not set project quota in common library" |
| fi |
| } |