BSD 4_4_Lite2 release
[unix-history] / usr / src / sys / sparc / sunos / makesyscalls.sh
index d16ee62..487652c 100644 (file)
@@ -1,5 +1,5 @@
 #! /bin/sh -
 #! /bin/sh -
-#      @(#)makesyscalls.sh     8.1 (Berkeley) 6/11/93
+#      @(#)makesyscalls.sh     8.2 (Berkeley) 4/3/95
 
 set -e
 
 
 set -e
 
@@ -39,7 +39,7 @@ awk < $1 "
                printf " * DO NOT EDIT-- this file is automatically generated.\n" > sysdcl
 
                printf "\n#ifdef %s\n", compat > syscompat
                printf " * DO NOT EDIT-- this file is automatically generated.\n" > sysdcl
 
                printf "\n#ifdef %s\n", compat > syscompat
-               printf "#define compat(n, name) n, __CONCAT(o,name)\n\n" > syscompat
+               printf "#define compat(n, name) n, n * 4, __CONCAT(compat_43_,name)\n\n" > syscompat
 
                printf "/*\n * System call names.\n *\n" > sysnames
                printf " * DO NOT EDIT-- this file is automatically generated.\n" > sysnames
 
                printf "/*\n * System call names.\n *\n" > sysnames
                printf " * DO NOT EDIT-- this file is automatically generated.\n" > sysnames
@@ -102,8 +102,8 @@ awk < $1 "
        }
        $2 == "STD" {
                printf("int\t%s();\n", $4) > sysdcl
        }
        $2 == "STD" {
                printf("int\t%s();\n", $4) > sysdcl
-               printf("\t{ %d, %s },\t\t\t/* %d = %s */\n", \
-                   $3, $4, syscall, $5) > sysent
+               printf("\t{ %d, %d, %s },\t\t\t/* %d = %s */\n", \
+                   $3, $3 * 4, $4, syscall, $5) > sysent
                printf("\t\"%s\",\t\t\t/* %d = %s */\n", \
                    $5, syscall, $5) > sysnames
                printf("#define\tSYS_%s\t%d\n", \
                printf("\t\"%s\",\t\t\t/* %d = %s */\n", \
                    $5, syscall, $5) > sysnames
                printf("#define\tSYS_%s\t%d\n", \
@@ -112,7 +112,7 @@ awk < $1 "
                next
        }
        $2 == "COMPAT" {
                next
        }
        $2 == "COMPAT" {
-               printf("int\to%s();\n", $4) > syscompat
+               printf("int\tcompat_43_%s();\n", $4) > syscompat
                printf("\t{ compat(%d,%s) },\t\t/* %d = old %s */\n", \
                    $3, $4, syscall, $5) > sysent
                printf("\t\"old.%s\",\t\t/* %d = old %s */\n", \
                printf("\t{ compat(%d,%s) },\t\t/* %d = old %s */\n", \
                    $3, $4, syscall, $5) > sysent
                printf("\t\"old.%s\",\t\t/* %d = old %s */\n", \
@@ -123,7 +123,7 @@ awk < $1 "
                next
        }
        $2 == "LIBCOMPAT" {
                next
        }
        $2 == "LIBCOMPAT" {
-               printf("int\to%s();\n", $4) > syscompat
+               printf("int\tcompat_43_%s();\n", $4) > syscompat
                printf("\t{ compat(%d,%s) },\t\t/* %d = old %s */\n", \
                    $3, $4, syscall, $5) > sysent
                printf("\t\"old.%s\",\t\t/* %d = old %s */\n", \
                printf("\t{ compat(%d,%s) },\t\t/* %d = old %s */\n", \
                    $3, $4, syscall, $5) > sysent
                printf("\t\"old.%s\",\t\t/* %d = old %s */\n", \
@@ -134,7 +134,7 @@ awk < $1 "
                next
        }
        $2 == "OBSOL" {
                next
        }
        $2 == "OBSOL" {
-               printf("\t{ 0, nosys },\t\t\t/* %d = obsolete %s */\n", \
+               printf("\t{ 0, 0, nosys },\t\t\t/* %d = obsolete %s */\n", \
                    syscall, comment) > sysent
                printf("\t\"obs_%s\",\t\t\t/* %d = obsolete %s */\n", \
                    $4, syscall, comment) > sysnames
                    syscall, comment) > sysent
                printf("\t\"obs_%s\",\t\t\t/* %d = obsolete %s */\n", \
                    $4, syscall, comment) > sysnames
@@ -144,7 +144,7 @@ awk < $1 "
                next
        }
        $2 == "UNIMPL" {
                next
        }
        $2 == "UNIMPL" {
-               printf("\t{ 0, nosys },\t\t\t/* %d = %s */\n", \
+               printf("\t{ 0, 0, nosys },\t\t\t/* %d = %s */\n", \
                    syscall, comment) > sysent
                printf("\t\"#%d\",\t\t\t/* %d = %s */\n", \
                    syscall, syscall, comment) > sysnames
                    syscall, comment) > sysent
                printf("\t\"#%d\",\t\t\t/* %d = %s */\n", \
                    syscall, syscall, comment) > sysnames
@@ -157,7 +157,7 @@ awk < $1 "
        }
        END {
                printf("\n#else /* %s */\n", compat) > syscompat
        }
        END {
                printf("\n#else /* %s */\n", compat) > syscompat
-               printf("#define compat(n, name) 0, nosys\n") > syscompat
+               printf("#define compat(n, name) 0, 0, nosys\n") > syscompat
                printf("#endif /* %s */\n\n", compat) > syscompat
 
                printf("};\n\n") > sysent
                printf("#endif /* %s */\n\n", compat) > syscompat
 
                printf("};\n\n") > sysent