Salome HOME
0021308: Remove hard-coded dependency of the external mesh plugins from the SMESH...
authoreap <eap@opencascade.com>
Mon, 19 Mar 2012 12:32:35 +0000 (12:32 +0000)
committereap <eap@opencascade.com>
Mon, 19 Mar 2012 12:32:35 +0000 (12:32 +0000)
   adjust _pyHypothesisReader() for HexoticPLUGIN_ROOT_DIR but not HEXOTICPLUGIN_ROOT_DIR

src/SMESH_I/SMESH_2smeshpy.cxx

index 1b85abc80b781112d2503da57bbdd034c19969a5..6e7d8452f1480eea7852368ae48b6d46427fa1b6 100644 (file)
@@ -3783,7 +3783,12 @@ _pyHypothesisReader::_pyHypothesisReader()
       rootDirVar += "_ROOT_DIR";
 
       const char* rootDir = getenv( rootDirVar.c_str() );
-      if ( !rootDir || strlen(rootDir) == 0 ) continue;
+      if ( !rootDir || strlen(rootDir) == 0 )
+      {
+        rootDirVar = plugin + "_ROOT_DIR"; // HexoticPLUGIN_ROOT_DIR
+        rootDir = getenv( rootDirVar.c_str() );
+        if ( !rootDir || strlen(rootDir) == 0 ) continue;
+      }
 
       // get a separator from rootDir
       for ( pos = strlen( rootDir )-1; pos >= 0 && sep.empty(); --pos )