| Version | EAPI | Keywords | Slot |
|---|---|---|---|
| 9999 | 8 | 0 |
# Copyright 1999-2025 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=8
inherit cmake git-r3
DESCRIPTION="Utilities library used by Belledonne Communications softwares"
HOMEPAGE="https://gitlab.linphone.org/BC/public/bctoolbox"
EGIT_REPO_URI="https://gitlab.linphone.org/BC/public/${PN}.git"
LICENSE="GPL-3"
SLOT="0"
IUSE="debug mbedtls +openssl test"
PROPERTIES="test_network"
# test doesn't build with mbedtls
REQUIRED_USE="^^ ( mbedtls openssl ) test? ( openssl )"
RESTRICT="!test? ( test )"
RDEPEND="mbedtls? ( net-libs/mbedtls:3= )
openssl? ( dev-libs/openssl:= )"
DEPEND="${RDEPEND}"
BDEPEND="virtual/pkgconfig
test? ( dev-util/bcunit )"
src_configure() {
local mycmakeargs=(
-DENABLE_DEBUG_LOGS="$(usex debug)"
-DENABLE_MBEDTLS="$(usex mbedtls)"
-DENABLE_OPENSSL="$(usex openssl)"
-DENABLE_STRICT=NO
-DENABLE_TESTS_COMPONENT="$(usex test)"
-DENABLE_UNIT_TESTS="$(usex test)"
)
cmake_src_configure
}
src_test() {
"${S}"_build/tester/bctoolbox-tester || die "tests failed"
cmake_src_test
}
mbedtls? ( net-libs/mbedtls:3= ) openssl? ( dev-libs/openssl:= )
mbedtls? ( net-libs/mbedtls:3= ) openssl? ( dev-libs/openssl:= )
virtual/pkgconfig test? ( dev-util/bcunit )