Hi I am getting the following error: Mex file entry point is missing. Please check the (case-sensitive) spelling of mexFunction (for C MEX-files), or the (case-insensitive) spelling of MEXFUNCTION (for FORTRAN MEX-files). What should I do? Thanks

Mex file entry point is missing. Please check the (case-sensitive) spelling of mexFunction (for C MEX-files), or the (case-insensitive) spelling of MEXFUNCTION (for FORTRAN MEX-files).

2 Comments

Joshua - please describe what you are doing when this error is generated. What code are you calling? Is it something that you have written in MATLAB, C, or Fortran?
Hi Geoff
I am trying to run a Simulink model (.slx file).
And that is the error that I am getting.
Thanks
Joshua

Sign in to comment.

Answers (1)

You need to have this code in your Fortran file which will serve as the entry point for the mex function:
#include "fintrf.h"
subroutine mexFunction(nlhs, plhs, nrhs, prhs)
implicit none ! <-- Not required but highly recommended
integer nlhs, nrhs
mwPointer plhs(*), prhs(*)
!\
! Your code goes here
!/
end subroutine

Categories

Asked:

on 28 Nov 2015

Commented:

on 30 Nov 2015

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!