Problem with xstr

Geoffrey D. Alexander alexande at unc.cs.unc.edu
Mon Sep 19 02:25:50 AEST 1988


I am using xstr as follow:

	cc prog.c -E | xstr -v -
	cc x.c -c -O -o x.o
	cc xs.c -c -O -o xs.o -R
	cc x.o xs.o -o prog
	rm x.c x.o xs.c xs.o
	strip prog

In some cases the C preprossor can generate fairly large lines, especially
when processing nested macros.  I am running to a problem with xstr producing
a syntatically incorrect translation on these large lines.  It appears that
xstr is partially substituting for a string.  For example, the string "test it"
might be substituted with "(&xstr[0])t it" in x.c where &xstr[0] references
"tes" in xs.c.  Does anyone have a suggestion on how to get around this problem
with xstr?

Note that I am running on SUN BSD UNIX 4.2.  Please e-mail responses directly
to me.

Thanks,
Geoff



More information about the Comp.unix.wizards mailing list