summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authormidipix <writeonce@midipix.org>2016-03-16 08:24:02 -0400
committermidipix <writeonce@midipix.org>2016-03-16 08:24:02 -0400
commit411564af27f7d3db87089c7dac0ad58e2026e96b (patch)
treecbabc251bcabe801eea5941a434acc799cd86ca0 /src
parentdb67ad0c89bc1100cc7371b8c4b264cc796d85ef (diff)
downloadslibtool-411564af27f7d3db87089c7dac0ad58e2026e96b.tar.bz2
slibtool-411564af27f7d3db87089c7dac0ad58e2026e96b.tar.xz
driver: handle --target provided as a compiler argument.
Diffstat (limited to 'src')
-rw-r--r--src/driver/slbt_driver_ctx.c9
1 files changed, 8 insertions, 1 deletions
diff --git a/src/driver/slbt_driver_ctx.c b/src/driver/slbt_driver_ctx.c
index 0dd94d4..3127f98 100644
--- a/src/driver/slbt_driver_ctx.c
+++ b/src/driver/slbt_driver_ctx.c
@@ -200,7 +200,14 @@ static int slbt_split_argv(
else if (!(strcmp("Xcompiler",&argv[i][1])))
*cargv++ = argv[++i];
- else {
+ else if (!(strncmp("-target=",&argv[i][1],strlen("-target="))))
+ *targv++ = argv[i++];
+
+ else if (!(strcmp("-target",&argv[i][1]))) {
+ *targv++ = argv[i++];
+ *targv++ = argv[i++];
+
+ } else {
for (option=options; option->long_name; option++)
if (!(strcmp(option->long_name,&argv[i][1])))
break;