mirror of
https://github.com/gentoo-mirror/gentoo.git
synced 2026-09-24 04:59:14 -07:00
dev-ml/llvm-ocaml: Stop enforcing external lit for tests
Modify the ebuild to no longer enforce externally installed dev-python/lit for tests, effectively causing the build system to use the bundled copy of lit (along with llvm-lit). While using the external package is more canonical, its disadvantages outweight the gain. Most notably, lit is not slotted in Gentoo and the behavior of lit frequently changes subtly which caused us to require a major version match between LLVM and lit. As a result, attempting to build multiple slots of LLVM with tests enabled cause package collisions. Building both LLVM and lit simultaneously causes a circular dependency. Since lit comes from the same package as LLVM itself and LLVM requires explicit python-any-r1 use anyway, using the bundled copy has no added cost. Furthermore, in the current git version the additional (fine-grained) test rules do not work correctly without llvm-lit, making it impossible to run LLVM binding tests separately.
This commit is contained in:
@@ -35,8 +35,7 @@ RDEPEND="
|
||||
DEPEND="${RDEPEND}
|
||||
dev-lang/perl
|
||||
dev-ml/findlib
|
||||
test? ( dev-ml/ounit
|
||||
$(python_gen_any_dep "~dev-python/lit-${PV}[\${PYTHON_USEDEP}]") )
|
||||
test? ( dev-ml/ounit )
|
||||
!!<dev-python/configparser-3.3.0.2
|
||||
${PYTHON_DEPS}"
|
||||
|
||||
@@ -48,11 +47,6 @@ S=${WORKDIR}/${MY_P/_/}.src
|
||||
# least intrusive of all
|
||||
CMAKE_BUILD_TYPE=RelWithDebInfo
|
||||
|
||||
python_check_deps() {
|
||||
! use test \
|
||||
|| has_version "dev-python/lit[${PYTHON_USEDEP}]"
|
||||
}
|
||||
|
||||
pkg_setup() {
|
||||
LLVM_MAX_SLOT=${PV%%.*} llvm_pkg_setup
|
||||
python-any-r1_pkg_setup
|
||||
@@ -92,10 +86,6 @@ src_configure() {
|
||||
# TODO: ocamldoc
|
||||
)
|
||||
|
||||
use test && mycmakeargs+=(
|
||||
-DLIT_COMMAND="${EPREFIX}/usr/bin/lit"
|
||||
)
|
||||
|
||||
cmake-utils_src_configure
|
||||
|
||||
local llvm_libdir=$(llvm-config --libdir)
|
||||
|
||||
@@ -37,8 +37,7 @@ RDEPEND="
|
||||
DEPEND="${RDEPEND}
|
||||
dev-lang/perl
|
||||
dev-ml/findlib
|
||||
test? ( dev-ml/ounit
|
||||
$(python_gen_any_dep "~dev-python/lit-${PV}[\${PYTHON_USEDEP}]") )
|
||||
test? ( dev-ml/ounit )
|
||||
!!<dev-python/configparser-3.3.0.2
|
||||
${PYTHON_DEPS}"
|
||||
|
||||
@@ -48,11 +47,6 @@ REQUIRED_USE="${PYTHON_REQUIRED_USE}
|
||||
# least intrusive of all
|
||||
CMAKE_BUILD_TYPE=RelWithDebInfo
|
||||
|
||||
python_check_deps() {
|
||||
! use test \
|
||||
|| has_version "dev-python/lit[${PYTHON_USEDEP}]"
|
||||
}
|
||||
|
||||
pkg_setup() {
|
||||
LLVM_MAX_SLOT=${PV%%.*} llvm_pkg_setup
|
||||
python-any-r1_pkg_setup
|
||||
@@ -92,10 +86,6 @@ src_configure() {
|
||||
# TODO: ocamldoc
|
||||
)
|
||||
|
||||
use test && mycmakeargs+=(
|
||||
-DLIT_COMMAND="${EPREFIX}/usr/bin/lit"
|
||||
)
|
||||
|
||||
# LLVM_ENABLE_ASSERTIONS=NO does not guarantee this for us, #614844
|
||||
# also: custom rules for OCaml do not work for CPPFLAGS
|
||||
use debug || local -x CFLAGS="${CFLAGS} -DNDEBUG"
|
||||
|
||||
@@ -38,8 +38,7 @@ RDEPEND="
|
||||
DEPEND="${RDEPEND}
|
||||
dev-lang/perl
|
||||
dev-ml/findlib
|
||||
test? ( dev-ml/ounit
|
||||
$(python_gen_any_dep "~dev-python/lit-${PV}[\${PYTHON_USEDEP}]") )
|
||||
test? ( dev-ml/ounit )
|
||||
!!<dev-python/configparser-3.3.0.2
|
||||
${PYTHON_DEPS}"
|
||||
|
||||
@@ -49,11 +48,6 @@ REQUIRED_USE="${PYTHON_REQUIRED_USE}
|
||||
# least intrusive of all
|
||||
CMAKE_BUILD_TYPE=RelWithDebInfo
|
||||
|
||||
python_check_deps() {
|
||||
! use test \
|
||||
|| has_version "dev-python/lit[${PYTHON_USEDEP}]"
|
||||
}
|
||||
|
||||
pkg_setup() {
|
||||
llvm_pkg_setup
|
||||
python-any-r1_pkg_setup
|
||||
@@ -97,7 +91,6 @@ src_configure() {
|
||||
)
|
||||
|
||||
use test && mycmakeargs+=(
|
||||
-DLLVM_EXTERNAL_LIT="${EPREFIX}/usr/bin/lit"
|
||||
-DLLVM_LIT_ARGS="-vv"
|
||||
)
|
||||
|
||||
|
||||
Reference in New Issue
Block a user