# Skip locals.
$2 == "l" { next }
-$2 == "g" || $2 == "w" && NF == 7 {
+# If the target uses ST_OTHER, it will be output before the symbol name.
+$2 == "g" || $2 == "w" && (NF == 7 || NF == 8) {
weak = $2;
type = $3;
size = $5;
sub(/^0*/, "", size);
size = " 0x" size;
version = $6;
- symbol = $7;
+ symbol = $NF;
gsub(/[()]/, "", version);
+ # binutils versions up through at least 2.23 have some bugs that
+ # caused STV_HIDDEN symbols to appear in .dynsym, though that is useless.
+ if (NF > 7 && $7 == ".hidden") next;
+
if (version == "GLIBC_PRIVATE") next;
desc = "";
type = "O";
seen_opd = 1;
}
+ else if (type == "D" && NF == 8 && $7 == "0x80") {
+ # Alpha functions avoiding plt entry in users
+ type = "F";
+ size = "";
+ seen_opd = -1;
+ }
else if ($4 == "*ABS*") {
type = "A";
size = "";
type = "F";
size = "";
}
+ else if (type == "iD" && ($4 == ".text" || $4 == ".opd")) {
+ # Indirect functions.
+ type = "F";
+ size = "";
+ }
else {
desc = symbol " " version " " weak " ? " type " " $4 " " $5;
}