fix linking errors for mountain lion