Pass shell=True to subprocess.Popen, which eliminates the need to escape double quotes and prepend /bin/sh -c to a tool dependency shell command.