ad2c(1) UNIX System V (April 1996) ad2c(1)
NAME
ad2c - convert resource files to C declarations
SYNOPSIS
ad2c [-a arrayname] [files]
DESCRIPTION
ad2c converts X resource files into C declarations,
appropriate for inclusion as fallback resources. The output
is a NULL terminated array of char *. The program itself is
a wrapper around a sed(1) script which is effectively a
finite state machine, escaping quotes and backslashes (and
newlines where necessary), and adding quotes and commas as
needed for array initialization.
ad2c reads from the given files (or stdin if none are given)
and writes the C array to stdout.
OPTIONS
-a arrayname
Name the produced array arrayname instead of the
default fallbacks.
files
Input application defaults files; the default is to
read from stdin.
RETURN VALUE
ad2c returns as for sed(1)
SEE ALSO
sed(1)
DISCLAIMER
This software is provided as is with no warranty expressed
or implied. I hope you find it useful, but I won't be held
responsable for any damage that may occur from reading,
compiling, installing or using it.
You are free to use any part of this code for other
purposes. It would be nice if you could keep my name on some
part of whatever the final product is.
AUTHORS
George Ferguson, ferguson@cs.rochester.edu.
Man page by Joseph Beckenbach, jerbil@ultra.com. Usage
section added by George Ferguson. Example corrected by Tim
Theisen, tim@cs.wisc.edu. Example further corrected by
David Wojtowicz, davidw@vista.atmos.uiuc.edu.
Modified to work with Gnu and IBM sed by Charles Hannum,
Page 1 (printed 8/26/99)
ad2c(1) UNIX System V (April 1996) ad2c(1)
mycroft@gnu.ai.mit.edu.
The -a switch was added by Eric Howe, mu@trends.net, as was
the production of an actual NULL terminated array.
Page 2 (printed 8/26/99)