From: vsr Date: Mon, 12 May 2014 13:57:41 +0000 (+0400) Subject: Additional patch for ParaView 4.1: support native separators in PV_PLUGIN_PATH X-Git-Tag: V7_4_0~14^2 X-Git-Url: http://git.salome-platform.org/gitweb/?a=commitdiff_plain;h=94c9e128fd48521aeb48c4166efba8eeec44f7b0;p=tools%2Finstall.git Additional patch for ParaView 4.1: support native separators in PV_PLUGIN_PATH --- diff --git a/config_files/patches/ParaView-4.1.0.patch b/config_files/patches/ParaView-4.1.0.patch index bd52a60..87da8a5 100644 --- a/config_files/patches/ParaView-4.1.0.patch +++ b/config_files/patches/ParaView-4.1.0.patch @@ -367,3 +367,47 @@ diff -Naur --exclude=CVS ParaView-4.1.0_SRC-orig/Wrapping/Python/paraview/server self.__arrays = [] for i in range(0, nElems, 2): if self.GetElement(i+1) != '0': +diff -Naur ParaView-4.1.0_SRC-orig/ParaViewCore/ClientServerCore/Core/vtkPVPluginLoader.cxx ParaView-4.1.0_SRC-new/ParaViewCore/ClientServerCore/Core/vtkPVPluginLoader.cxx +--- ParaView-4.1.0_SRC-orig/ParaViewCore/ClientServerCore/Core/vtkPVPluginLoader.cxx 2014-01-11 17:59:57.000000000 +0400 ++++ ParaView-4.1.0_SRC-new/ParaViewCore/ClientServerCore/Core/vtkPVPluginLoader.cxx 2014-05-08 11:16:16.000000000 +0400 +@@ -42,6 +42,13 @@ + #define vtkPVPluginLoaderErrorMacro(x)\ + if (!no_errors) {vtkErrorMacro(<< x);} this->SetErrorString(x); + ++ ++#if defined(_WIN32) && !defined(__CYGWIN__) ++const char ENV_PATH_SEP=';'; ++#else ++const char ENV_PATH_SEP=':'; ++#endif ++ + namespace + { + // This is an helper class used for plugins constructed from XMLs. +@@ -195,7 +202,7 @@ + appDir += "/plugins"; + if(paths.size()) + { +- paths += ";"; ++ paths += ENV_PATH_SEP/*";"*/; + } + paths += appDir; + } +@@ -227,10 +234,15 @@ + << this->SearchPaths); + + std::vector paths; +- vtksys::SystemTools::Split(this->SearchPaths, paths, ';'); ++ vtksys::SystemTools::Split(this->SearchPaths, paths, ENV_PATH_SEP/*';'*/); + for (size_t cc=0; cc < paths.size(); cc++) + { +- this->LoadPluginsFromPath(paths[cc].c_str()); ++ std::vector subpaths; ++ vtksys::SystemTools::Split(paths[cc].c_str(), subpaths, ';'); ++ for (size_t scc=0; scc < subpaths.size(); scc++) ++ { ++ this->LoadPluginsFromPath(subpaths[scc].c_str()); ++ } + } + #else + vtkPVPluginLoaderDebugMacro(