Solved compilation problems in macosx