use 0 instead of NULL for null pointer constants and thereby remove otherwise-unnecessary inclusion of stddef.h
include cleanups: remove unused headers and add feature test macros
initial check-in, version 0.5.0