diff --git a/README.md b/README.md
index 4c59c93c003eaf8b8e054aada2cf6c15093ba697..d77a436f7fb8cd998af2b376fdc02650d21173ab 100644
--- a/README.md
+++ b/README.md
@@ -45,8 +45,8 @@ determine the type of your MATLAB/Octave installation, type:
 ```matlab
 >> computer
 ```
-at the MATLAB/Octave prompt. Under MATLAB, if it returns `PCWIN64`, `GLNX64` or
-`MACI64`, then it is a 64-bit MATLAB; if it returns `PCWIN`, `MACI` or `GLNX`,
+at the MATLAB/Octave prompt. Under MATLAB, if it returns `PCWIN64`, `GLNX64`,
+`MACI64` or `MACA64` then it is a 64-bit MATLAB; if it returns `PCWIN`, `MACI` or `GLNX`,
 then it is a 32-bit MATLAB. Under Octave, if it returns a string that begins
 with `x86_64`, it is a 64-bit Octave; if the strings begins with `i686`, it is
 a 32-bit Octave.
diff --git a/doc/manual/source/running-dynare.rst b/doc/manual/source/running-dynare.rst
index abef1d1a1be7764644e3df30c53e281ed90557e1..7a0987cca359f95ba8e92aad1cb771f92a2e8fab 100644
--- a/doc/manual/source/running-dynare.rst
+++ b/doc/manual/source/running-dynare.rst
@@ -315,7 +315,7 @@ by the ``dynare`` command.
         Prevent Dynare from printing the output of the steps leading up to the
         preprocessor as well as the preprocessor output itself.
 
-    .. option:: mexext=mex|mexw32|mexw64|mexmaci64|mexa64
+    .. option:: mexext=mex|mexw32|mexw64|mexmaci64|mexmaca64|mexa64
 
         The mex extension associated with your platform to be used
         when compiling output associated with :opt:`use_dll`.
diff --git a/m4/ax_matlab_arch.m4 b/m4/ax_matlab_arch.m4
index e37bd522880f92389ece091e1fc718137f6c7c82..3def1809a8a6d9a08ab9646e0f3138ed3aa4885c 100644
--- a/m4/ax_matlab_arch.m4
+++ b/m4/ax_matlab_arch.m4
@@ -1,7 +1,7 @@
 dnl matlabarch.m4 --- check for MATLAB machine architecture.
 dnl
 dnl Copyright © 2002, 2003 Ralph Schleicher
-dnl Copyright © 2009 Dynare Team
+dnl Copyright © 2009-2023 Dynare Team
 dnl
 dnl This program is free software; you can redistribute it and/or
 dnl modify it under the terms of the GNU General Public License as
@@ -57,6 +57,9 @@ else
       *mexmaci64)
 	ax_cv_matlab_arch=maci64
 	;;
+      *mexmaca64)
+	ax_cv_matlab_arch=maca64
+	;;
       *)
 	ax_cv_matlab_arch=unknown
 	;;
diff --git a/m4/ax_mexopts.m4 b/m4/ax_mexopts.m4
index 644ffa0141539e7eed90e95b182af876ed26ff5b..1a5ef951255a622dd09f9a06150389174837fc0f 100644
--- a/m4/ax_mexopts.m4
+++ b/m4/ax_mexopts.m4
@@ -68,7 +68,7 @@ case ${MATLAB_ARCH} in
     FORTRAN_LIBS_FOR_CXXLINK="-Wl,-Bstatic -lgfortran -Wl,-Bdynamic" # libquadmath is already in MATLAB_LDFLAGS_NOMAP
     ax_mexopts_ok="yes"
     ;;
-  maci64)
+  mac[[ai]]64)
     MATLAB_DEFS="-DNDEBUG"
     MATLAB_CFLAGS="-fno-common -fexceptions"
     MATLAB_CXXFLAGS="-fno-common -fexceptions"
@@ -78,7 +78,7 @@ case ${MATLAB_ARCH} in
     # This -L flag is put here, hence later on the linker command line, so as
     # to avoid linking against the HDF5 shipped by MATLAB (which would
     # otherwise override the HDF5 from Homebrew)
-    MATLAB_LIBS="-L$MATLAB/bin/maci64 -lmx -lmex -lmat -lmwlapack -lmwblas"
+    MATLAB_LIBS="-L$MATLAB/bin/${MATLAB_ARCH} -lmx -lmex -lmat -lmwlapack -lmwblas"
     FORTRAN_LIBS_FOR_CXXLINK="-lgfortran -lquadmath"
     ax_mexopts_ok="yes"
     ;;
diff --git a/matlab/add_path_to_mex_files.m b/matlab/add_path_to_mex_files.m
index 2a352d82fcd7389869628550c97147718e011111..97548b1ea942e7e9f46f8128d3f0cec1f6010849 100644
--- a/matlab/add_path_to_mex_files.m
+++ b/matlab/add_path_to_mex_files.m
@@ -89,6 +89,15 @@ else
             end
         end
     end
+    if strcmp(computer, 'MACA64')
+        tmp = [dynareroot '../mex/matlab/maca64-9.14/'];
+        if exist(tmp, 'dir')
+            mexpath = tmp;
+            if modifypath
+                addpath(mexpath);
+            end
+        end
+    end
     % Add generic MATLAB path (with higher priority than the previous ones)
     if exist('mexpath')
         mexpath = { mexpath; [dynareroot '../mex/matlab/'] };