Skip to content

Commit 29cc567

Browse files
committed
fix ROOT dependency, case sensitive on linux
1 parent 0f140ca commit 29cc567

3 files changed

Lines changed: 13 additions & 5 deletions

File tree

ci/build.sh

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,7 @@ meson_option=$(meson_setup_options $1)
1212

1313
echo " > Geant-config: $(which geant4-config) : $(geant4-config --version)" | tee $setup_log
1414
echo " > Root-config: $(which root-config) : $(root-config --version)" | tee -a $setup_log
15+
echo
1516
echo " > Meson Interactive Options: $test_interactive_option"
1617
echo " > Meson Setup Options: $meson_option"
1718
echo " > Using $jobs cores"

gdynamicDigitization/gDosimeterDigitization.cc

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -134,9 +134,10 @@ bool GDosimeterDigitization::loadConstantsImpl([[maybe_unused]] int
134134
// if that's the case, the data is inside gdynamicDigitization
135135
dataFileWithPath = gemcRoot.string() + "/gdynamicDigitization/dosimeterData" + "/Niel/" + filename;
136136
inputfile.open(dataFileWithPath);
137-
if (!inputfile)
138-
log->error(EC__FILENOTFOUND, "Error loading dosimeter data for pid <", pid, "> from file ",
139-
dataFileWithPath);
137+
if (!inputfile) {
138+
log->error(EC__FILENOTFOUND, "Error loading dosimeter data for pid <", pid, "> from file ",
139+
dataFileWithPath);
140+
}
140141
}
141142

142143
log->info(0, " Loading dosimeter data for pid <", pid, "> from file ", dataFileWithPath);

meson/meson.build

Lines changed: 8 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -41,15 +41,21 @@ if (not root_dep.found()) and (not root_opt.disabled())
4141
# Probe root-config once
4242
rootcfg = find_program('root-config', required : false)
4343
if rootcfg.found()
44+
root_prefix = run_command(rootcfg, '--prefix', check : true).stdout().strip()
45+
4446
root_mods = []
45-
root_dep = dependency('root',
47+
root_dep = dependency('ROOT',
4648
version : '>=6.32.16',
4749
method : 'cmake',
4850
modules : ['ROOT::Core', 'ROOT::RIO', 'ROOT::Tree', 'ROOT::Hist'],
4951
required : false,
5052
include_type : 'system') # treat as system include paths - no warnings
5153

52-
message('root-config found. root_dep dependency added')
54+
if root_dep.found()
55+
message('root-config found; ROOT dependency resolved: ' + root_dep.version())
56+
else
57+
message('root-config found, but ROOT CMake dependency NOT resolved; ROOT features will be disabled')
58+
endif
5359
else
5460
if root_opt.enabled()
5561
warning('ROOT was explicitly enabled (-Droot=enabled) but root-config was not found.')

0 commit comments

Comments
 (0)