From f9ee66654cca2089996cf184dbb5f90de7e121ef Mon Sep 17 00:00:00 2001 From: Tim Kok Date: Tue, 31 Oct 2023 11:31:27 +0100 Subject: [PATCH 1/2] Ensure right Python version is used in DP3, WSClean and dependencies --- .../easyconfigs/a/AOFlagger/AOFlagger-3.4.0-foss-2022a.eb | 3 +++ easybuild/easyconfigs/c/casacore/casacore-3.5.0-foss-2022a.eb | 4 +++- easybuild/easyconfigs/d/DP3/DP3-6.0-foss-2022a.eb | 3 +++ .../easyconfigs/e/EveryBeam/EveryBeam-0.5.2-foss-2022a.eb | 3 +++ easybuild/easyconfigs/w/WSClean/WSClean-3.4-foss-2022a.eb | 3 +++ 5 files changed, 15 insertions(+), 1 deletion(-) diff --git a/easybuild/easyconfigs/a/AOFlagger/AOFlagger-3.4.0-foss-2022a.eb b/easybuild/easyconfigs/a/AOFlagger/AOFlagger-3.4.0-foss-2022a.eb index eeb528a357b..fc5d1d7e3bd 100644 --- a/easybuild/easyconfigs/a/AOFlagger/AOFlagger-3.4.0-foss-2022a.eb +++ b/easybuild/easyconfigs/a/AOFlagger/AOFlagger-3.4.0-foss-2022a.eb @@ -32,6 +32,9 @@ dependencies = [ ('libxml2', '2.9.13'), ] +# make sure the right Python is used +configopts = '-DPython3_EXECUTABLE=$EBROOTPYTHON/bin/python ' + sanity_check_paths = { 'files': ['include/aoflagger.h', 'bin/aoflagger'], 'dirs': ['bin'], diff --git a/easybuild/easyconfigs/c/casacore/casacore-3.5.0-foss-2022a.eb b/easybuild/easyconfigs/c/casacore/casacore-3.5.0-foss-2022a.eb index 9c359a65e60..7209a109104 100644 --- a/easybuild/easyconfigs/c/casacore/casacore-3.5.0-foss-2022a.eb +++ b/easybuild/easyconfigs/c/casacore/casacore-3.5.0-foss-2022a.eb @@ -42,7 +42,9 @@ dependencies = [ ] configopts = '-DBUILD_PYTHON=NO -DBUILD_PYTHON3=YES -Wno-dev -DCXX11="ON" -DDATA_DIR=%(installdir)s/data ' -configopts += '-DUSE_OPENMP=ON -DUSE_HDF5=ON -DUSE_MPI=ON' +configopts += '-DUSE_OPENMP=ON -DUSE_HDF5=ON -DUSE_MPI=ON ' +# make sure the right Python is used +configopts += '-DPython3_EXECUTABLE=$EBROOTPYTHON/bin/python ' sanity_check_paths = { 'files': ['lib/libcasa_casa.%s' % SHLIB_EXT, 'lib/libcasa_mirlib.%s' % SHLIB_EXT, diff --git a/easybuild/easyconfigs/d/DP3/DP3-6.0-foss-2022a.eb b/easybuild/easyconfigs/d/DP3/DP3-6.0-foss-2022a.eb index 41dbbeb6af1..6ee878c3713 100644 --- a/easybuild/easyconfigs/d/DP3/DP3-6.0-foss-2022a.eb +++ b/easybuild/easyconfigs/d/DP3/DP3-6.0-foss-2022a.eb @@ -36,6 +36,9 @@ dependencies = [ ('AOFlagger', '3.4.0') ] +# make sure the right Python is used +configopts = '-DPython3_EXECUTABLE=$EBROOTPYTHON/bin/python ' + sanity_check_paths = { 'files': ['include/include/dp3/base/DP3.h', 'bin/DP3'], 'dirs': ['bin'], diff --git a/easybuild/easyconfigs/e/EveryBeam/EveryBeam-0.5.2-foss-2022a.eb b/easybuild/easyconfigs/e/EveryBeam/EveryBeam-0.5.2-foss-2022a.eb index 43f393b0dc7..48e5bd469f0 100644 --- a/easybuild/easyconfigs/e/EveryBeam/EveryBeam-0.5.2-foss-2022a.eb +++ b/easybuild/easyconfigs/e/EveryBeam/EveryBeam-0.5.2-foss-2022a.eb @@ -36,6 +36,9 @@ dependencies = [ ('libxml2', '2.9.13'), ] +# make sure the right Python is used +configopts = '-DPython3_EXECUTABLE=$EBROOTPYTHON/bin/python ' + sanity_check_paths = { 'files': ['include/EveryBeam/beamformer.h', 'lib/libeverybeam.so'], 'dirs': [], diff --git a/easybuild/easyconfigs/w/WSClean/WSClean-3.4-foss-2022a.eb b/easybuild/easyconfigs/w/WSClean/WSClean-3.4-foss-2022a.eb index de04e74ec1c..7822414a2b9 100644 --- a/easybuild/easyconfigs/w/WSClean/WSClean-3.4-foss-2022a.eb +++ b/easybuild/easyconfigs/w/WSClean/WSClean-3.4-foss-2022a.eb @@ -31,6 +31,9 @@ dependencies = [ ('Python', '3.10.4'), ] +# make sure the right Python is used +configopts = '-DPython3_EXECUTABLE=$EBROOTPYTHON/bin/python ' + sanity_check_paths = { 'files': ['include/wscleaninterface.h', 'bin/wsclean'], 'dirs': ['bin'], From d7da9537361056ca65857887dd91ab6446c0875d Mon Sep 17 00:00:00 2001 From: Tim Kok Date: Tue, 31 Oct 2023 16:32:48 +0100 Subject: [PATCH 2/2] Improve comment by being more explicit --- .../easyconfigs/a/AOFlagger/AOFlagger-3.4.0-foss-2022a.eb | 4 +++- easybuild/easyconfigs/c/casacore/casacore-3.5.0-foss-2022a.eb | 4 +++- easybuild/easyconfigs/d/DP3/DP3-6.0-foss-2022a.eb | 4 +++- .../easyconfigs/e/EveryBeam/EveryBeam-0.5.2-foss-2022a.eb | 4 +++- easybuild/easyconfigs/w/WSClean/WSClean-3.4-foss-2022a.eb | 4 +++- 5 files changed, 15 insertions(+), 5 deletions(-) diff --git a/easybuild/easyconfigs/a/AOFlagger/AOFlagger-3.4.0-foss-2022a.eb b/easybuild/easyconfigs/a/AOFlagger/AOFlagger-3.4.0-foss-2022a.eb index fc5d1d7e3bd..ada37c804a9 100644 --- a/easybuild/easyconfigs/a/AOFlagger/AOFlagger-3.4.0-foss-2022a.eb +++ b/easybuild/easyconfigs/a/AOFlagger/AOFlagger-3.4.0-foss-2022a.eb @@ -32,7 +32,9 @@ dependencies = [ ('libxml2', '2.9.13'), ] -# make sure the right Python is used +# Without this, the wrong (system) python is picked up by cmake +# in cases where the system python is newer than the one used in these EasyConfigs +# See PR # 19119 configopts = '-DPython3_EXECUTABLE=$EBROOTPYTHON/bin/python ' sanity_check_paths = { diff --git a/easybuild/easyconfigs/c/casacore/casacore-3.5.0-foss-2022a.eb b/easybuild/easyconfigs/c/casacore/casacore-3.5.0-foss-2022a.eb index 7209a109104..d98f5af249e 100644 --- a/easybuild/easyconfigs/c/casacore/casacore-3.5.0-foss-2022a.eb +++ b/easybuild/easyconfigs/c/casacore/casacore-3.5.0-foss-2022a.eb @@ -43,7 +43,9 @@ dependencies = [ configopts = '-DBUILD_PYTHON=NO -DBUILD_PYTHON3=YES -Wno-dev -DCXX11="ON" -DDATA_DIR=%(installdir)s/data ' configopts += '-DUSE_OPENMP=ON -DUSE_HDF5=ON -DUSE_MPI=ON ' -# make sure the right Python is used +# Without this, the wrong (system) python is picked up by cmake +# in cases where the system python is newer than the one used in these EasyConfigs +# See PR # 19119 configopts += '-DPython3_EXECUTABLE=$EBROOTPYTHON/bin/python ' sanity_check_paths = { diff --git a/easybuild/easyconfigs/d/DP3/DP3-6.0-foss-2022a.eb b/easybuild/easyconfigs/d/DP3/DP3-6.0-foss-2022a.eb index 6ee878c3713..c18f4974acf 100644 --- a/easybuild/easyconfigs/d/DP3/DP3-6.0-foss-2022a.eb +++ b/easybuild/easyconfigs/d/DP3/DP3-6.0-foss-2022a.eb @@ -36,7 +36,9 @@ dependencies = [ ('AOFlagger', '3.4.0') ] -# make sure the right Python is used +# Without this, the wrong (system) python is picked up by cmake +# in cases where the system python is newer than the one used in these EasyConfigs +# See PR # 19119 configopts = '-DPython3_EXECUTABLE=$EBROOTPYTHON/bin/python ' sanity_check_paths = { diff --git a/easybuild/easyconfigs/e/EveryBeam/EveryBeam-0.5.2-foss-2022a.eb b/easybuild/easyconfigs/e/EveryBeam/EveryBeam-0.5.2-foss-2022a.eb index 48e5bd469f0..b61f0c86167 100644 --- a/easybuild/easyconfigs/e/EveryBeam/EveryBeam-0.5.2-foss-2022a.eb +++ b/easybuild/easyconfigs/e/EveryBeam/EveryBeam-0.5.2-foss-2022a.eb @@ -36,7 +36,9 @@ dependencies = [ ('libxml2', '2.9.13'), ] -# make sure the right Python is used +# Without this, the wrong (system) python is picked up by cmake +# in cases where the system python is newer than the one used in these EasyConfigs +# See PR # 19119 configopts = '-DPython3_EXECUTABLE=$EBROOTPYTHON/bin/python ' sanity_check_paths = { diff --git a/easybuild/easyconfigs/w/WSClean/WSClean-3.4-foss-2022a.eb b/easybuild/easyconfigs/w/WSClean/WSClean-3.4-foss-2022a.eb index 7822414a2b9..e3bdcb00894 100644 --- a/easybuild/easyconfigs/w/WSClean/WSClean-3.4-foss-2022a.eb +++ b/easybuild/easyconfigs/w/WSClean/WSClean-3.4-foss-2022a.eb @@ -31,7 +31,9 @@ dependencies = [ ('Python', '3.10.4'), ] -# make sure the right Python is used +# Without this, the wrong (system) python is picked up by cmake +# in cases where the system python is newer than the one used in these EasyConfigs +# See PR # 19119 configopts = '-DPython3_EXECUTABLE=$EBROOTPYTHON/bin/python ' sanity_check_paths = {