summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authoraakropotkin <alex.ameen.tx@gmail.com>2021-11-18 21:24:47 -0600
committeraakropotkin <alex.ameen.tx@gmail.com>2021-11-18 21:24:47 -0600
commit1b74d78401d7e09d5c31f4d479109d9b52984a32 (patch)
treed56961913f33892c36b434cb2e409f69bc1fd1b9
parent86d71e869d998fb09bee543a2aaef7beb6d6f591 (diff)
downloadlibtool-1b74d78401d7e09d5c31f4d479109d9b52984a32.tar.gz
libtool: Add -Wa,* link-mode flag for assembler pass-thru
* build-aux/ltmain.in: add -Wa,* as link-mode flag. Add help messages for -Wa,* and -Xassember in link mode. Add help message for -Xcompiler in compile mode. * doc/libtool.texi: document -Xassembler and -Wa,* for link-mode.
-rw-r--r--build-aux/ltmain.in8
-rw-r--r--doc/libtool.texi6
2 files changed, 12 insertions, 2 deletions
diff --git a/build-aux/ltmain.in b/build-aux/ltmain.in
index fa2e1b5f..0a9adc84 100644
--- a/build-aux/ltmain.in
+++ b/build-aux/ltmain.in
@@ -1751,7 +1751,8 @@ This mode accepts the following additional options:
-prefer-non-pic try to build non-PIC objects only
-shared do not build a '.o' file suitable for static linking
-static only build a '.o' file suitable for static linking
- -Wc,FLAG pass FLAG directly to the compiler
+ -Wc,FLAG
+ -Xcompiler FLAG pass FLAG directly to the compiler
COMPILE-COMMAND is a command to be used in creating a 'standard' object file
from the given SOURCEFILE.
@@ -1857,6 +1858,8 @@ The following components of LINK-COMMAND are treated specially:
-weak LIBNAME declare that the target provides the LIBNAME interface
-Wc,FLAG
-Xcompiler FLAG pass linker-specific FLAG directly to the compiler
+ -Wa,FLAG
+ -Xassembler FLAG pass linker-specific FLAG directly to the assembler
-Wl,FLAG
-Xlinker FLAG pass linker-specific FLAG directly to the linker
-XCClinker FLAG pass link-specific FLAG to the compiler driver (CC)
@@ -5392,10 +5395,11 @@ func_mode_link ()
# -stdlib=* select c++ std lib with clang
# -fsanitize=* Clang/GCC memory and address sanitizer
# -fuse-ld=* Linker select flags for GCC
+ # -Wa,* Pass flags directly to the assembler
-64|-mips[0-9]|-r[0-9][0-9]*|-xarch=*|-xtarget=*|+DA*|+DD*|-q*|-m*| \
-t[45]*|-txscale*|-p|-pg|--coverage|-fprofile-*|-F*|@*|-tp=*|--sysroot=*| \
-O*|-g*|-flto*|-fwhopr*|-fuse-linker-plugin|-fstack-protector*|-stdlib=*| \
- -specs=*|-fsanitize=*|-fuse-ld=*)
+ -specs=*|-fsanitize=*|-fuse-ld=*|-Wa,*)
func_quote_arg pretty "$arg"
arg=$func_quote_arg_result
func_append compile_command " $arg"
diff --git a/doc/libtool.texi b/doc/libtool.texi
index 6d88690c..3caab104 100644
--- a/doc/libtool.texi
+++ b/doc/libtool.texi
@@ -1616,6 +1616,12 @@ Pass a linker-specific flag directly to the compiler. With @code{-Wc,},
multiple flags may be separated by commas, whereas @code{-Xcompiler }
passes through commas unchanged.
+@item -Wa,@var{flag}
+@itemx -Xassembler @var{flag}
+Pass a linker-specific flag directly to the assembler. With @code{-Wa,},
+multiple flags may be separated by commas, whereas @code{-Xassembler }
+passes through commas unchanged.
+
@item -Wl,@var{flag}
@itemx -Xlinker @var{flag}
Pass a linker-specific flag directly to the linker.