manpagez: man pages & more
info m4
Home | html | info | man
[ << ] [ < ] [ Up ] [ > ] [ >> ]         [Top] [Contents] [Index] [ ? ]

15.2 Frozen file format

Frozen files are sharable across architectures. It is safe to write a frozen file on one machine and read it on another, given that the second machine uses the same or newer version of GNU m4. It is conventional, but not required, to give a frozen file the suffix of .m4f.

These are simple (editable) text files, made up of directives, each starting with a capital letter and ending with a newline (<NL>). Wherever a directive is expected, the character ‘#’ introduces a comment line; empty lines are also ignored if they are not part of an embedded string. In the following descriptions, each len refers to the length of the corresponding strings str in the next line of input. Numbers are always expressed in decimal. There are no escape characters. The directives are:

C len1 , len2 <NL> str1 str2 <NL>

Uses str1 and str2 as the begin-comment and end-comment strings. If omitted, then ‘#’ and <NL> are the comment delimiters.

D number, len <NL> str <NL>

Selects diversion number, making it current, then copy str in the current diversion. number may be a negative number for a non-existing diversion. To merely specify an active selection, use this command with an empty str. With 0 as the diversion number, str will be issued on standard output at reload time. GNU m4 will not produce the ‘D’ directive with non-zero length for diversion 0, but this can be done with manual edits. This directive may appear more than once for the same diversion, in which case the diversion is the concatenation of the various uses. If omitted, then diversion 0 is current.

F len1 , len2 <NL> str1 str2 <NL>

Defines, through pushdef, a definition for str1 expanding to the function whose builtin name is str2. If the builtin does not exist (for example, if the frozen file was produced by a copy of m4 compiled with changeword support, but the version of m4 reloading was compiled without it), the reload is silent, but any subsequent use of the definition of str1 will result in a warning. This directive may appear more than once for the same name, and its order, along with ‘T’, is important. If omitted, you will have no access to any builtins.

Q len1 , len2 <NL> str1 str2 <NL>

Uses str1 and str2 as the begin-quote and end-quote strings. If omitted, then ‘`’ and ‘'’ are the quote delimiters.

T len1 , len2 <NL> str1 str2 <NL>

Defines, though pushdef, a definition for str1 expanding to the text given by str2. This directive may appear more than once for the same name, and its order, along with ‘F’, is important.

V number <NL>

Confirms the format of the file. m4 1.4.17 only creates and understands frozen files where number is 1. This directive must be the first non-comment in the file, and may not appear more than once.


[ << ] [ < ] [ Up ] [ > ] [ >> ]         [Top] [Contents] [Index] [ ? ]

This document was generated on September 29, 2013 using texi2html 5.0.

© manpagez.com 2000-2017
Individual documents may contain additional copyright information.