Fixed setting output type for externals using utils

A new function "utils.GetOutput" takes care of the work, by modifying
os.Args.