]> SALOME platform Git repositories - tools/sat_salome.git/commitdiff
Salome HOME
add TTK
authorNabil Ghodbane <nabil.ghodbane@cea.fr>
Thu, 29 Sep 2022 15:37:41 +0000 (17:37 +0200)
committerNabil Ghodbane <nabil.ghodbane@cea.fr>
Thu, 29 Sep 2022 15:37:41 +0000 (17:37 +0200)
applications/SALOME-master.pyconf
products/TTK.pyconf [new file with mode: 0644]
products/compil_scripts/TTK.sh [new file with mode: 0755]
products/compil_scripts/openturns-1.19.sh
products/env_scripts/TTK.py [new file with mode: 0644]

index 1a511f5085d3e4415d8fbd46abdf4a9746374e6d..aef4b089f71e6d2b2848cd85f5753d0bf7912551 100644 (file)
@@ -205,6 +205,10 @@ APPLICATION :
 }
 __overwrite__ :
 [
+    {
+        __condition__ : "VARS.dist not in ['DB09']"
+        'APPLICATION.rm_products' : ['TTK']
+    }
     {
         __condition__ : "VARS.dist not in ['DB09','DB10', 'DB11']"
         'APPLICATION.products.MeshGems' : {tag : '2.13-1', hpc : 'yes', base: 'no'}
diff --git a/products/TTK.pyconf b/products/TTK.pyconf
new file mode 100644 (file)
index 0000000..f87d196
--- /dev/null
@@ -0,0 +1,23 @@
+default :
+{
+    name : "TTK"
+    build_source : "script"
+    compil_script :  $name + $VARS.scriptExtension
+    get_source : "archive"
+    environ :
+    {
+       env_script : "TTK.py"
+    }
+    depend : ['Python', 'lapack', 'hdf5', 'tbb', 'nlopt', 'libxml2', 'eigen', 'matplotlib', 'ParaView', 'boost', 'qt', 'embree']
+    build_depend : ["cmake", "swig"]
+    opt_depend : ['openmpi']
+    patches : []
+    source_dir : $APPLICATION.workdir + $VARS.sep + 'SOURCES' + $VARS.sep + $name
+    build_dir : $APPLICATION.workdir + $VARS.sep + 'BUILD' + $VARS.sep + $name
+    install_dir : 'base'
+    properties :
+    {
+      single_install_dir : "no"
+      incremental : "yes"
+    }
+}
diff --git a/products/compil_scripts/TTK.sh b/products/compil_scripts/TTK.sh
new file mode 100755 (executable)
index 0000000..a77a094
--- /dev/null
@@ -0,0 +1,44 @@
+#!/bin/bash                                                                                                                                                                              
+
+echo "##########################################################################"
+echo "TTK" $VERSION
+echo "##########################################################################"
+
+CMAKE_OPTIONS=""
+CMAKE_OPTIONS+=" -DCMAKE_INSTALL_PREFIX:STRING=${PRODUCT_INSTALL}"
+CMAKE_OPTIONS+=" -DCMAKE_INSTALL_LIBDIR:STRING=lib"
+CMAKE_OPTIONS+=" -DCMAKE_BUILD_TYPE:STRING=Release"
+CMAKE_OPTIONS+=" -DTK_BUILD_PARAVIEW_PLUGINS=ON"
+
+echo
+echo "*** cmake" $CMAKE_OPTIONS
+rm -rf $BUILD_DIR
+mkdir -p $BUILD_DIR
+cd  $BUILD_DIR
+cmake $CMAKE_OPTIONS $SOURCE_DIR
+if [ $? -ne 0 ]
+then
+    echo "ERROR on cmake"
+    exit 1
+fi
+
+echo
+echo "*** make" $MAKE_OPTIONS
+make $MAKE_OPTIONS
+if [ $? -ne 0 ]
+then
+    echo "ERROR on make"
+    exit 2
+fi
+
+echo
+echo "*** make install"
+make install
+if [ $? -ne 0 ]
+then
+    echo "ERROR on make install"
+    exit 3
+fi
+
+echo
+echo "########## END"
index 2f38a1dec76ec370a248db0ed19a563db14a17f3..3880af297380b76f39fc978d78c3772b9ce5d177 100755 (executable)
@@ -109,6 +109,7 @@ fi
 echo
 echo "*** cmake" $CMAKE_OPTIONS
 
+rm -rf $BUILD_DIR
 mkdir -p $BUILD_DIR/openturns
 mkdir -p  $BUILD_DIR/cache/pip
 cd  $BUILD_DIR/openturns
diff --git a/products/env_scripts/TTK.py b/products/env_scripts/TTK.py
new file mode 100644 (file)
index 0000000..d1168cb
--- /dev/null
@@ -0,0 +1,14 @@
+#!/usr/bin/env python
+import os.path
+
+def set_env(env, prereq_dir, version):
+    env.set('TTK_ROOT_DIR', prereq_dir)
+    env.set('TTK_HOME', prereq_dir)
+    env.set('TTK_VERSION',version)
+    env.prepend('PATH', os.path.join(prereq_dir,'bin'))
+    env.prepend('LD_LIBRARY_PATH',os.path.join(prereq_dir, 'lib'))
+    pyver = 'python' + env.get('PYTHON_VERSION')
+    env.prepend('PYTHONPATH', os.path.join(prereq_dir, 'lib', pyver, 'site-packages'))
+
+def set_nativ_env(env):
+    pass