From 79f475de93a274ee5ef733b4769686d2664144b0 Mon Sep 17 00:00:00 2001 From: Nabil Ghodbane Date: Wed, 2 Feb 2022 13:48:01 +0100 Subject: [PATCH] rearrange sections and add try except for qt.py environment file since distro missing on CO8 --- applications/SALOME-9.8.0-native.pyconf | 41 +++++++++++------------- applications/SALOME-master-native.pyconf | 33 +++++++++---------- products/ParaView.pyconf | 35 +++++++++++++++++++- products/env_scripts/qt.py | 14 ++++---- 4 files changed, 76 insertions(+), 47 deletions(-) diff --git a/applications/SALOME-9.8.0-native.pyconf b/applications/SALOME-9.8.0-native.pyconf index ce7c772..0e97603 100644 --- a/applications/SALOME-9.8.0-native.pyconf +++ b/applications/SALOME-9.8.0-native.pyconf @@ -200,8 +200,10 @@ __overwrite__ : } { # - __condition__ : "VARS.dist in ['UB20.04', 'CO8', 'FD32']" - 'APPLICATION.products.ParaView' : {tag: '5.9.0', base: 'no', section: 'version_5_9_0_CO8_FD32_UB20_0_4'} + __condition__ : "VARS.dist in ['UB20.04']" + 'APPLICATION.products.cminpack': 'native' + 'APPLICATION.products.PyFMI' : {tag: '2.5', base: 'no', section: 'version_2_5_no_pip' } + 'APPLICATION.products.ParaView' : {tag: '5.9.0', base: 'no', section: 'version_5_9_0_UB20_0_4'} } { # On DB10, ParaView fails to find xmlpatterns executable : ParaViewClient.cmake try to find it @@ -211,18 +213,30 @@ __overwrite__ : # As this version is compliant too, let's force it as the new minimum needed version. __condition__ : "VARS.dist in ['DB10']" 'APPLICATION.products.ParaView' : {tag: '5.9.0', base : 'no', section: 'version_5_9_0_DB10'} + 'APPLICATION.products.cminpack' : 'native' + 'APPLICATION.products.PyFMI' : {tag:'2.5', base: 'no', section: 'version_2_5_no_pip'} + } + { + __condition__ : "VARS.dist in ['DB11']" + 'APPLICATION.products.cminpack': 'native' + 'APPLICATION.products.PyFMI' : {tag:'2.5', base: 'no', section: 'version_2_5_no_pip'} + 'APPLICATION.products.ParaView' : {tag: '5.9.0', base : 'no', section: 'version_5_9_0_DB11'} } { # CentOS 8 repositories don't include sphinxintl package which must be installed through pip. # To avoid its missing (system_info pyconf key doesn't handle this use case), we embed it. __condition__ : "VARS.dist in ['CO8']" 'APPLICATION.products.sphinxintl' : {tag: '0.9.10', base: 'no', section: 'version_0_9_10_no_pip'} - 'APPLICATION.products.cmake' : '3.12.1' + 'APPLICATION.products.cminpack' : '1.3.6' + 'APPLICATION.products.PyFMI' : {tag: '2.5', base: 'no', section: 'version_2_5_no_pip' } + 'APPLICATION.products.statsmodels' : {tag: '0.6.1', base: 'no', section: 'version_0_6_1_no_pip' } + 'APPLICATION.products.ParaView' : {tag: '5.9.0', base: 'no', section: 'version_5_9_0_CO8' } } { __condition__ : "VARS.dist in ['FD32']" - 'APPLICATION.products.PyFMI' : {tag:'2.5', base: 'no', section: 'version_2_5_no_pip'} - 'APPLICATION.products.openturns' : {tag:'1.17', base: 'no', section: 'version_1_17_FD32' } + 'APPLICATION.products.PyFMI' : {tag: '2.5', base: 'no', section: 'version_2_5_no_pip'} + 'APPLICATION.products.openturns' : {tag: '1.17', base: 'no', section: 'version_1_17_FD32' } + 'APPLICATION.products.ParaView' : {tag: '5.9.0', base: 'no', section: 'version_5_9_0_FD32'} } { # FD 34 qt5 package is qt5-qtbase-devel. @@ -232,21 +246,4 @@ __overwrite__ : 'APPLICATION.products.PyFMI' : {tag: '2.5', base: 'no', section: 'version_2_5_no_pip' } 'APPLICATION.products.root' : {tag:'6.22.02', base: 'no', section: 'version_6_22_02_FD34'} } - { - __condition__ : "VARS.dist in ['DB10', 'UB20.04']" - 'APPLICATION.products.cminpack': 'native' - 'APPLICATION.products.PyFMI' : {tag:'2.5', base: 'no', section: 'version_2_5_no_pip'} - } - { - __condition__ : "VARS.dist in ['CO8']" - 'APPLICATION.products.cminpack' : '1.3.6' - 'APPLICATION.products.PyFMI' : {tag:'2.5', base: 'no', section: 'version_2_5_no_pip' } - 'APPLICATION.products.statsmodels' : {tag:'0.6.1', base : 'no', section: 'version_0_6_1_no_pip'} - } - { - __condition__ : "VARS.dist in ['DB11']" - 'APPLICATION.products.cminpack': 'native' - 'APPLICATION.products.PyFMI' : {tag:'2.5', base: 'no', section: 'version_2_5_no_pip'} - 'APPLICATION.products.ParaView' : {tag: '5.9.0', base : 'no', section: 'version_5_9_0_DB11'} - } ] diff --git a/applications/SALOME-master-native.pyconf b/applications/SALOME-master-native.pyconf index 58e178f..8172068 100644 --- a/applications/SALOME-master-native.pyconf +++ b/applications/SALOME-master-native.pyconf @@ -202,8 +202,10 @@ __overwrite__ : } { # - __condition__ : "VARS.dist in ['UB20.04', 'CO8', 'FD32']" - 'APPLICATION.products.ParaView' : {tag: '5.9.0', base: 'no', section: 'version_5_9_0_CO8_FD32_UB20_0_4', hpc: 'yes'} + __condition__ : "VARS.dist in ['UB20.04']" + 'APPLICATION.products.cminpack': 'native' + 'APPLICATION.products.PyFMI' : {tag: '2.5', base: 'no', section: 'version_2_5_no_pip' } + 'APPLICATION.products.ParaView' : {tag: '5.9.0', base: 'no', section: 'version_5_9_0_UB20_0_4', hpc: 'yes'} } { # On DB10, ParaView fails to find xmlpatterns executable : ParaViewClient.cmake try to find it @@ -212,23 +214,31 @@ __overwrite__ : # What is more, ParaView 5.9 CMake procedure requires Qt 5.12 as minimum version (5.11 here). # As this version is compliant too, let's force it as the new minimum needed version. __condition__ : "VARS.dist in ['DB10']" + 'APPLICATION.products.cminpack': 'native' + 'APPLICATION.products.PyFMI' : {tag:'2.5', base: 'no', section: 'version_2_5_no_pip' } 'APPLICATION.products.ParaView' : {tag: '5.9.0', base : 'no', section: 'version_5_9_0_DB10', hpc: 'yes'} } { __condition__ : "VARS.dist in ['DB11']" + 'APPLICATION.products.cminpack': 'native' + 'APPLICATION.products.PyFMI' : {tag:'2.5', base: 'no', section: 'version_2_5_no_pip' } 'APPLICATION.products.ParaView' : {tag: '5.9.0', base : 'no', section: 'version_5_9_0_DB11', hpc: 'yes'} } { # CentOS 8 repositories don't include sphinxintl package which must be installed through pip. # To avoid its missing (system_info pyconf key doesn't handle this use case), we embed it. __condition__ : "VARS.dist in ['CO8']" - 'APPLICATION.products.sphinxintl' : {tag: '0.9.10', base: 'no', section: 'version_0_9_10_no_pip'} - 'APPLICATION.products.cmake' : '3.12.1' + 'APPLICATION.products.sphinxintl' : {tag: '0.9.10', base: 'no', section: 'version_0_9_10_no_pip' } + 'APPLICATION.products.cminpack' : '1.3.6' + 'APPLICATION.products.PyFMI' : {tag: '2.5', base: 'no', section: 'version_2_5_no_pip' } + 'APPLICATION.products.statsmodels' : {tag: '0.6.1', base: 'no', section: 'version_0_6_1_no_pip' } + 'APPLICATION.products.ParaView' : {tag: '5.9.0', base: 'no', section: 'version_5_9_0_CO8', hpc: 'yes'} } { __condition__ : "VARS.dist in ['FD32']" - 'APPLICATION.products.PyFMI' : {tag:'2.5', base: 'no', section: 'version_2_5_no_pip'} - 'APPLICATION.products.openturns' : {tag:'1.17', base: 'no', section: 'version_1_17_FD32' } + 'APPLICATION.products.PyFMI' : {tag: '2.5', base: 'no', section: 'version_2_5_no_pip'} + 'APPLICATION.products.openturns' : {tag: '1.17', base: 'no', section: 'version_1_17_FD32' } + 'APPLICATION.products.ParaView' : {tag: '5.9.0', base: 'no', section: 'version_5_9_0_FD32'} } { # FD 34 qt5 package is qt5-qtbase-devel. @@ -238,15 +248,4 @@ __overwrite__ : 'APPLICATION.products.PyFMI' : {tag: '2.5', base: 'no', section: 'version_2_5_no_pip' } 'APPLICATION.products.root' : {tag:'6.22.02', base: 'no', section: 'version_6_22_02_FD34'} } - { - __condition__ : "VARS.dist in ['DB10', 'DB11', 'UB20.04']" - 'APPLICATION.products.cminpack': 'native' - 'APPLICATION.products.PyFMI' : {tag:'2.5', base: 'no', section: 'version_2_5_no_pip'} - } - { - __condition__ : "VARS.dist in ['CO8']" - 'APPLICATION.products.cminpack' : '1.3.6' - 'APPLICATION.products.PyFMI' : {tag:'2.5', base: 'no', section: 'version_2_5_no_pip' } - 'APPLICATION.products.statsmodels' : {tag:'0.6.1', base : 'no', section: 'version_0_6_1_no_pip'} - } ] diff --git a/products/ParaView.pyconf b/products/ParaView.pyconf index ee02ffe..c4abaa7 100755 --- a/products/ParaView.pyconf +++ b/products/ParaView.pyconf @@ -296,7 +296,7 @@ version_5_9_0_MPI_int32 : ] } -version_5_9_0_CO8_FD32_UB20_0_4 : +version_5_9_0_FD32 : { compil_script : 'ParaView-5.9.0.sh' archive_info : {archive_name : "ParaView-5.9.0-lata.tar.gz"} @@ -312,6 +312,39 @@ version_5_9_0_CO8_FD32_UB20_0_4 : ] } +version_5_9_0_UB_20_0_4 : +{ + compil_script : 'ParaView-5.9.0.sh' + archive_info : {archive_name : "ParaView-5.9.0-lata.tar.gz"} + # two other LATA patches already included in archive + patches : ['paraview.0003-ParaViewClient.patch', + 'paraview.0005-ParaView_find_cgns.patch', + 'paraview.0010-ParaView_CATALYST_cmake.patch', + 'paraview.0008-ParaView_coincident_rendering.patch', + 'paraview.0017-ParaView_protobuf_crash.patch', + 'paraview.0015-Paraview_VTKM_ioss.patch' + 'paraview.0018-spns-26351-autoconvert.patch', + 'paraview.0019-spns-26344-VTK-OpenMP.patch' + ] +} + +version_5_9_0_CO8 : +{ + compil_script : 'ParaView-5.9.0.sh' + archive_info : {archive_name : "ParaView-5.9.0-lata.tar.gz"} + # two other LATA patches already included in archive + patches : ['paraview.0003-ParaViewClient.patch', + 'paraview.0005-ParaView_find_cgns.patch', + 'paraview.0010-ParaView_CATALYST_cmake.patch', + 'paraview.0008-ParaView_coincident_rendering.patch', + 'paraview.0017-ParaView_protobuf_crash.patch', + 'paraview.0015-Paraview_VTKM_ioss.patch' + 'paraview.0018-spns-26351-autoconvert.patch', + 'paraview.0019-spns-26344-VTK-OpenMP.patch', + 'paraview.0020.findMPI.patch' + ] +} + version_5_9_0_DB10 : { compil_script : 'ParaView-5.9.0.sh' diff --git a/products/env_scripts/qt.py b/products/env_scripts/qt.py index 47c88c3..127df4c 100644 --- a/products/env_scripts/qt.py +++ b/products/env_scripts/qt.py @@ -23,13 +23,13 @@ def set_env(env, prereq_dir, version): env.prepend('LD_LIBRARY_PATH', os.path.join(prereq_dir, 'lib')) def set_nativ_env(env): - - import distro - if any(distribution in distro.name().lower() for distribution in ["debian", "ubuntu"]) : - qt_lib_dir='/usr/lib/x86_64-linux-gnu' - else : - qt_lib_dir='/usr/lib64' - + qt_lib_dir='/usr/lib64' + try: + import distro + if any(distribution in distro.name().lower() for distribution in ["debian", "ubuntu"]) : + qt_lib_dir='/usr/lib/x86_64-linux-gnu' + except: + pass env.set('QT5_ROOT_DIR', '/usr') env.set('Qt5Core_DIR', os.path.join(qt_lib_dir, 'cmake/Qt5Core')) env.set('Qt5Gui_DIR', os.path.join(qt_lib_dir, 'cmake/Qt5Gui')) -- 2.39.2