replace BSD flock check with compile time test