summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authormidipix <writeonce@midipix.org>2020-09-14 02:43:32 +0000
committermidipix <writeonce@midipix.org>2020-09-14 02:43:32 +0000
commit2c4e5f97a9937016257e70e4841404ca376e808f (patch)
treeae3191d9a69e0d9e979ef123cd96553645f371a2
parentd9e9392b897381cd59d12df926f2cbe68de74324 (diff)
downloadslibtool-2c4e5f97a9937016257e70e4841404ca376e808f.tar.bz2
slibtool-2c4e5f97a9937016257e70e4841404ca376e808f.tar.xz
driver: added -Xlinker support.
-rw-r--r--src/driver/slbt_driver_ctx.c9
-rw-r--r--src/skin/slbt_skin_default.c5
2 files changed, 14 insertions, 0 deletions
diff --git a/src/driver/slbt_driver_ctx.c b/src/driver/slbt_driver_ctx.c
index 78058aa..7e1e690 100644
--- a/src/driver/slbt_driver_ctx.c
+++ b/src/driver/slbt_driver_ctx.c
@@ -407,6 +407,15 @@ static int slbt_split_argv(
} else if (!strncmp(argv[i],"-L",2)) {
fcopy = true;
+ } else if (!strcmp(argv[i],"-Xlinker")) {
+ *dargv++ = dst;
+ *dst++ = '-';
+ *dst++ = 'W';
+ *dst++ = 'l';
+ *dst++ = ',';
+ strcpy(dst,argv[++i]);
+ dst += strlen(dst)+1;
+
} else if (!strcmp(argv[i],"--library-path")) {
*dargv++ = dst;
*dst++ = '-';
diff --git a/src/skin/slbt_skin_default.c b/src/skin/slbt_skin_default.c
index 51e7452..1f81148 100644
--- a/src/skin/slbt_skin_default.c
+++ b/src/skin/slbt_skin_default.c
@@ -276,6 +276,11 @@ const struct argv_option slbt_default_options[] = {
0,"<flag>",
"pass a raw flag to the compiler"},
+ {"Xlinker", 0,TAG_VERBATIM_FLAG,ARGV_OPTARG_REQUIRED,
+ ARGV_OPTION_HYBRID_ONLY|ARGV_OPTION_HYBRID_SPACE,
+ 0,"<flag>",
+ "pass a raw flag to the compiler linker-driver"},
+
{"XCClinker", 0,TAG_VERBATIM_FLAG,ARGV_OPTARG_REQUIRED,
ARGV_OPTION_HYBRID_ONLY|ARGV_OPTION_HYBRID_SPACE,
0,"<flag>",