| Index: tools/compile_test/compile_test.py
|
| diff --git a/tools/compile_test/compile_test.py b/tools/compile_test/compile_test.py
|
| index a52c0720209142af858d656a071ca43328dd3b16..79371a1fd05d2e03e098340527fc897faadad54c 100755
|
| --- a/tools/compile_test/compile_test.py
|
| +++ b/tools/compile_test/compile_test.py
|
| @@ -21,6 +21,7 @@ import tempfile
|
| def DoMain(argv):
|
| parser = optparse.OptionParser()
|
| parser.add_option('--code')
|
| + parser.add_option('--run-linker', action='store_true')
|
| parser.add_option('--on-success', default='')
|
| parser.add_option('--on-failure', default='')
|
|
|
| @@ -39,7 +40,12 @@ def DoMain(argv):
|
|
|
| o_path = os.path.join(tmpdir, 'test.o')
|
|
|
| - cxx_popen = subprocess.Popen([cxx, cxx_path, '-o', o_path, '-c'],
|
| + cxx_cmdline = [cxx, cxx_path, '-o', o_path]
|
| + if not options.run_linker:
|
| + cxx_cmdline.append('-c')
|
| + # Pass remaining arguments to the compiler.
|
| + cxx_cmdline += args
|
| + cxx_popen = subprocess.Popen(cxx_cmdline,
|
| stdout=subprocess.PIPE,
|
| stderr=subprocess.PIPE)
|
| cxx_stdout, cxx_stderr = cxx_popen.communicate()
|
|
|