fixed Matlab compile on OS X and added instructions