From: dmv Date: Mon, 11 Aug 2008 08:39:18 +0000 (+0000) Subject: Bug IPAL20202 Qt4 porting: it is impossible to start application with "-t" option. X-Git-Tag: TG_TRIPOLI_qt4_porting~23 X-Git-Url: http://git.salome-platform.org/gitweb/?a=commitdiff_plain;h=f9345179ebef03a5f4b9460b8f796977cb60142c;p=modules%2Fkernel.git Bug IPAL20202 Qt4 porting: it is impossible to start application with "-t" option. --- diff --git a/bin/envSalome.py b/bin/envSalome.py index ed153d41b..1d0d61cb6 100755 --- a/bin/envSalome.py +++ b/bin/envSalome.py @@ -39,6 +39,6 @@ sys.argv = argv[1:] #args, modules_list, modules_root_dir = setenv.get_config() #runSalome.set_env(args, modules_list, modules_root_dir) -setenv.main(True); +setenv.main(); os.execvp(argv[0],argv) diff --git a/bin/setenv.py b/bin/setenv.py index 052e4d2e6..c5b9f418d 100755 --- a/bin/setenv.py +++ b/bin/setenv.py @@ -262,12 +262,13 @@ def set_env(args, modules_list, modules_root_dir, silent=False): = os.path.join(modules_root_dir["KERNEL"],"share", salome_subdir,"resources","kernel") - if sys.platform == 'win32': - graphicShr = "OCCViewer.dll" - else: - graphicShr = "libOCCViewer.so" - os.environ["CSF_GraphicShr"] \ - = os.path.join(modules_root_dir["GUI"],"lib","salome",graphicShr) + if "GUI" in modules_list: + if sys.platform == 'win32': + graphicShr = "OCCViewer.dll" + else: + graphicShr = "libOCCViewer.so" + os.environ["CSF_GraphicShr"] \ + = os.path.join(modules_root_dir["GUI"],"lib","salome",graphicShr) if "GEOM" in modules_list: if verbose() and not silent: print "GEOM OCAF Resources" @@ -289,9 +290,9 @@ def set_env(args, modules_list, modules_root_dir, silent=False): # ----------------------------------------------------------------------------- -def main(silent=False): - args, modules_list, modules_root_dir = get_config(silent=silent) - set_env(args, modules_list, modules_root_dir, silent=silent) +def main(): + args, modules_list, modules_root_dir = get_config() + set_env(args, modules_list, modules_root_dir) return args # -----------------------------------------------------------------------------