]> SALOME platform Git repositories - tools/sat_salome.git/commitdiff
Salome HOME
more robust approach aimed to check if a product is native/embedded
authorNabil Ghodbane <nabil.ghodbane@cea.fr>
Thu, 18 Aug 2022 13:36:52 +0000 (15:36 +0200)
committerNabil Ghodbane <nabil.ghodbane@cea.fr>
Thu, 18 Aug 2022 13:36:52 +0000 (15:36 +0200)
products/compil_scripts/PERSALYS-v11.0.sh
products/compil_scripts/ParaView-5.8.0.sh
products/compil_scripts/ParaView-5.9.0.sh
products/compil_scripts/ParaView.sh
products/compil_scripts/netcdf-4.6.2.sh
products/compil_scripts/openturns-1.18.sh
products/compil_scripts/zeromq-4.3.1.sh

index 4e2aa6c8dcbe4e09202945fe99a9195e720b049c..62c81afabd5fc5f50b0dd603e1ccd3c13aad757c 100755 (executable)
@@ -24,10 +24,11 @@ CMAKE_OPTIONS+=" -DOpenTURNS_DIR=$OT_ROOT_DIR/lib/cmake/openturns"
 CMAKE_OPTIONS+=" -DPy2cpp_DIR=$PY2CPP_ROOT_DIR//lib/cmake/py2cpp"
 
 # strangely Centos 8 fails to guess qwt installation
-if [[ $DIST_NAME == "CO" && $DIST_VERSION == "8" && $APPLICATION_NAME =~ native ]]; then
+
+if [[ $DIST_NAME == "CO" && $DIST_VERSION == "8" && "${SAT_qwt_IS_NATIVE}" == "1" ]]; then
     CMAKE_OPTIONS+=" -DQWT_LIBRARY=/usr/lib64/libqwt-qt5.so"
     CMAKE_OPTIONS+=" -DQWT_INCLUDE_DIR=/usr/include/qt5/qwt"
-elif [ "$QWT_ROOT_DIR" != "/usr" ]; then
+if [ "${SAT_qwt_IS_NATIVE}" != "1" ]; then
     CMAKE_OPTIONS+=" -DQWT_LIBRARY=$QWT_ROOT_DIR/lib/libqwt.so"
     CMAKE_OPTIONS+=" -DQWT_INCLUDE_DIR=$QWT_ROOT_DIR/include"
 fi
@@ -46,11 +47,11 @@ fi
 CMAKE_OPTIONS+=" -DPYTHON_EXECUTABLE=$PYTHONBIN"
 
 CMAKE_OPTIONS+=" -DPYTHON_INCLUDE_DIR=$PYTHON_INCLUDE"
-if [ "$PYTHON_ROOT_DIR" != "/usr" ]; then
+if [ "${SAT_Python_IS_NATIVE}" != "1" ]; then
     CMAKE_OPTIONS+=" -DPYTHON_LIBRARY=$PYTHON_ROOT_DIR/lib/libpython$PYTHON_VERSION.so"
 fi
 
-if [ "$SPHINX_ROOT_DIR" != "/usr" ]; then
+if [ "${SAT_Sphinx_IS_NATIVE}" != "1" ]; then
     CMAKE_OPTIONS+=" -DSPHINX_ROOT_DIR:FILEPATH=$SPHINX_ROOT_DIR"
     CMAKE_OPTIONS+=" -DSPHINX_EXECUTABLE:FILEPATH=$SPHINX_ROOT_DIR/bin/sphinx-build"
 fi
index 7fa8a19cdb797070655f7384adb1a1eda41e0a7a..457772519c29133a7678c16c3309c7a84fc0a8f9 100755 (executable)
@@ -102,8 +102,7 @@ CMAKE_OPTIONS="${CMAKE_OPTIONS} -DVTK_BUILD_QT_DESIGNER_PLUGIN:BOOL=OFF"
 ### Python settings
 CMAKE_OPTIONS="${CMAKE_OPTIONS} -DPARAVIEW_USE_PYTHON:BOOL=ON"
 CMAKE_OPTIONS="${CMAKE_OPTIONS} -DVTK_WRAP_PYTHON:BOOL=ON"
-if [ "${PYTHON_ROOT_DIR}" != "/usr" ]
-then
+if [ "${SAT_Python_IS_NATIVE}" != "1" ]; then
     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"
 fi
@@ -160,8 +159,7 @@ CMAKE_OPTIONS="${CMAKE_OPTIONS} -DHDF5_ROOT:PATH=${HDF5_ROOT_DIR}"
 
 ### CGNS
 CMAKE_OPTIONS="${CMAKE_OPTIONS} -DVTK_MODULE_USE_EXTERNAL_ParaView_cgns:BOOL=ON"
