OpenCores
URL https://opencores.org/ocsvn/open8_urisc/open8_urisc/trunk

Subversion Repositories open8_urisc

[/] [open8_urisc/] [trunk/] [gnu/] [binutils/] [gprof/] [gen-c-prog.awk] - Rev 41

Go to most recent revision | Compare with Previous | Blame | View Log

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>"
    print "#include \"ansidecl.h\""
}
 
	{
	  if (curfun != FUNCTION)
	    {
	      if (curfun)
		print "}"
	      curfun = FUNCTION
	      print ""
	      print "void ", FUNCTION, "(FILE *);"
	      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 "}" }
 

Go to most recent revision | Compare with Previous | Blame | View Log

powered by: WebSVN 2.1.0

© copyright 1999-2024 OpenCores.org, equivalent to Oliscience, all rights reserved. OpenCores®, registered trademark.