diff options
author | Cem Keylan <cem@ckyln.com> | 2020-04-30 11:22:07 +0300 |
---|---|---|
committer | Cem Keylan <cem@ckyln.com> | 2020-04-30 11:22:07 +0300 |
commit | d05d34425accf3a586de7f7c6df8dd7529e4c631 (patch) | |
tree | abeee952cc6a757c952c5eeaf4fa7cd02a25131a /extra/rsync/files/mkproto.awk | |
parent | 376b4914e8db81ec932acff57fded371b7d65164 (diff) | |
download | repository-d05d34425accf3a586de7f7c6df8dd7529e4c631.tar.gz |
rsync: move back to core
Diffstat (limited to 'extra/rsync/files/mkproto.awk')
-rw-r--r-- | extra/rsync/files/mkproto.awk | 39 |
1 files changed, 0 insertions, 39 deletions
diff --git a/extra/rsync/files/mkproto.awk b/extra/rsync/files/mkproto.awk deleted file mode 100644 index d3802f95..00000000 --- a/extra/rsync/files/mkproto.awk +++ /dev/null @@ -1,39 +0,0 @@ -#!/usr/bin/awk -f - -BEGIN { - while ((getline i < "proto.h") > 0) old_protos = old_protos ? old_protos "\n" i : i - protos = "/* This file is automatically generated with \"make proto\". DO NOT EDIT */\n" -} - -inheader { - protos = protos "\n" ((inheader = /\)[ \t]*$/ ? 0 : 1) ? $0 : $0 ";") - next -} - -/^FN_(LOCAL|GLOBAL)_[^(]+\([^,()]+/ { - local = /^FN_LOCAL/ - gsub(/^FN_(LOC|GLOB)AL_|,.*$/, "") - sub(/^BOOL\(/, "BOOL ") - sub(/^CHAR\(/, "char ") - sub(/^INTEGER\(/, "int ") - sub(/^STRING\(/, "char *") - protos = protos "\n" $0 (local ? "(int module_id);" : "(void);") - next -} - -/^static|^extern|;/||!/^[A-Za-z][A-Za-z0-9_]* / { next } - -/\(.*\)[ \t]*$/ { - protos = protos "\n" $0 ";" - next -} - -/\(/ { - inheader = 1 - protos = protos "\n" $0 -} - -END { - if (old_protos != protos) print protos > "proto.h" - print "" > "proto.h-tstamp" -} |