| 1 | |
| 2 | |
| 3 | @@ -23,11 +23,12 @@ from __future__ import print_function
|
| 4 |
|
| 5 | from optparse import OptionParser
|
| 6 | import os
|
| 7 | -import pipes
|
| 8 | import string
|
| 9 | import subprocess
|
| 10 | import sys
|
| 11 |
|
| 12 | +from shlex import quote
|
| 13 | +
|
| 14 | sourcedir = os.path.dirname(os.path.realpath(__file__))
|
| 15 | sys.path.insert(0, os.path.join(sourcedir, 'misc'))
|
| 16 | import ninja_syntax
|
| 17 | @@ -259,7 +260,7 @@ n.variable('configure_args', ' '.join(configure_args))
|
| 18 | env_keys = set(['CXX', 'AR', 'CFLAGS', 'LDFLAGS'])
|
| 19 | configure_env = dict((k, os.environ[k]) for k in os.environ if k in env_keys)
|
| 20 | if configure_env:
|
| 21 | - config_str = ' '.join([k + '=' + pipes.quote(configure_env[k])
|
| 22 | + config_str = ' '.join([k + '=' + quote(configure_env[k])
|
| 23 | for k in configure_env])
|
| 24 | n.variable('configure_env', config_str + '$ ')
|
| 25 | n.newline()
|