* various fixed for correct compilation on BSD