aboutsummaryrefslogtreecommitdiff
path: root/gprof/gen-c-prog.awk
diff options
context:
space:
mode:
authorDaniel Jacobowitz <drow@false.org>2002-02-10 18:52:30 +0000
committerDaniel Jacobowitz <drow@false.org>2002-02-10 18:52:30 +0000
commit82fe033f4cc7acfa367258cd367c6dba4ad04cca (patch)
tree6056646e4f525e469097230b0b9c35bc2418544e /gprof/gen-c-prog.awk
parent408f8db182e9d020b5ba2af7d650314ddba1eb84 (diff)
downloadfsf-binutils-gdb-82fe033f4cc7acfa367258cd367c6dba4ad04cca.zip
fsf-binutils-gdb-82fe033f4cc7acfa367258cd367c6dba4ad04cca.tar.gz
fsf-binutils-gdb-82fe033f4cc7acfa367258cd367c6dba4ad04cca.tar.bz2
2002-02-10 Daniel Jacobowitz <drow@mvista.com>
* gprof.c: Include "getopt.h" after other includes, so that the proper macros are defined. * gen-c-prog.awk: Emit a prototype for the generated function.
Diffstat (limited to 'gprof/gen-c-prog.awk')
-rw-r--r--gprof/gen-c-prog.awk2
1 files changed, 2 insertions, 0 deletions
diff --git a/gprof/gen-c-prog.awk b/gprof/gen-c-prog.awk
index b59c1f8..b235a64 100644
--- a/gprof/gen-c-prog.awk
+++ b/gprof/gen-c-prog.awk
@@ -3,6 +3,7 @@ NR == 1 {
print "/* ==> Do not modify this file!! It is created automatically"
printf " from %s using the gen-c-prog.awk script. <== */\n\n", FILE
print "#include <stdio.h>"
+ print "#include \"ansidecl.h\""
}
{
@@ -12,6 +13,7 @@ NR == 1 {
print "}"
curfun = FUNCTION
print ""
+ print "void ", FUNCTION, "PARAMS ((FILE *));"
print "void";
printf "%s (file)\n", FUNCTION
print " FILE *file;";