-if [ "$CGNS_ROOT_DIR" != "/usr" ]
-then
+if [ -n "$CGNS_ROOT_DIR" ] && [ "${SAT_cgns_IS_NATIVE}" != "1" ]; then
     CMAKE_OPTIONS="${CMAKE_OPTIONS} -DCGNS_INCLUDE_DIR:PATH=${CGNS_ROOT_DIR}/include"
     CMAKE_OPTIONS="${CMAKE_OPTIONS} -DCGNS_LIBRARY:PATH=${CGNS_ROOT_DIR}/lib/libcgns.so"
 fi
@@ -181,12 +179,10 @@ CMAKE_OPTIONS="${CMAKE_OPTIONS} -DBoost_NO_SYSTEM_PATHS:BOOL=ON"
 CMAKE_OPTIONS="${CMAKE_OPTIONS} -DVTK_MODULE_USE_EXTERNAL_VTK_gl2ps:BOOL=OFF"
 
 ### libxml2 settings
-if [ -n "$LIBXML2_ROOT_DIR" ]
-then
+if [ -n "$LIBXML2_ROOT_DIR" ]; then
     # with a native libxml2, do not use these options
     CMAKE_OPTIONS="${CMAKE_OPTIONS} -DVTK_MODULE_USE_EXTERNAL_VTK_libxml2:BOOL=ON"
-    if [ "${LIBXML2_ROOT_DIR}" != "/usr" ]
-    then
+    if [ "${SAT_libxml2_IS_NATIVE}" != "1" ]; then
         CMAKE_OPTIONS="${CMAKE_OPTIONS} -DLIBXML2_INCLUDE_DIR:STRING=${LIBXML2_ROOT_DIR}/include/libxml2"
         CMAKE_OPTIONS="${CMAKE_OPTIONS} -DLIBXML2_LIBRARIES:STRING=${LIBXML2_ROOT_DIR}/lib/libxml2.so"
         CMAKE_OPTIONS="${CMAKE_OPTIONS} -DLIBXML2_XMLLINT_EXECUTABLE=${LIBXML2_ROOT_DIR}/bin/xmllint"
@@ -195,8 +191,7 @@ fi
 
 ### freetype settings
 CMAKE_OPTIONS="${CMAKE_OPTIONS} -DVTK_MODULE_USE_EXTERNAL_VTK_freetype:BOOL=ON"
-if [ -n "$FREETYPE_ROOT_DIR" ]
-then
+if [ -n "$FREETYPE_ROOT_DIR" ] && [ "${SAT_freetype_IS_NATIVE}" != "1" ]; then
     # with a native freetype, do not use these options
     CMAKE_OPTIONS="${CMAKE_OPTIONS} -DFREETYPE_INCLUDE_DIRS:STRING=${FREETYPE_ROOT_DIR}/include/freetype2"
     CMAKE_OPTIONS="${CMAKE_OPTIONS} -DFREETYPE_LIBRARY:STRING=${FREETYPE_ROOT_DIR}/lib/libfreetype.so"
index f91b68ef4416030c73ab79dbcfaf6cffb89ba763..8cffe1c5936095185f53dd2ee97c803b72c76a71 100755 (executable)
@@ -185,8 +185,7 @@ CMAKE_OPTIONS+=" -DHDF5_IS_PARALLEL=OFF"
 
 ### CGNS
 CMAKE_OPTIONS+=" -DVTK_MODULE_USE_EXTERNAL_ParaView_cgns:BOOL=ON"
-if [ "${SAT_cgns_IS_NATIVE}" != "1" ]
-then
+if [ -n "$CGNS_ROOT_DIR" ] && [ "${SAT_cgns_IS_NATIVE}" != "1" ]; then
     CMAKE_OPTIONS+=" -DCGNS_INCLUDE_DIR:PATH=${CGNS_ROOT_DIR}/include"
     CMAKE_OPTIONS+=" -DCGNS_LIBRARY:PATH=${CGNS_ROOT_DIR}/lib/libcgns.so"
 fi
index 94d3fa2207f271e378e806d84842482892123507..d638d3d11eef3f4dedae6df7ec12c5f74b346c5e 100755 (executable)
@@ -100,8 +100,7 @@ CMAKE_OPTIONS="${CMAKE_OPTIONS} -DVTK_BUILD_QT_DESIGNER_PLUGIN:BOOL=OFF"
 ### Python settings
 CMAKE_OPTIONS="${CMAKE_OPTIONS} -DPARAVIEW_USE_PYTHON:BOOL=ON"
 CMAKE_OPTIONS="${CMAKE_OPTIONS} -DVTK_WRAP_PYTHON:BOOL=ON"
