@@ -117,10 +117,12 @@ def callAndRecord(command, nocall = False, noshell = True):
117117 else :
118118 print ("WARN>>" ,env ,"<< optional env is not set" );
119119
120- print (' ==> command used.. ' + '_' .join (command ))
120+ ## print(' ==> command used.. '+'_'.join(command))
121+ print (' ==> command used.. ' + shlex .join (command ))
121122 if nocall == False :
122123 if noshell == False :
123- my_command = ' ' .join (command )
124+ ## my_command=' '.join(command)
125+ my_command = shlex .join (command )
124126 proc = Popen ([ my_command ], env = my_env , shell = True , stdout = PIPE , stderr = PIPE )
125127 retout , reterr = proc .communicate ()
126128 retVal = proc .poll ()
@@ -289,7 +291,9 @@ def installConfigMakeInstall(tarname, ucvmpath, type, config_data):
289291
290292 if "ConfigureFlags" in config_data and config_data ["ConfigureFlags" ] != "" :
291293 tmp = config_data ["ConfigureFlags" ].split (" " )
292- configure_array += shlex .split (config_data ["ConfigureFlags" ])
294+ flags = shlex .split (config_data ["ConfigureFlags" ])
295+ configure_array += flags
296+
293297 elif "Libraries" in config_data :
294298## this is to work with our embedded libraries being installed in UCVM_INSTALL_PATH
295299 needs_array = config_data ["Libraries" ]
@@ -1021,15 +1025,17 @@ def _add2orderedToInstallList(library):
10211025for library in librariesToInstall :
10221026 the_library = config_data ["libraries" ][library ]
10231027 if "UCVMConfigureFlags" in the_library and the_library ["UCVMConfigureFlags" ] != "" :
1024- flags = the_library ["UCVMConfigureFlags" ].split (" " )
1028+ tmp_flags = the_library ["UCVMConfigureFlags" ].split (" " )
1029+ flags = shlex .split (the_library ["UCVMConfigureFlags" ])
10251030 ucvm_conf_command += flags
10261031
10271032for model in modelsToInstall :
10281033 the_model = config_data ["models" ][model ]
10291034
10301035 # We need to append the ucvm configure flags.
10311036 if "UCVMConfigureFlags" in the_model and the_model ["UCVMConfigureFlags" ] != "" :
1032- flags = the_model ["UCVMConfigureFlags" ].split (" " )
1037+ tmp_flags = the_model ["UCVMConfigureFlags" ].split (" " )
1038+ flags = shlex .split (the_model ["UCVMConfigureFlags" ])
10331039 ucvm_conf_command += flags
10341040
10351041ucvm_conf_command .append ("--prefix=" + ucvmpath )
0 commit comments