]> git.ipfire.org Git - thirdparty/libtool.git/commitdiff
libtool: avoid non-underscore symbols in the "dumpbin -symbols" wrapper
authorPeter Rosin <peda@lysator.liu.se>
Fri, 19 Oct 2012 06:54:15 +0000 (08:54 +0200)
committerPeter Rosin <peda@lysator.liu.se>
Fri, 19 Oct 2012 06:54:15 +0000 (08:54 +0200)
If an object has a symbol lacking an expected leading underscore,
the symbol name is not printed, but the symbol type is, leading
to output such as:
    T _normal _normal
    T T _another _another
when the expected output would have been something like:
    T _normal _normal
    T no_underscore no_underscore
    T _another _another
However, symbols lacking an expected leading underscore are
not "real" symbols, they are internal symbols which we don't
care about, therefore drop them instead.
* m4/libtool.m4 (_LT_CMD_GLOBAL_SYMBOLS) [MSVC]: Output the whole
symbol line in one go.
* NEWS: Update.

NEWS
m4/libtool.m4

diff --git a/NEWS b/NEWS
index d2e48d6321367f5a171801b27714f78c1fda2a83..17436b1cd57a0fd1b494c159c572bddb81e21e39 100644 (file)
--- a/NEWS
+++ b/NEWS
@@ -55,6 +55,8 @@ NEWS - list of user-visible changes between releases of GNU Libtool
     (e.g. the ability to parse `var+=append') as $CONFIG_SHELL, libtool
     will now correctly fallback to using only vanilla shell features
     instead of failing with a parse at startup.
+  - Fix a bug in the wrapper for using Microsoft dumpbin as name lister
+    which could lead to broken symbol listings in some corner cases.
 
 ** Important incompatible changes:
 
index 2dac8a13d6fea4763400c4cf909376a37ec71f25..d02bd252b8af5232bd9e2f52893cbbd16f6f9201 100644 (file)
@@ -3686,10 +3686,10 @@ for ac_symprfx in "" "_"; do
 "     \$ 0!~/External *\|/{next};"\
 "     / 0+ UNDEF /{next}; / UNDEF \([^|]\)*()/{next};"\
 "     {if(hide[section]) next};"\
-"     {f=0}; \$ 0~/\(\).*\|/{f=1}; {printf f ? \"T \" : \"D \"};"\
-"     {split(\$ 0, a, /\||\r/); split(a[2], s)};"\
-"     s[1]~/^[@?]/{print s[1], s[1]; next};"\
-"     s[1]~prfx {split(s[1],t,\"@\"); print t[1], substr(t[1],length(prfx))}"\
+"     {f=\"D\"}; \$ 0~/\(\).*\|/{f=\"T\"};"\
+"     {split(\$ 0,a,/\||\r/); split(a[2],s)};"\
+"     s[1]~/^[@?]/{print f,s[1],s[1]; next};"\
+"     s[1]~prfx {split(s[1],t,\"@\"); print f,t[1],substr(t[1],length(prfx))}"\
 "     ' prfx=^$ac_symprfx]"
   else
     lt_cv_sys_global_symbol_pipe="sed -n -e 's/^.*[[    ]]\($symcode$symcode*\)[[       ]][[    ]]*$ac_symprfx$sympat$opt_cr$/$symxfrm/p'"