summaryrefslogtreecommitdiffstats
path: root/clang/docs/CommandGuide
diff options
context:
space:
mode:
authorMichal Gorny <mgorny@gentoo.org>2016-10-10 12:23:40 +0000
committerMichal Gorny <mgorny@gentoo.org>2016-10-10 12:23:40 +0000
commit7cfe480122b81a3b19f0a0d9a4d22f68da161f08 (patch)
tree038749703bfcdafcc2f0d69252a8528149cfdf78 /clang/docs/CommandGuide
parentc9edc2ee8d97618ebb0702f66202720b3b8cb29a (diff)
downloadbcm5719-llvm-7cfe480122b81a3b19f0a0d9a4d22f68da161f08.tar.gz
bcm5719-llvm-7cfe480122b81a3b19f0a0d9a4d22f68da161f08.zip
[Driver] Make -print-libgcc-file-name print compiler-rt lib when used
Make the -print-libgcc-file-name option print an appropriate compiler runtime library, that is libgcc.a if gcc runtime is used and an appropriate compiler-rt library if that runtime is used. The main use for this is to allow linking executables built with -nodefaultlibs (e.g. to avoid linking to the standard C++ library) to the compiler runtime library, e.g. using: clang++ ... -nodefaultlibs $(clang++ ... -print-libgcc-file-name) in which case currently a program built like this linked to the gcc runtime unconditionally. The patch fixes it to use compiler-rt libraries instead when compiler-rt is the active runtime. Differential Revision: https://reviews.llvm.org/D25338 llvm-svn: 283746
Diffstat (limited to 'clang/docs/CommandGuide')
-rw-r--r--clang/docs/CommandGuide/clang.rst3
1 files changed, 2 insertions, 1 deletions
diff --git a/clang/docs/CommandGuide/clang.rst b/clang/docs/CommandGuide/clang.rst
index 14c81270e17..c71544915e4 100644
--- a/clang/docs/CommandGuide/clang.rst
+++ b/clang/docs/CommandGuide/clang.rst
@@ -394,7 +394,8 @@ Driver Options
.. option:: -print-libgcc-file-name
- Print the library path for "libgcc.a".
+ Print the library path for the currently used compiler runtime library
+ ("libgcc.a" or "libclang_rt.builtins.*.a").
.. option:: -print-prog-name=<name>
OpenPOWER on IntegriCloud