aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorKaz Kylheku <kaz@kylheku.com>2022-04-24 10:18:04 -0700
committerKaz Kylheku <kaz@kylheku.com>2022-04-24 10:18:04 -0700
commit7253942c532942d8789d45451e5aa6998c30cb32 (patch)
treeaac9d3e420d4ec5bf72d1f8c6984ae1542997241
parent78793aecce92e1be7c9d2ef92c22c1746366954f (diff)
downloadcppawk-7253942c532942d8789d45451e5aa6998c30cb32.tar.gz
cppawk-7253942c532942d8789d45451e5aa6998c30cb32.tar.bz2
cppawk-7253942c532942d8789d45451e5aa6998c30cb32.zip
man page: add origin-comment example.
-rw-r--r--cppawk.118
1 files changed, 18 insertions, 0 deletions
diff --git a/cppawk.1 b/cppawk.1
index 9dbc403..1a5d2f1 100644
--- a/cppawk.1
+++ b/cppawk.1
@@ -271,6 +271,24 @@ contains:
#define rule(\fIcond\fP) if (\fIcond\fP)
.ft R
+Produce an informative banner in generated output, as an Awk comment block.
+This is very useful when output is being generated and retained instead of
+being immediately executed, for instance for installation on a target system
+which has no preprocessor:
+
+.ft B
+ #define HASH #
+ HASH###################################################
+ HASH DO NOT EDIT!
+ HASH This file was generated from __FILE__ on __DATE__
+ HASH###################################################
+.ft R
+
+Note: this was tested to work with the GNU preprocessor. A spurious blank line
+may appear. The material in the Awk comments isn't a comment to the C
+preprocessor; it must consist of valid C preprocessor tokens, so the text must
+be chosen accordingly.
+
.SH "SEE ALSO"
awk(1), cpp(6), cppawk-narg(1), cppawk-case(1), cppawk-cons(1)