'Given an environment, returns a string looking like
\'export FOO=foo; export BAR="${FOO} bar;\'
that exports |env| to the shell.'

def ComputeExportEnvString(self, env):

    export_str = []
    for (k, v) in env:
        export_str.append(('export    %s=%s;' % (k, ninja_syntax.escape(gyp.common.EncodePOSIXShellArgument(v)))))
    return '    '.join(export_str)