-if [ "${PYTHON_ROOT_DIR}" != "/usr" ]
-then
+if [ "${SAT_Python_IS_NATIVE}" != "1" ]; then
     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"
 fi
@@ -160,8 +159,7 @@ CMAKE_OPTIONS="${CMAKE_OPTIONS} -DHDF5_ROOT:PATH=${HDF5_ROOT_DIR}"
 
 ### CGNS
 CMAKE_OPTIONS="${CMAKE_OPTIONS} -DVTK_MODULE_USE_EXTERNAL_ParaView_cgns:BOOL=ON"
-if [ "$CGNS_ROOT_DIR" != "/usr" ]
-then
+if [ -n "$CGNS_ROOT_DIR" ] && [ "${SAT_cgns_IS_NATIVE}" != "1" ]; then
     CMAKE_OPTIONS="${CMAKE_OPTIONS} -DCGNS_INCLUDE_DIR:PATH=${CGNS_ROOT_DIR}/include"
     CMAKE_OPTIONS="${CMAKE_OPTIONS} -DCGNS_LIBRARY:PATH=${CGNS_ROOT_DIR}/lib/libcgns.so"
 fi
@@ -181,12 +179,10 @@ CMAKE_OPTIONS="${CMAKE_OPTIONS} -DBoost_NO_SYSTEM_PATHS:BOOL=ON"
 CMAKE_OPTIONS="${CMAKE_OPTIONS} -DVTK_MODULE_USE_EXTERNAL_VTK_gl2ps:BOOL=OFF"
 
 ### libxml2 settings
-if [ -n "$LIBXML2_ROOT_DIR" ]
-then
+if [ -n "$LIBXML2_ROOT_DIR" ]; then
     # with a native libxml2, do not use these options
     CMAKE_OPTIONS="${CMAKE_OPTIONS} -DVTK_MODULE_USE_EXTERNAL_VTK_libxml2:BOOL=ON"
-    if [ "${LIBXML2_ROOT_DIR}" != "/usr" ]
-    then
+    if [ "${SAT_libxml2_IS_NATIVE}" != "1" ]; then
         CMAKE_OPTIONS="${CMAKE_OPTIONS} -DLIBXML2_INCLUDE_DIR:STRING=${LIBXML2_ROOT_DIR}/include/libxml2"
         CMAKE_OPTIONS="${CMAKE_OPTIONS} -DLIBXML2_LIBRARIES:STRING=${LIBXML2_ROOT_DIR}/lib/libxml2.so"
         CMAKE_OPTIONS="${CMAKE_OPTIONS} -DLIBXML2_XMLLINT_EXECUTABLE=${LIBXML2_ROOT_DIR}/bin/xmllint"
@@ -195,8 +191,7 @@ fi
 
 ### freetype settings
 CMAKE_OPTIONS="${CMAKE_OPTIONS} -DVTK_MODULE_USE_EXTERNAL_VTK_freetype:BOOL=ON"
-if [ -n "$FREETYPE_ROOT_DIR" ]
-then
+if [ -n "$FREETYPE_ROOT_DIR" ] && [ "${SAT_freetype_IS_NATIVE}" != "1" ]; then
     # with a native freetype, do not use these options
     CMAKE_OPTIONS="${CMAKE_OPTIONS} -DFREETYPE_INCLUDE_DIRS:STRING=${FREETYPE_ROOT_DIR}/include/freetype2"
     CMAKE_OPTIONS="${CMAKE_OPTIONS} -DFREETYPE_LIBRARY:STRING=${FREETYPE_ROOT_DIR}/lib/libfreetype.so"
index 3ed646464da03e4516760c2e6472effd5f054c90..ec5c1870254591539be1a633320d91046c2b696e 100755 (executable)
@@ -21,14 +21,14 @@ CMAKE_OPTIONS+=" -DENABLE_TESTS=ON"
 CMAKE_OPTIONS+=" -DPYTHON_EXECUTABLE=${PYTHONBIN}"
 
 ### libxml2 settings
