fixed error with Darwin detection