make this build with gcc 14 on netbsd.
it was only including unistd.h if "unix" was defined, but netbsd and
several others only define __unix__ these days.
bumped pkg version because this may fix some weird stuff because it
didn't include headers and got default int etc.
make sure prototypes are present.
pgp_getopt() is always the name used, so make it's prototype always there.
also include <sys/ioctl.h> on netbsd to get ioctl() prototype.
fixes GCC 14 build.
fix some issues with the netbsd port to make GCC 14 happier.
- include <util.h> and <sys/wait.h> for openpty() and ioctl().
- set MAINTYPE=int for netbsd targets.
fix a wctype(3) usage problem found while looking at GCC 14 issues.
this doesn't fix the build for GCC 14, but does remove a warning about
calling iswctype() with swapped arguments.