1 # This script generates the PS3 hypervisor call header from a hypervisor
2 # interface definition file. All lines that do not begin with HVCALL
3 # or a bare # for comments are copied to the output header so that
4 # enums, constant, C comments and the like can be passed through into the
7 # Invoke like so: awk -f ps3-hv-header.awk < ps3-hvcall.master > ps3-hv.h
12 !/HVCALL.*/ && (!/#.*/ || /#define.*/ || /#include.*/) {
24 for (i = 1; i <= length(ins); i++) {
25 printf("uint64_t %s", ins[i]);
26 if (i < length(ins)) printf(", ");
29 if (length(outs) > 0 && length(ins) > 0)
32 for (i = 1; i <= length(outs); i++) {
33 printf("uint64_t *%s", outs[i]);
34 if (i < length(outs)) printf(", ");
37 if (length(outs) == 0 && length(ins) == 0)