fix netmap compile errors on BSD