From fcb804bd7e8cd8dda8153b0551da6f0e3340800f Mon Sep 17 00:00:00 2001 From: Quentin Cozette Date: Thu, 12 Nov 2020 16:21:20 +0100 Subject: [PATCH] Native Debian build - adapt SALOME configuration, compil scripts (ParaView - netgen) and system_info (pyconf products) --- applications/SALOME-master-native.pyconf | 25 ++++++++--------------- products/PyQt.pyconf | 4 ++-- products/Python.pyconf | 6 ++++-- products/boost.pyconf | 8 ++------ products/cgns.pyconf | 2 +- products/compil_scripts/ParaView.sh | 21 ++++++++++++++++--- products/compil_scripts/netgen_5_3_1.sh | 13 +++++++++--- products/env_scripts/qt.py | 26 +++++++++++++++--------- products/freeimage.pyconf | 2 +- products/freetype.pyconf | 2 +- products/llvm.pyconf | 8 ++++---- products/qt.pyconf | 4 ++-- products/qwt.pyconf | 7 +++++++ products/scotch.pyconf | 2 +- products/snowballstemmer.pyconf | 2 +- products/sphinxintl.pyconf | 7 +++++++ products/tbb.pyconf | 2 +- 17 files changed, 87 insertions(+), 54 deletions(-) diff --git a/applications/SALOME-master-native.pyconf b/applications/SALOME-master-native.pyconf index 858c61e..5032054 100644 --- a/applications/SALOME-master-native.pyconf +++ b/applications/SALOME-master-native.pyconf @@ -29,7 +29,7 @@ APPLICATION : Babel : 'native' # Previous master version : '1.58.0' boost : 'native' - CAS : 'V7_4_0p1' + CAS : 'CR740-SALOME-PATCH' certifi : 'native' # Previous master version : '3.3.1' cgns : 'native' @@ -74,7 +74,7 @@ APPLICATION : llvm : 'native' markupsafe : 'native' matplotlib : 'native' - medfile : '4.1.0' + medfile : {section: 'default_Autotools', tag: '4.1.0'} # Previous master version : '13.0.6' mesa : 'native' MeshGems : '2.11-5' @@ -83,8 +83,8 @@ APPLICATION : netgen : '5.3.1_with_CAS_7.2' nlopt : '2.4.2' numpy : 'native' - omniORB : '4.2.2' - omniORBpy : '4.2.2' + omniORB : '4.2.4' + omniORBpy : '4.2.4' # Previous master version : '3.2.0' opencv : 'native' openssl : 'native' @@ -102,7 +102,7 @@ APPLICATION : Python : 'native' pytz : 'native' qt : 'native' - qwt : '6.1.2' + qwt : 'native' requests : 'native' scipy : 'native' # Previous master version : '6.0.4' (too old for native metis) @@ -131,9 +131,9 @@ APPLICATION : 'SHAPER' 'SHAPERSTUDY' 'RESTRICTED' - 'LIBBATCH' : {tag :'V2_4_3'} + 'LIBBATCH' : {tag :'V2_4_4'} 'KERNEL' - 'MEDCOUPLING' + 'MEDCOUPLING' : {section: 'default_int64'} 'GUI' 'GEOM' 'SMESH' @@ -192,15 +192,8 @@ APPLICATION : __overwrite__ : [ { - # - __condition__ : "VARS.dist in ['DB10']" - 'PRODUCTS.embree.default.depend' : ['ispc'] - } - - { - # as agreed, we don't build SALOME with OSpray support. - __condition__ : "VARS.dist in ['FD30']" - 'APPLICATION.rm_products' : ['embree', 'ispc', 'ospray'] + # Fedora is the only one to still offer both omniORB and omniORBpy + __condition__ : "VARS.dist in ['FD30', 'FD32']" 'APPLICATION.products.omniORB' : 'native' 'APPLICATION.products.omniORBpy' : 'native' } diff --git a/products/PyQt.pyconf b/products/PyQt.pyconf index 1054ca2..ef891cd 100644 --- a/products/PyQt.pyconf +++ b/products/PyQt.pyconf @@ -7,9 +7,9 @@ default : system_info : { rpm : ["python3-qt5"] - rpm_dev : [] + rpm_dev : ["python3-qt5-devel"] apt : ["python3-pyqt5"] - apt_dev : [] + apt_dev : ["pyqt5-dev", "pyqt5-dev-tools"] } environ : { diff --git a/products/Python.pyconf b/products/Python.pyconf index 0812669..8e18b56 100755 --- a/products/Python.pyconf +++ b/products/Python.pyconf @@ -6,9 +6,11 @@ default : get_source : "archive" system_info : { - rpm : ["python36"] + # Python is a mandatory part of current used Linux platforms, no need to check its presence therefore. + # As version of Python 3.x differs on each of them, a better solution would to eventually check the binary presence. + rpm : [] rpm_dev : [] - apt : ["python36"] + apt : [] apt_dev : [] } environ : diff --git a/products/boost.pyconf b/products/boost.pyconf index 84c4535..b98aa62 100644 --- a/products/boost.pyconf +++ b/products/boost.pyconf @@ -8,12 +8,8 @@ default : { rpm : ["boost"] rpm_dev : ["boost-devel"] - apt : ["libboost-regexr", "libboost-thread" , "libboost-serialization", - "libboost-chrono", "libboost-filesystem", "libboost-system", - "libboost-date-time"] - apt_dev : ["libboost-regexr-dev", "libboost-thread-dev", "libboost-serialization-dev", - "libboost-chrono-dev", "libboost-filesystem-dev", "libboost-system-dev", - "libboost-date-time-dev"] + apt : [] + apt_dev : ["libboost-all-dev"] } environ : { diff --git a/products/cgns.pyconf b/products/cgns.pyconf index 1cc0112..56e8f04 100644 --- a/products/cgns.pyconf +++ b/products/cgns.pyconf @@ -8,7 +8,7 @@ default : { rpm : ["cgnslib"] rpm_dev : ["cgnslib-devel"] - apt : ["libcgns3"] + apt : ["libcgns3.3"] apt_dev : ["libcgns-dev"] } environ : diff --git a/products/compil_scripts/ParaView.sh b/products/compil_scripts/ParaView.sh index 3ee02da..da48e73 100755 --- a/products/compil_scripts/ParaView.sh +++ b/products/compil_scripts/ParaView.sh @@ -76,7 +76,12 @@ CMAKE_OPTIONS="${CMAKE_OPTIONS} -DVTK_WRAP_PYTHON:BOOL=ON" if [ "${PYTHON_ROOT_DIR}" == "/usr" ] then CMAKE_OPTIONS="${CMAKE_OPTIONS} -DPython3_INCLUDE_DIR:STRING=${PYTHON_ROOT_DIR}/include/python${PYTHON_VERSION}m" - CMAKE_OPTIONS="${CMAKE_OPTIONS} -DPython3_LIBRARY:STRING=${PYTHON_ROOT_DIR}/lib64/libpython${PYTHON_VERSION}m.so" + if [ -z "$(hostnamectl | grep buster)" ] + then + CMAKE_OPTIONS="${CMAKE_OPTIONS} -DPython3_LIBRARY:STRING=${PYTHON_ROOT_DIR}/lib64/libpython${PYTHON_VERSION}m.so" + else + CMAKE_OPTIONS="${CMAKE_OPTIONS} -DPython3_LIBRARY:STRING=${PYTHON_ROOT_DIR}/lib/x86_64-linux-gnu/libpython${PYTHON_VERSION}m.so" + fi else CMAKE_OPTIONS="${CMAKE_OPTIONS} -DPython3_INCLUDE_DIR:STRING=${PYTHON_ROOT_DIR}/include/python${PYTHON_VERSION}" CMAKE_OPTIONS="${CMAKE_OPTIONS} -DPython3_LIBRARY:STRING=${PYTHON_ROOT_DIR}/lib/libpython${PYTHON_VERSION}.so" @@ -137,7 +142,12 @@ CMAKE_OPTIONS="${CMAKE_OPTIONS} -DVTK_MODULE_USE_EXTERNAL_ParaView_cgns:BOOL=ON" CMAKE_OPTIONS="${CMAKE_OPTIONS} -DCGNS_INCLUDE_DIR:PATH=${CGNS_ROOT_DIR}/include" if [ "$CGNS_ROOT_DIR" == "/usr" ] then - CMAKE_OPTIONS="${CMAKE_OPTIONS} -DCGNS_LIBRARY:PATH=${CGNS_ROOT_DIR}/lib64/libcgns.so" + if [ -z "$(hostnamectl | grep buster)" ] + then + CMAKE_OPTIONS="${CMAKE_OPTIONS} -DCGNS_LIBRARY:PATH=${CGNS_ROOT_DIR}/lib64/libcgns.so" + else + CMAKE_OPTIONS="${CMAKE_OPTIONS} -DCGNS_LIBRARY:PATH=${CGNS_ROOT_DIR}/lib/x86_64-linux-gnu/libcgns.so" + fi else CMAKE_OPTIONS="${CMAKE_OPTIONS} -DCGNS_LIBRARY:PATH=${CGNS_ROOT_DIR}/lib/libcgns.so" fi @@ -164,7 +174,12 @@ then CMAKE_OPTIONS="${CMAKE_OPTIONS} -DLIBXML2_INCLUDE_DIR:STRING=${LIBXML2_ROOT_DIR}/include/libxml2" if [ "${LIBXML2_ROOT_DIR}" == "/usr" ] then - CMAKE_OPTIONS="${CMAKE_OPTIONS} -DLIBXML2_LIBRARIES:STRING=${LIBXML2_ROOT_DIR}/lib64/libxml2.so" + if [ -z "$(hostnamectl | grep buster)" ] + then + CMAKE_OPTIONS="${CMAKE_OPTIONS} -DLIBXML2_LIBRARIES:STRING=${LIBXML2_ROOT_DIR}/lib64/libxml2.so" + else + CMAKE_OPTIONS="${CMAKE_OPTIONS} -DLIBXML2_LIBRARIES:STRING=${LIBXML2_ROOT_DIR}/lib/x86_64-linux-gnu/libxml2.so" + fi else CMAKE_OPTIONS="${CMAKE_OPTIONS} -DLIBXML2_LIBRARIES:STRING=${LIBXML2_ROOT_DIR}/lib/libxml2.so" fi diff --git a/products/compil_scripts/netgen_5_3_1.sh b/products/compil_scripts/netgen_5_3_1.sh index d2cc4d8..f29187a 100755 --- a/products/compil_scripts/netgen_5_3_1.sh +++ b/products/compil_scripts/netgen_5_3_1.sh @@ -61,9 +61,16 @@ echo "*** configure" BFLAG="-m64" OLEVEL="-O2" +TCL_INCLUDE_DIR=${TCLHOME}/include if [ "${TCLHOME}" == '/usr' ] then - TCL_LIB_DIR=${TCLHOME}/lib64 + if [ -z "$(hostnamectl | grep buster)" ] + then + TCL_LIB_DIR=${TCLHOME}/lib64 + else + TCL_LIB_DIR=${TCLHOME}/lib + TCL_INCLUDE_DIR=${TCLHOME}/include/tcl8.6 + fi else TCL_LIB_DIR=${TCLHOME}/lib fi @@ -72,14 +79,14 @@ echo ./configure --prefix=${PRODUCT_INSTALL} \ --with-tcl=${TCL_LIB_DIR} \ --with-tk=${TCL_LIB_DIR} \ --disable-openmp \ - --with-tclinclude=${TCLHOME}/include \ + --with-tclinclude=${TCL_INCLUDE_DIR} \ CXXFLAGS="-I${CASROOT}/include/opencascade ${OLEVEL} ${BFLAG} -std=c++0x" ./configure --prefix=${PRODUCT_INSTALL} \ --with-occ=${CASROOT} \ --with-tcl=${TCL_LIB_DIR} \ --with-tk=${TCL_LIB_DIR} \ --disable-openmp \ - --with-tclinclude=${TCLHOME}/include \ + --with-tclinclude=${TCL_INCLUDE_DIR} \ CXXFLAGS="-I${CASROOT}/include/opencascade ${OLEVEL} ${BFLAG} -std=c++0x" #-std=gnu++11" #-std=c++11 -std=c++0x" if [ $? -ne 0 ] diff --git a/products/env_scripts/qt.py b/products/env_scripts/qt.py index 8d42bb3..335cbb0 100644 --- a/products/env_scripts/qt.py +++ b/products/env_scripts/qt.py @@ -23,14 +23,20 @@ def set_env(env, prereq_dir, version): env.prepend('LD_LIBRARY_PATH', os.path.join(prereq_dir, 'lib')) def set_nativ_env(env): + + if "debian" in platform.platform() : + qt_lib_dir = '/usr/lib/x86_64-linux-gnu' + else : + qt_lib_dir = '/usr/lib64' + env.set('QT5_ROOT_DIR', '/usr') - env.set('Qt5Core_DIR', '/usr/lib64/cmake/Qt5Core') - env.set('Qt5Gui_DIR', '/usr/lib64/cmake/Qt5Gui') - env.set('Qt5Widgets_DIR', '/usr/lib64/cmake/Qt5Widgets') - env.set('Qt5Network_DIR', '/usr/lib64/cmake/Qt5Network') - env.set('Qt5Xml_DIR', '/usr/lib64/cmake/Qt5Xml') - env.set('Qt5OpenGL_DIR', '/usr/lib64/cmake/Qt5OpenGL') - env.set('Qt5PrintSupport_DIR', '/usr/lib64/cmake/Qt5PrintSupport') - env.set('Qt5Help_DIR', '/usr/lib64/cmake/Qt5Help') - env.set('Qt5Test_DIR', '/usr/lib64/cmake/Qt5Test') - env.set('Qt5X11Extras_DIR', '/usr/lib64/cmake/Qt5X11Extras') + env.set('Qt5Core_DIR', os.path.join(qt_lib_dir, 'cmake/Qt5Core')) + env.set('Qt5Gui_DIR', os.path.join(qt_lib_dir, 'cmake/Qt5Gui')) + env.set('Qt5Widgets_DIR', os.path.join(qt_lib_dir, 'cmake/Qt5Widgets')) + env.set('Qt5Network_DIR', os.path.join(qt_lib_dir, 'cmake/Qt5Network')) + env.set('Qt5Xml_DIR', os.path.join(qt_lib_dir, 'cmake/Qt5Xml')) + env.set('Qt5OpenGL_DIR', os.path.join(qt_lib_dir, 'cmake/Qt5OpenGL')) + env.set('Qt5PrintSupport_DIR', os.path.join(qt_lib_dir, 'cmake/Qt5PrintSupport')) + env.set('Qt5Help_DIR', os.path.join(qt_lib_dir, 'cmake/Qt5Help')) + env.set('Qt5Test_DIR', os.path.join(qt_lib_dir, 'cmake/Qt5Test')) + env.set('Qt5X11Extras_DIR', os.path.join(qt_lib_dir, 'cmake/Qt5X11Extras')) diff --git a/products/freeimage.pyconf b/products/freeimage.pyconf index 5f993e6..d5e5671 100644 --- a/products/freeimage.pyconf +++ b/products/freeimage.pyconf @@ -8,7 +8,7 @@ default : { rpm : ["freeimage"] rpm_dev : ["freeimage-devel"] - apt : ["libfreeimage"] + apt : ["libfreeimage3"] apt_dev : ["libfreeimage-dev"] } patches : [] diff --git a/products/freetype.pyconf b/products/freetype.pyconf index a245ca4..32109e4 100755 --- a/products/freetype.pyconf +++ b/products/freetype.pyconf @@ -8,7 +8,7 @@ default : { rpm : ["freetype"] rpm_dev : ["freetype-devel"] - apt : ["libfreetype"] + apt : ["libfreetype6"] apt_dev : ["libfreetype6-dev"] } environ : diff --git a/products/llvm.pyconf b/products/llvm.pyconf index d125f9d..14ce5ae 100644 --- a/products/llvm.pyconf +++ b/products/llvm.pyconf @@ -6,10 +6,10 @@ default : get_source : "archive" system_info : { - rpm : ["llvm-toolset"] - rpm_dev : [] - apt : [] - apt_dev : [] + rpm : [] + rpm_dev : ["llvm-devel", "clang-devel"] + apt : ["clang"] + apt_dev : ["llvm-dev"] } environ : { diff --git a/products/qt.pyconf b/products/qt.pyconf index 8c26d05..e455ad4 100644 --- a/products/qt.pyconf +++ b/products/qt.pyconf @@ -8,8 +8,8 @@ default: { rpm : [] rpm_dev : ["qt5-devel"] - apt : ["build-essential"] - apt_dev : ["libgl1-mesa-dev"] + apt : [] + apt_dev : ["qttools5-dev", "libqt5svg5-dev", "libqt5x11extras5-dev", "qtxmlpatterns5-dev-tools"] } environ : { diff --git a/products/qwt.pyconf b/products/qwt.pyconf index 1f8ff3c..8e1538f 100644 --- a/products/qwt.pyconf +++ b/products/qwt.pyconf @@ -4,6 +4,13 @@ default : build_source : "script" compil_script : $name + $VARS.scriptExtension get_source : "archive" + system_info : + { + rpm : ["qwt-qt5"] + rpm_dev : ["qwt-qt5-devel"] + apt : ["libqwt-qt5-6"] + apt_dev : ["libqwt-qt5-dev"] + } environ : { env_script : $name + ".py" diff --git a/products/scotch.pyconf b/products/scotch.pyconf index ce6a726..837fcac 100644 --- a/products/scotch.pyconf +++ b/products/scotch.pyconf @@ -8,7 +8,7 @@ default : { rpm : ["scotch"] rpm_dev : ["scotch-devel"] - apt : ["libscotch"] + apt : [] apt_dev : ["libscotch-dev"] } environ : diff --git a/products/snowballstemmer.pyconf b/products/snowballstemmer.pyconf index 13b7d96..eebcc58 100644 --- a/products/snowballstemmer.pyconf +++ b/products/snowballstemmer.pyconf @@ -8,7 +8,7 @@ default : { rpm : ["python3-snowballstemmer"] rpm_dev : [] - apt : ["python3-snowballstemmer"] + apt : ["python3-stemmer"] apt_dev : [] } environ : diff --git a/products/sphinxintl.pyconf b/products/sphinxintl.pyconf index 5804a43..9b90641 100644 --- a/products/sphinxintl.pyconf +++ b/products/sphinxintl.pyconf @@ -4,6 +4,13 @@ default : build_source : "script" compil_script : 'pip_install' + $VARS.scriptExtension get_source : "archive" + system_info : + { + rpm : [] + rpm_dev : [] + apt : ["sphinx-intl"] + apt_dev : [] + } environ : { env_script : "sphinxintl.py" diff --git a/products/tbb.pyconf b/products/tbb.pyconf index bae7f47..47a0a41 100644 --- a/products/tbb.pyconf +++ b/products/tbb.pyconf @@ -8,7 +8,7 @@ default : { rpm : ["tbb"] rpm_dev : ["tbb-devel"] - apt : ["libtbb"] + apt : ["libtbb2"] apt_dev : ["libtbb-dev"] } environ : -- 2.39.2