Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
13 changes: 8 additions & 5 deletions configure
Original file line number Diff line number Diff line change
Expand Up @@ -885,16 +885,19 @@ if($gopt_enable_geant4_interface eq "YES") {
# if it still not set, try autodetecting it
if(! -d $gopt_with_geant4_lib && $auto_detect) {
print "Auto-detecting GEANT4 library path...\n";
$matched = auto_detect("libG4processes.so");
if( $matched=~m/(\S*)\/libG4processes.so/i ) {
# v10 has libG4processes.so, but v11 has libG4processes_core.so
$matched = auto_detect("libG4processes.so","libG4processes_core.so");
if( $matched=~m/(\S*)\/(?:libG4processes|libG4processes_core)\.so/i ) {
$gopt_with_geant4_lib = $1;
}
print "Setting --with-geant4-lib=$gopt_with_geant4_lib\n";
}
# check
my $fileso = "$gopt_with_geant4_lib/libG4processes.so";
my $filedylib = "$gopt_with_geant4_lib/libG4processes.dylib";
if(! -e $fileso && ! -e $filedylib) {
my $file10so = "$gopt_with_geant4_lib/libG4processes.so";
my $file10dylib = "$gopt_with_geant4_lib/libG4processes.dylib";
my $file11so = "$gopt_with_geant4_lib/libG4processes_core.so";
my $file11dylib = "$gopt_with_geant4_lib/libG4processes_core.dylib";
if(! -e $file10so && ! -e $file10dylib && ! -e $file11so && ! -e $file11dylib) {
print "*** Error *** You need to specify the path to GEANT4 library using --with-geant4-lib=/some/path/\n";
print "*** Error *** Otherwise, you should --disable-geant4\n\n";
exit 1;
Expand Down