blob: f542264169643099e7d36a7b1520fedef43bb5b4 [file] [log] [blame]
# Copyright 2022 The Chromium OS Authors. All rights reserved.
# Distributed under the terms of the GNU General Public License v2
EAPI="7"
CROS_WORKON_COMMIT=("52616c3ec16e7dd73a782baaf3d3c491ad10fa8f" "19ddacfca78cbce374e74fa06db41100af9e9850" "2292d9d2570b742a4aaaaf77293c7b1423e82c39" "68b356f2e7a8c6103eff9662d1d37d52a0f49305")
CROS_WORKON_TREE=("81608e81e7a1a6aacd7096a66fd44588c1d5ece9" "e7dba8c91c1f3257c34d4a7ffff0ea2537aeb6bb" "ebc94095def7b9d97104e9574b06f31139765b85" "537ecd16c7699aa18aeed7375cc0ed5ec4ca9361" "c3473ab29243f136628d4c8708ab647c15f6a411")
CROS_WORKON_PROJECT=(
"chromiumos/platform2"
"aosp/platform/packages/modules/Bluetooth"
"aosp/platform/packages/modules/Bluetooth"
"aosp/platform/frameworks/proto_logging"
)
CROS_WORKON_LOCALNAME=(
"../platform2"
"../aosp/packages/modules/Bluetooth/local"
"../aosp/packages/modules/Bluetooth/upstream"
"../aosp/frameworks/proto_logging"
)
CROS_WORKON_DESTDIR=(
"${S}/platform2"
"${S}/platform2/bt"
"${S}/platform2/bt"
"${S}/platform2/external/proto_logging"
)
CROS_WORKON_SUBTREE=("common-mk .gn" "" "" "")
CROS_WORKON_EGIT_BRANCH=("main" "main" "upstream/master" "master")
CROS_WORKON_OPTIONAL_CHECKOUT=(
""
"use !floss_upstream"
"use floss_upstream"
""
)
PLATFORM_SUBDIR="bt"
IUSE="floss_upstream"
WANT_LIBCHROME="no"
WANT_LIBBRILLO="no"
inherit cros-workon toolchain-funcs platform
DESCRIPTION="Bluetooth Build Tools"
HOMEPAGE="https://android.googlesource.com/platform/packages/modules/Bluetooth"
# Apache-2.0 for system/bt
# All others from rust crates
LICENSE="
Apache-2.0
MIT BSD ISC
"
KEYWORDS="*"
DEPEND=""
BDEPEND="
dev-libs/tinyxml2
"
RDEPEND="${DEPEND}"
src_configure() {
ARCH="$(tc-arch "${CBUILD}")" tc-env_build platform "configure" "--host"
}
src_compile() {
ARCH="$(tc-arch "${CBUILD}")" tc-env_build platform "compile" "tools" "--host"
}
src_install() {
local bin_dir="$(cros-workon_get_build_dir)/out/Default/"
dobin "${bin_dir}/bluetooth_packetgen"
dobin "${bin_dir}/bluetooth_flatbuffer_bundler"
}