I grabbed the patched BSD indent from a mirror. Here's a couple of points:
. with a little trial and error GNU indent 2.2.9 actually did quite a
reasonable job for me last night. But I guess YMMV. I'm curious to know
what nasty mangling it does.
. the file is a compressed tar file - it would be better to have a file
extension of .tgz or .tar.gz instead of just .gz, so that this is apparent.
. I had to hack the makefile for my linux box for a reasonably clean
build, so that the CFLAGS on the install line doesn't override setting
the defines, and the compiler won't complain about isblank and/or strdup
and/or fileno. The diff is attached for anyone interested.
cheers
andrew
4d3
< #
6,7c5,6
< XFLAGS =
< CFLAGS = -g -Wall -D__RCSID="static char *rcsid=" -D__COPYRIGHT="static char *copyright="
---
> XFLAGS = -D_GNU_SOURCE -D__RCSID="static char *rcsid=" -D__COPYRIGHT="static char *copyright="
> CFLAGS = -g -Wall
11c10
< $(CC) -o $(TARGET) $(XFLAGS) $(CFLAGS) args.o indent.o io.o lexi.o parse.o pr_comment.o $(LIBS)
---
> $(CC) -o $(TARGET) $(CFLAGS) args.o indent.o io.o lexi.o parse.o pr_comment.o $(LIBS)