Subject: Re: Searching for macro processor of some kind
To: Matthias Scheler <tron@zhadum.org.uk>
From: Greg A. Woods <woods@weird.com>
List: netbsd-users
Date: 12/10/2006 10:59:43
--pgp-sign-Multipart_Sun_Dec_10_10:59:39_2006-1
Content-Type: text/plain; charset=US-ASCII
Content-Transfer-Encoding: quoted-printable
At Sat, 9 Dec 2006 22:01:36 +0000,
Matthias Scheler wrote:
>=20
> I could hack together a Perl or shell script which does this. But I guess
> such a tool already exist. Any recommendations?
The canonical answer would be m4(1). It is _the_ macro processor that's
standard on anything unix-like.
There's also D'Arcy Cain's "generate" in pkgsrc (devel/generate).
There was also a thing introduced back in 1992 called "m5" that went
another step in macro language features, but I haven't seen too much of
anything about it since.
Google for "An Intensional macro Processor" to find a document that
gives a very good overview of many other macro processors and languages
and similar technology in its introduction.
If you're implementing the network appliance though (as opposed to just
managing one or more of them), then it would probably be better to add
variable assignment and expansion (and maybe variable scope) to its
input language directly rather than relying on a macro processor to
manipulate the input file.
--=20
Greg A. Woods
H:+1 416 218-0098 W:+1 416 489-5852 x122 VE3TCP RoboHack <woods@robohack.ca>
Planix, Inc. <woods@planix.com> Secrets of the Weird <woods@weird.com>
--pgp-sign-Multipart_Sun_Dec_10_10:59:39_2006-1
Content-Type: application/pgp-signature
Content-Transfer-Encoding: 7bit
-----BEGIN PGP SIGNATURE-----
Version: PGPfreeware 5.0i for non-commercial use
MessageID: aQiLX3egsdCmOJ4tVpWvlq+PZYXinnnl
iQA/AwUBRXwu72J7XxTCWceFEQKG5gCfWwCRVNyMgvika0UrPMMVQf423dIAn0vq
KuHPKOd6ZfV+Ecg3XzX/TqVN
=EnAm
-----END PGP SIGNATURE-----
--pgp-sign-Multipart_Sun_Dec_10_10:59:39_2006-1--