add unixd.h include and remove some warnings