Renamed config.m4 and related files to sqlvars.m4 which is more descriptive of its function.
For consistency, allow project database vars to be defined in config.sh. We can still use PREFIX_ vars, but they will work as overrides only.
Better error reporting of problems with PREFIXDIR var, the only one that is still required to be declared in the environment prior to execution.
New -su and -d options to db_filter abstract the way database superuser usage and default schema usage are specified; we were using psql parameters, of course.
Some trivial modification.
Small code simplification around CONF variables, so we don't have to remember whether to use indirect expansion or not.
Aesthetic touches.
Check validity of CONF_DIR before sourcing config-script.sh, otherwise the check procedure's purpose is defeated.
When generating the intermediate sql file, use a better tmp filename.
General fix of use of quotes around variables.
Ignore emacs autosave files.
Removed 02-pgcrypto.sql since it's postgres-specific and put the code in 01-database.sql.
Renamed DB global to arg_DB since the name was too simple.
Other aesthetic changes.
Debugging: ${!{$PREFIX}SUFFIX} doesn't work, too much abuse on the syntax. Defining "prefix" function to perform this operation. The project location var (CHARPDIR by default) will have to be named CHARP_DIR now, for consistency.
Also, moved postgres-specific sqlvars m4 macros to its own file in pg and added code to include it during m4 processing.