1#!/bin/sh23#4# This job is very easy because app and kernel ABI are identical5# until the 4th parameter, so we only have to set the syscall6# number in rax78sed -n "9 s/[ ]*#.*//10 /$1/p" syscall.lst |11while read num name nargs12do13cat <<EOF > $name.s14 .file "$name.s"1516 .globl $name17$name:18 `case $nargs in 4|5|6)19 echo "movq %rcx,%r10"20 ;;21 esac`22 movq \$$num,%rax23 syscall24 jmp _cerrno25EOF26done