Skip to content

Commit c21bc3f

Browse files
committed
[roottest] Move from ROOT_xxx_FOUND to ROOT's native build options.
The build options called ROOT_xxx_FOUND originate from find_package(ROOT). Given that roottest is built as part of the ROOT build, one can now directly use the build option flags from ROOT's CMake. This will allow to remove the find_package(ROOT) step in the future. This change enabled the following test, which was disabled because ROOT_mathmore_FOUND wasn't set correctly: +gtest-roofit-roofit-vectorisedPDFs-testLegendre
1 parent 6c1424d commit c21bc3f

File tree

24 files changed

+29
-30
lines changed

24 files changed

+29
-30
lines changed

roofit/roofit/test/vectorisedPDFs/CMakeLists.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -48,7 +48,7 @@ ROOT_ADD_GTEST(testCBShape testCBShape.cxx
4848
LIBRARIES VectorisedPDFTests)
4949
ROOT_ADD_GTEST(testGamma testGamma.cxx
5050
LIBRARIES VectorisedPDFTests)
51-
if(ROOT_mathmore_FOUND)
51+
if(mathmore)
5252
ROOT_ADD_GTEST(testLegendre testLegendre.cxx
5353
LIBRARIES VectorisedPDFTests ROOT::RooFitMore)
5454
endif()

roottest/CMakeLists.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -119,7 +119,7 @@ set(CMAKE_ROOTTEST_DICT ON)
119119
set(CMAKE_MODULE_PATH "${CMAKE_MODULE_PATH};${ROOT_SOURCE_DIR}/roottest/cmake/modules")
120120

121121
#---Set flag for PyROOT tests that are expected to fail
122-
if(ROOT_pyroot_FOUND)
122+
if(pyroot)
123123
set(PYTESTS_WILLFAIL WILLFAIL)
124124
endif()
125125

roottest/cling/functionTemplate/CMakeLists.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ ROOTTEST_ADD_TEST(runreferenceuse
1010
DEPENDS MyClassReferenceUse.C
1111
LABELS roottest regression cling)
1212

13-
if(ROOT_pyroot_FOUND)
13+
if(pyroot)
1414
ROOTTEST_ADD_TEST(testcint
1515
MACRO testcint.py
1616
PRECMD ${ROOT_root_CMD} -b -q -l -e .L\ t.h+

roottest/cling/parsing/ALICE-18972/CMakeLists.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
if(ROOT_geom_FOUND)
1+
if(geom)
22
ROOTTEST_GENERATE_REFLEX_DICTIONARY(ALICE_18972 mylib.h SELECTION mylib_sel.xml)
33

44
ROOTTEST_ADD_TEST(ALICE_18972

roottest/cling/template/CMakeLists.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ ROOTTEST_ADD_TEST(templateSingleton
1616
FIXTURES_REQUIRED cling-template-Singleton-fixture
1717
LABELS roottest regression cling)
1818

19-
if(NOT ROOT_runtime_cxxmodules_FOUND)
19+
if(NOT runtime_cxxmodules)
2020
ROOTTEST_GENERATE_DICTIONARY(slaveDict slave.h LINKDEF slaveLinkDef.h)
2121
endif()
2222
ROOTTEST_GENERATE_DICTIONARY(masterDict master.h NO_CXXMODULE LINKDEF masterLinkDef.h)

roottest/cmake/modules/SearchInstalledSoftwareRoottest.cmake

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ if(NOT MSVC)
66
endif()
77

88
#---Check for MPI---------------------------------------------------------------
9-
if(ROOT_mpi_FOUND)
9+
if(mpi)
1010
message(STATUS "Looking for MPI")
1111
find_package(MPI)
1212
if(NOT MPI_FOUND)

roottest/python/CMakeLists.txt

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,10 @@
1-
if(ROOT_pyroot_FOUND)
1+
if(pyroot)
22

3-
if(ROOT_roofit_FOUND)
3+
if(roofit)
44
set(roofit True)
55
else()
66
set(roofit False)
7-
endif(ROOT_roofit_FOUND)
7+
endif(roofit)
88

99
find_python_module(pytest OPTIONAL)
1010

roottest/python/JsMVA/CMakeLists.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
#if (ROOT_pyroot_FOUND AND NOT ROOT_CLASSIC_BUILD) # Do not run with classic build
1+
#if (pyroot AND NOT ROOT_CLASSIC_BUILD) # Do not run with classic build
22

33
#set(NBDIFFUTIL ${CMAKE_CURRENT_SOURCE_DIR}/nbdiff.py )
44

roottest/python/JupyROOT/CMakeLists.txt

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
if(NOT MSVC OR win_broken_tests)
33

44
# Do not run with classic build or if tests are vetoed
5-
if (ROOT_pyroot_FOUND AND NOT ROOT_CLASSIC_BUILD)
5+
if (pyroot AND NOT ROOT_CLASSIC_BUILD)
66

77
set(MODULES_LOCATION ${ROOTSYS}/lib/JupyROOT/helpers)
88
set(NBDIFFUTIL ${CMAKE_CURRENT_SOURCE_DIR}/nbdiff.py )
@@ -38,7 +38,7 @@ foreach(NOTEBOOK ${NOTEBOOKS})
3838
PYTHON_DEPS jupyter)
3939
endforeach()
4040

41-
if(ROOT_imt_FOUND)
41+
if(imt)
4242
# No need to compare output here, just check it runs with no error
4343
set(IMT_NB Cpp_IMT_Canvas.ipynb)
4444
get_filename_component(NOTEBOOKBASE ${IMT_NB} NAME_WE)

roottest/python/basic/CMakeLists.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
if(ROOT_pyroot_FOUND)
1+
if(pyroot)
22
ROOTTEST_ADD_TEST(basic
33
MACRO PyROOT_basictests.py
44
COPY_TO_BUILDDIR ArgumentPassingCompiled.C ReturnValues.C SimpleClass.C ArgumentPassingInterpreted.C

0 commit comments

Comments
 (0)