NetBSD's endian.h needs sys/types.h for the typedefs that are used to get htonl() correct when a long is 64 bits.