logo

oasis

Own branch of Oasis Linux (upstream: <https://git.sr.ht/~mcf/oasis/>) git clone https://anongit.hacktivis.me/git/oasis.git

unistd.awk (314B)


  1. BEGIN {
  2. guard = toupper("_ASM_" arch "_" file)
  3. gsub(/[^A-Za-z0-9_]/, "_", guard)
  4. print "#ifndef " guard
  5. print "#define " guard " 1"
  6. print ""
  7. }
  8. $0 ~ /^[^#]+/ && $2 ~ "^(" abi ")$" {
  9. if (off != "")
  10. $1 = "(" off " + " $1 ")"
  11. print "#define __NR_" $3, $1
  12. }
  13. END {
  14. print ""
  15. print "#endif /* " guard " */"
  16. }