blob: d5ff06b626886032a18433da1c71c56e43418413 [file] [log] [blame]
# Copyright 2015 The ChromiumOS Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=7
CROS_WORKON_COMMIT="c3bbb3d8b7e4e1d43402020ccbbb51cd7a43be59"
CROS_WORKON_TREE="36cda69e16d13862bdb2a8eff49eb2f37b86de8c"
CROS_WORKON_PROJECT="chromiumos/platform2"
CROS_WORKON_LOCALNAME="platform2"
CROS_WORKON_DESTDIR="${S}"
CROS_WORKON_OUTOFTREE_BUILD=1
CROS_WORKON_SUBTREE="regions"
PLATFORM_SUBDIR="regions"
inherit cros-workon
DESCRIPTION="Chromium OS Region Data"
HOMEPAGE="https://chromium.googlesource.com/chromiumos/platform2/+/HEAD/regions/"
LICENSE="BSD-Google"
KEYWORDS="*"
IUSE="cros-debug"
# 'jq' allows command line tools to access the JSON database.
RDEPEND="app-misc/jq"
DEPEND=""
src_unpack() {
cros-workon_src_unpack
S+="/regions"
}
src_compile() {
./regions.py --format=json --output "${WORKDIR}/cros-regions.json" $(usex cros-debug "--include_pseudolocales" "")
}
src_test() {
./regions_unittest.py
}
src_install() {
dobin cros_region_data
insinto /usr/share/misc
doins "${WORKDIR}/cros-regions.json"
}