Files
smb-decomp/disasm-tools/create_function_header.awk
2021-07-20 20:33:52 -05:00

18 lines
349 B
Awk
Executable File

#!/usr/bin/awk -f
# List all functions in the .text section, excluding ones that start with lbl_
BEGIN { inTextSection = 0 }
/^.* section layout/ {
inTextSection = ($1 == ".text");
}
inTextSection && /(entry of \.text)/ {
if (!match($4, /^lbl_/))
print("// ? "$4"();");
}
inTextSection && $4=="4" {
print("// ? "$5"();");
}