old-cross-binutils/gprof/gen-c-prog.awk
J.T. Conklin 7858d8dc8a * gen-c-prog.awk: Changed reference to "make-c-prog.awk" in
comment emitted by this script to gen-c-prog.awk.

* Makefile.in, configure.in: Converted to use autoconf.
* configure: New file, generated with autoconf 2.3.
* config/{mt-alpha, mt-dummy, mt-i386, mt-ns532, mt-sparc,
  mt-tahoe, mt-vax}: Removed.
1995-04-19 18:27:35 +00:00

26 lines
568 B
Awk

NR == 1 {
FS="\"";
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>"
}
{
if (curfun != FUNCTION)
{
if (curfun)
print "}"
curfun = FUNCTION
print ""
print "void";
printf "%s (file)\n", FUNCTION
print " FILE *file;";
print "{";
}
printf " fputs (\"";
for (i = 1; i < NF; i++)
printf "%s\\\"", $i;
printf "%s\\n\", file);\n", $NF;
}
END { print "}" }