diff options
Diffstat (limited to '')
-rw-r--r-- | c/src/librdbg/src/awk.svc | 65 |
1 files changed, 0 insertions, 65 deletions
diff --git a/c/src/librdbg/src/awk.svc b/c/src/librdbg/src/awk.svc deleted file mode 100644 index 61e0bf68a2..0000000000 --- a/c/src/librdbg/src/awk.svc +++ /dev/null @@ -1,65 +0,0 @@ -######################################################################### -# -# Component: RDBG -# Module: awk.svc -# -# Synopsis: AWK script which transforms the server skeleton produced -# by rpcgen(1) into something suitable for RDB servers. -# -######################################################################### -# -# $Id$ -# -BEGIN { - headerstarted = 0 - withinproc = 0 - brack = 0 -} - -$1 ~ /^\/\*HEADER_START\*\/$/ { - headerstarted = 1 - printf("#include <rpc/types.h>\n"); - printf("#include <rpc/rpc.h>\n"); - printf("#include <stdio.h>\n"); - printf("#include <stdlib.h>\n"); - printf("#include <string.h>\n"); - printf("#include <bsp.h>\n"); - printf("#include <rdbg/servrpc.h>\n"); - printf("#include <rdbg/%s>\n", THEPROG); - printf("#define fprintf(a,b,c) printf(b,c)\n"); -} - -$1 ~ /^\/\*HEADER_END\*\/$/ { - headerstarted = 0 -} - -{ - if (headerstarted == 1) { - print $0 - } else if ($1 ~ /.*_2.*/) { - withinproc = 1 - printf("void\n"); - print $0 - } else if (withinproc == 1) { - if ($1 == "switch") { - print "\tDPRINTF ((\"remotedeb_2: %s (%d)\\n\", " - print "\t\t(unsigned) rqstp->rq_proc < " - print "\t\t(unsigned) (sizeof names / sizeof names[0]) ?" - print "\t\tnames [rqstp->rq_proc] : \"???\", " - print "\t\t(int) rqstp->rq_proc));\n" - } - for (i = 1; i <= NF; i++) { - if ($i == "{") { - brack++; - } else if ($i == "}") { - brack--; - if (brack == 0) { - withinproc = 0; - } - } - } - if ($1 != "_rpcsvcdirty" ) { - print $0 - } - } -} |