Mathworks has an Apple Silicon beta for Matlab. They’ve mentioned also possible upcoming ARM64 support for other operating systems. For now, to test Matlab for Apple Silicon, I made this small patch to CMake’s factory FindMatlab.cmake.
Since we don’t know if these are the final naming schemes, or if September’s typical release schedule will bring official Apple Silicon support, I haven’t yet done a CMake MR.
I have general C, C++, Fortran Matlab MEX and Matlab Engine CMake examples at GitHub - scivision/matlab-cmake-mex: CMake and Matlab MEX producing accelerated Matlab code
707a710,711 > elseif(APPLE AND CMAKE_SYSTEM_PROCESSOR STREQUAL "arm64") > set(_matlab_mex_extension "mexmaca64") 1744c1748,1752 < set(_matlab_bin_suffix_64bits "i64") --- > if(CMAKE_SYSTEM_PROCESSOR STREQUAL "arm64") > set(_matlab_bin_suffix_64bits "a64") > else() > set(_matlab_bin_suffix_64bits "i64") > endif()