I am using SCons to install a package, but when I try to compile with mex, the matlab compiler, it runs other command from pdfTeX with same name. To solve this problem on bash, I've just changed .bashrc:
alias mex="/Applications/MATLAB_R2009b.app/bin/mex"
but I dont know how to change it on SCons environment. Someone knows how to do it?
Thanks.
I've managed to fix this problem. On SCons, the environment it sees is from the instance:
env = Environment(..., ENV = os.environ)
What I did was to add to os.environ the path of the matlab mex, by doing:
os.environ['PATH'] = matlabPath + '/bin:' + os.environ['PATH'];
Where matlabPath is the Matlab Path, e.g.:
/Applications/MATLAB_R2009b.app
That's it!
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With