]> git.ipfire.org Git - thirdparty/libtool.git/commitdiff
Pick up clang_rt static archives compiler internal libraries
authorManoj Gupta <manojgupta@chromium.org>
Wed, 10 Oct 2018 07:50:23 +0000 (10:50 +0300)
committerIleana Dumitrescu <ileanadumitrescu95@gmail.com>
Thu, 7 Aug 2025 17:20:00 +0000 (20:20 +0300)
Libtool checks only for libraries linked as -l* when trying to
find internal compiler libraries. Clang, however uses the absolute
path to link its internal libraries e.g. compiler_rt. This patch
handles clang's statically linked libraries when finding internal
compiler libraries.
https://crbug.com/749263
https://debbugs.gnu.org/cgi/bugreport.cgi?bug=27866

m4/libtool.m4

index 4b4ea721a01cc5fcd4ac16aec488b712c3eedf9b..8e0a46bcb893c8f137fdf67bc8ae553b83a2bc07 100644 (file)
@@ -7758,7 +7758,7 @@ if AC_TRY_EVAL(ac_compile); then
   for p in `eval "$output_verbose_link_cmd"`; do
     case $prev$p in
 
-    -L* | -R* | -l*)
+    -L* | -R* | -l* | */libclang_rt.*.a)
        # Some compilers place space between "-{L,R,l}" and the path.
        # Remove the space.
        if test x-L = x"$p" ||