Make ANSI and TERMINFO 0/1 rather than straight defines.
It always bugged me that I had to run Zedit to check the function
arrays. I moved that code to a standalone program that checks before
building Zedit so we know up front.

Removed the DBG define... really no longer needed since, except for
the functions test, all the other tests where cheap.
Add --config-dir.
Rename termcap to terminfo.
Checkpatch cleanups.