This is the mail archive of the binutils@sources.redhat.com mailing list for the binutils project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [PATCH] nm output fix for sysv format.


Hi Elias,

> This (not so perfect) patch fixes the output of nm, when it used
> with the sysv format. It eliminates output such as:
> 
> % nm -fsysv /usr/lib/libc.a
> [snipped]
> __pthread_initialize|        |   w  |                  |      |     |
> __pthread_initialize_minimal|        |   w  |                  |      |     |
> [snipped]
> 
> I would appreciate any feedback on that (even if the patch is not ok).

*sigh*.  I would like to accept this patch, but I am afraid that I
cannot.  The problem is that your patch splits the symbol name up over
multiple names, which means that nm's output would not work very well
with tools like grep.

Imagine searching for symbols containing the string 'minimal'.  With
the emaple output you have above, but with your patch applied, grep
would return:

  _minimal|        |      |                  |      |     |

which gives no indication of the symbol's class, and which implies
that the symbol's name is "_minimal" and not
"__pthread_initialize_minimal".

Cheers
        Nick


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]