ebfret / ebfret-gui

ebFRET (GUI version) – Empirical Bayes HMM analysis for multiple single-molecule FRET time series

Home Page:ebfret.github.io

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

forwback.cpp for ebfret-scripting not compiling on windows

michaeldarcy opened this issue · comments

Attempting to compile forwback.cpp on Windows yielded the following error:

>> mex forwback.cpp Building with 'MinGW64 Compiler (C++)'. Error using mex Z:\Darcy\Scripts and Code\ebfret-script-master\src\vbem\forwback.cpp: In function 'void mexFunction(int, mxArray**, int, const mxArray**)': Z:\Darcy\Scripts and Code\ebfret-script-master\src\vbem\forwback.cpp:118:67: error: cannot convert 'int*' to 'const mwSize* {aka const long long unsigned int*}' for argument '2' to 'mxArray* mxCreateNumericArray_730(mwSize, const mwSize*, mxClassID, mxComplexity)' plhs[1] = mxCreateNumericArray(3, xi_dims, mxDOUBLE_CLASS, mxREAL); ^
It seemed my compiler was working because I was able to compile Viterbi.cpp successfully.

The workaround I used was to rename "forwback_fallback.m" to "forwback.m" and the proxy/comment only file "forwback.m" to something else so that MATLAB will find the native forwback function when running eb_fret(), rather than trying to run the Mex/C++ version of the function. I was unable to run eb_fret() without error until I did this, presumably because it was attempting to use the empty "forwback.m" function.