bug-libtool
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

FYI: Minor but annoying bug in ld.so.conf/ld.so.conf.d parsing in libtoo


From: Ralf Wildenhues
Subject: FYI: Minor but annoying bug in ld.so.conf/ld.so.conf.d parsing in libtool.m4
Date: Tue, 28 Mar 2006 20:12:52 +0200
User-agent: Mutt/1.5.9i

* Orion Poplawski wrote on Tue, Mar 28, 2006 at 07:15:28PM CEST:
> Ralf Wildenhues wrote:
> >Thanks for reporting this.  How about this instead?
> >
> >lt_ld_extra=`awk '/^include / { system(sprintf("cd /etc; cat %s 
> >2>/dev/null", \$2)); skip = 1; } { if (!skip) print \$0; skip = 0; }' < 
> >/etc/ld.so.conf | $SED -e 's/#.*//;s/[:,\t]/ /g;s/=[^=]*$//;s/=[^= ]* / 
> >/g;/^$/d' | tr '\n' ' '`
> 
> That looks good.

Thanks.  I'm installing the following patches in CVS HEAD and
branch-1-5, respectively.

> I also see this in libltdl/acinclude.m4 but I don't 
> know if it is a copy or originates from libtool.m4.

That is a generated file.  (CVS HEAD has less of this duplication.)

Cheers,
Ralf

HEAD:
        * libltdl/m4/libtool.m4 (_LT_SYS_DYNAMIC_LINKER) [ linux ]:
        Avoid warning when "parsing" `/etc/ld.so.conf' and empty
        `/etc/ld.so.conf.d'.
        Reported by Orion Poplawski <address@hidden>.

Index: libltdl/m4/libtool.m4
===================================================================
RCS file: /cvsroot/libtool/libtool/libltdl/m4/libtool.m4,v
retrieving revision 1.62
diff -u -r1.62 libtool.m4
--- libltdl/m4/libtool.m4       17 Mar 2006 04:20:17 -0000      1.62
+++ libltdl/m4/libtool.m4       28 Mar 2006 18:08:53 -0000
@@ -2291,7 +2291,7 @@
 
   # Append ld.so.conf contents to the search path
   if test -f /etc/ld.so.conf; then
-    lt_ld_extra=`awk '/^include / { system(sprintf("cd /etc; cat %s", \[$]2)); 
skip = 1; } { if (!skip) print \[$]0; skip = 0; }' < /etc/ld.so.conf | $SED -e 
's/#.*//;s/[:,   ]/ /g;s/=[^=]*$//;s/=[^= ]* / /g;/^$/d' | tr '\n' ' '`
+    lt_ld_extra=`awk '/^include / { system(sprintf("cd /etc; cat %s 
2>/dev/null", \[$]2)); skip = 1; } { if (!skip) print \[$]0; skip = 0; }' < 
/etc/ld.so.conf | $SED -e 's/#.*//;s/[:,       ]/ /g;s/=[^=]*$//;s/=[^= ]* / 
/g;/^$/d' | tr '\n' ' '`
     sys_lib_dlsearch_path_spec="/lib /usr/lib $lt_ld_extra"
   fi
 

branch-1-5:
        * libtool.m4 (AC_LIBTOOL_SYS_DYNAMIC_LINKER) [ linux ]:
        Avoid warning when "parsing" `/etc/ld.so.conf' and empty
        `/etc/ld.so.conf.d'.
        Reported by Orion Poplawski <address@hidden>.

Index: libtool.m4
===================================================================
RCS file: /cvsroot/libtool/libtool/Attic/libtool.m4,v
retrieving revision 1.314.2.151
diff -u -r1.314.2.151 libtool.m4
--- libtool.m4  17 Mar 2006 04:20:54 -0000      1.314.2.151
+++ libtool.m4  28 Mar 2006 18:09:35 -0000
@@ -1581,7 +1581,7 @@
 
   # Append ld.so.conf contents to the search path
   if test -f /etc/ld.so.conf; then
-    lt_ld_extra=`awk '/^include / { system(sprintf("cd /etc; cat %s", \[$]2)); 
skip = 1; } { if (!skip) print \[$]0; skip = 0; }' < /etc/ld.so.conf | $SED -e 
's/#.*//;s/[:,   ]/ /g;s/=[^=]*$//;s/=[^= ]* / /g;/^$/d' | tr '\n' ' '`
+    lt_ld_extra=`awk '/^include / { system(sprintf("cd /etc; cat %s 
2>/dev/null", \[$]2)); skip = 1; } { if (!skip) print \[$]0; skip = 0; }' < 
/etc/ld.so.conf | $SED -e 's/#.*//;s/[:,       ]/ /g;s/=[^=]*$//;s/=[^= ]* / 
/g;/^$/d' | tr '\n' ' '`
     sys_lib_dlsearch_path_spec="/lib /usr/lib $lt_ld_extra"
   fi
 




reply via email to

[Prev in Thread] Current Thread [Next in Thread]