diff options
author | Ian Lance Taylor <iant@google.com> | 2008-02-04 17:26:12 +0000 |
---|---|---|
committer | Ian Lance Taylor <iant@google.com> | 2008-02-04 17:26:12 +0000 |
commit | 1d503ee0f47136ae52be0975288d3b8f09efc356 (patch) | |
tree | 4a8af3e2e1a4704a7de209ef4da924cd5ad62da4 /gold/main.cc | |
parent | 186d6a3eb0612754e34b316f2e8811e6e5b3bdac (diff) | |
download | binutils-redhat-1d503ee0f47136ae52be0975288d3b8f09efc356.tar.gz |
From Craig Silverstein: support @file expansion.
Diffstat (limited to 'gold/main.cc')
-rw-r--r-- | gold/main.cc | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/gold/main.cc b/gold/main.cc index a6c9872180..2f68e06ec5 100644 --- a/gold/main.cc +++ b/gold/main.cc @@ -91,7 +91,10 @@ write_debug_script(std::string filename_str, FILE* fp = fopen(filename, "w"); if (fp) { - fprintf(fp, "[ \"$1\" = debug ] && PREFIX=\"${GDB-/home/build/static/projects/tools/gdb} --annotate=3 --fullname %s --args\" && shift\n", argv_0); + fprintf(fp, "[ \"$1\" = debug ]" + " && PREFIX=\"${GDB-gdb} --annotate=3 --fullname %s --args\"" + " && shift\n", + argv_0); fprintf(fp, "$PREFIX%s $*\n", args); fclose(fp); chmod(filename, 0755); @@ -132,6 +135,9 @@ main(int argc, char** argv) program_name = argv[0]; + // In libiberty; expands @filename to the args in "filename". + expandargv(&argc, &argv); + // This is used by write_debug_script(), which wants the unedited argv. std::string args = collect_argv(argc, argv); |