summaryrefslogtreecommitdiffhomepage
diff options
context:
space:
mode:
authorBrian Callahan <bcallah@openbsd.org>2018-06-16 03:53:56 +0200
committerAndreas Fried <andreas.fried@kit.edu>2019-05-17 23:14:33 +0200
commit7703641da4bc8291f811a6b4c0f1911b126fe44a (patch)
tree4aa23d0d739a07c0d2b5bb2dfb8b9d8eb8d967c5
parentcb5bd0040854ad8650faf7fc329d870a0fb654f0 (diff)
Teach cparser about -fuse-ld.
Both clang and gcc use this option to select a linker other than the system default.
-rw-r--r--src/driver/options.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/src/driver/options.c b/src/driver/options.c
index 4aae3b3..5f18894 100644
--- a/src/driver/options.c
+++ b/src/driver/options.c
@@ -385,6 +385,8 @@ bool options_parse_linker(options_state_t *s)
} else if (simple_arg("pg", s)) {
set_target_option("gprof");
driver_add_flag(&ldflags_obst, "-pg");
+ } else if ((arg = equals_arg("fuse-ld", s)) != NULL) {
+ driver_add_flag(&ldflags_obst, "-fuse-ld=%s", arg);
} else if ((arg = equals_arg("print-file-name", s)) != NULL) {
print_file_name_file = arg;
s->action = action_print_file_name;