Fixed compile errors on Mac
+x flag for executables
Added mac build scripts