]> SALOME platform Git repositories - tools/pvdeliv.git/commitdiff
Salome HOME
restore all subprocess pipes - need a verbose/quiet mode
authorCédric Aguerre <cedric.aguerre@edf.fr>
Tue, 18 Oct 2016 16:57:49 +0000 (18:57 +0200)
committerCédric Aguerre <cedric.aguerre@edf.fr>
Tue, 18 Oct 2016 16:57:49 +0000 (18:57 +0200)
scripts/salome_compile.py

index 4b837d28f7b10fdb0e73ca4bcc8ca041fd025258..587955ed51b7d18d245493d24f9fd981735fa7ce 100644 (file)
@@ -18,7 +18,7 @@ def __getCurrentVersion(srcDir,pattern, config):
     return s
   elif isinstance(srcLoc,tuple):
     dirGitLoc=os.path.splitext(os.path.basename(srcLoc[0]))[0]
-    p=subprocess.Popen(["git","rev-parse","--verify","HEAD"],cwd=dirGitLoc)
+    p=subprocess.Popen(["git","rev-parse","--verify","HEAD"],cwd=dirGitLoc,stdout=subprocess.PIPE,stderr=subprocess.PIPE)
     p_out,p_err=p.communicate()
     if p.returncode != 0:
       msg = "Error in __getCurrentVersion\n" + p_err
@@ -117,7 +117,7 @@ def __compileOldCommon(topSrcDir,pattern,config,envAcc,srcDir,topBuildDir,topIns
       return myInstallDir
     myCmd=[os.path.join(srcDir,"configure"),"--prefix=%s"%(myInstallDir)]+addCfgParam
     print "Command: ", " ".join(myCmd)
-    p=subprocess.Popen(myCmd,cwd=myBuildDir,env=computeEnv(envAcc))
+    p=subprocess.Popen(myCmd,cwd=myBuildDir,env=computeEnv(envAcc),stdout=subprocess.PIPE,stderr=subprocess.PIPE)
     __compilePart1(p,myBuildDir)
     __compilePart2(topSrcDir,pattern,config,envAcc,myBuildDir,splitInstall)
     return myInstallDir
@@ -134,7 +134,7 @@ def compileNew(topSrcDir,pattern,config,envAcc,srcDir,topBuildDir,topInstallDir,
       return myInstallDir
     myCmd=["cmake","-DCMAKE_INSTALL_PREFIX=%s"%(myInstallDir)]+addCfgParam+[srcDir]
     print(" ".join(myCmd))
-    p=subprocess.Popen(myCmd,cwd=myBuildDir,env=computeEnv(envAcc))
+    p=subprocess.Popen(myCmd,cwd=myBuildDir,env=computeEnv(envAcc),stdout=subprocess.PIPE,stderr=subprocess.PIPE)
     __compilePart1(p,myBuildDir)
     __compilePart2(topSrcDir,pattern,config,envAcc,myBuildDir,False)
     return myInstallDir