Ask mex to use several directories for #include files

I read in the documentation for MATLAB mex here the following:

-Ipathname : add the path to the list of folders to search for #include files. Do not add a space after this switch.

How can I ask mex to use several included folders? Do I provide them as -Ipath1 -Ipath2 etc.

+7
source share
1 answer

Yes; eg:

mex -Iinclude/path/one -Iinclude/path/two -I"include/path/with spaces" mymexfile.c 
+10
source

All Articles