pmwebd: buildability fixes for illumos-based distros

Users have reported buildability problems with pmwebd on non-linux
platforms that lack <fts.h> and a few other facilities.  This patch
makes <fts.h> somewhat optional (though at the cost of crippling the
graphite interface), and adjusts a few other nits toward broader
portability.

Commit message & autoconf magic by: Frank Ch. Eigler <fche@redhat.com>
libpcp: ensure context flags are being set correctly

Fixes some fallout in several of the authentication tests, after
a bit of over-enthusiastic code cleanup prior to committing.
Merge branch 'illumos' of git://repo.or.cz/pcp/jeffpc into jeffpc-merge