-if [ -n "$LIBXML2_ROOT_DIR" ] && [ "${LIBXML2_ROOT_DIR}" != "/usr" ]; then
+if [ -n "$LIBXML2_ROOT_DIR" ] && [ "${SAT_libxml2_IS_NATIVE}" != "1" ]; then
     CMAKE_OPTIONS+=" -DLIBXML2_INCLUDE_DIR:STRING=${LIBXML2_ROOT_DIR}/include/libxml2"
     CMAKE_OPTIONS+=" -DLIBXML2_LIBRARIES:STRING=${LIBXML2_ROOT_DIR}/lib/libxml2.so"
     CMAKE_OPTIONS+=" -DLIBXML2_XMLLINT_EXECUTABLE=${LIBXML2_ROOT_DIR}/bin/xmllint"
 fi
 
 # HDF5
-if [ -n "$HDF5_ROOT_DIR" ] && [ "${HDF5_ROOT_DIR}" != "/usr" ]; then
+if [ -n "$HDF5_ROOT_DIR" ] && [ "${SAT_hdf5_IS_NATIVE}" != "1" ]; then
     CMAKE_OPTIONS+=" -DHDF5_DIR:PATH=${HDF5_ROOT_DIR}/share/cmake/hdf5"
     CMAKE_OPTIONS+=" -DHDF5_USE_STATIC_LIBRARIES:BOOL=OFF"
     CMAKE_OPTIONS+=" -DHDF5_ROOT:PATH=${HDF5_ROOT_DIR}"
@@ -38,7 +38,7 @@ if [ -n "$HDF5_ROOT_DIR" ] && [ "${HDF5_ROOT_DIR}" != "/usr" ]; then
 fi
 
 ### libxml2 settings
-if [ -n "$LIBXML2_ROOT_DIR" ] && [ "${LIBXML2_ROOT_DIR}" != "/usr" ]; then
+if [ -n "$LIBXML2_ROOT_DIR" ] && [ "${SAT_libxml2_IS_NATIVE}" != "1" ]; then
     CMAKE_OPTIONS+=" -DLIBXML2_INCLUDE_DIR:STRING=${LIBXML2_ROOT_DIR}/include/libxml2"
     CMAKE_OPTIONS+=" -DLIBXML2_LIBRARIES:STRING=${LIBXML2_ROOT_DIR}/lib/libxml2.so"
     CMAKE_OPTIONS+=" -DLIBXML2_XMLLINT_EXECUTABLE=${LIBXML2_ROOT_DIR}/bin/xmllint"
index 9afbfd256b30b66fc81231e4faf4555ab7780d9b..719726a3e9b0c36e8389ed6aed6f2d15c80d9cab 100755 (executable)
@@ -332,12 +332,19 @@ if [[ -d "$SOURCE_DIR/otfftw-0.11" ]]; then
            DB10)
                 SITE_PATCH=/usr/lib/python3/dist-packages/setuptools/site-patch.py
                 ;;
+           UB22*)
+                SITE_PATCH=/usr/lib/pypy/dist-packages/setuptools/site-patch.py
+                ;;
            UB20*)
                 SITE_PATCH=/usr/lib/pypy/dist-packages/setuptools/site-patch.py
                 ;;
            FD32)
                 SITE_PATCH=/usr/lib/pypy/dist-packages/setuptools/site-patch.py
                 ;;
+           FD36)
+                ###SITE_PATCH=
+                SITE_PATCH=$SOURCE_DIR/addons/site-patch.py
+                ;;
            FD34)
                 ###SITE_PATCH=
                 SITE_PATCH=$SOURCE_DIR/addons/site-patch.py
index 5b02fd25dcb560c0df9b58625db719bd281ed08f..d29c0aa86af11de14b9f12e22757cb1d15dd800b 100755 (executable)
@@ -8,7 +8,7 @@ CMAKE_OPTIONS=""
 CMAKE_OPTIONS+=" -DCMAKE_INSTALL_PREFIX:STRING=${PRODUCT_INSTALL}"
 CMAKE_OPTIONS+=" -DCMAKE_INSTALL_LIBDIR:STRING=lib"
 ### libxml2 settings
-if [ -n "$LIBXML2_ROOT_DIR" ] && [ "${LIBXML2_ROOT_DIR}" != "/usr" ]; then
+if [ "${SAT_libxml2_IS_NATIVE}" != "1" ]; then
     CMAKE_OPTIONS+=" -DLIBXML2_INCLUDE_DIR:STRING=${LIBXML2_ROOT_DIR}/include/libxml2"
     CMAKE_OPTIONS+=" -DLIBXML2_LIBRARIES:STRING=${LIBXML2_ROOT_DIR}/lib/libxml2.so"
     CMAKE_OPTIONS+=" -DLIBXML2_XMLLINT_EXECUTABLE=${LIBXML2_ROOT_DIR}/bin/xmllint"