fix mac 10.9; fix ubuntu GUI; fix mutex lock