Does anybody try to compile mex executable using Diolan C API? I've tried to include dln_generic.h and dln_gpio.h to wrapper cpp file for mex compile, and every related header files and .lib are stored in the directory which compile command shall be execured, however it complains the linking "undefined reference to function_name". Here is my environemnt. I tried with -R2017b and -R2018a but result were same.
matlab version: R2020a
compiler: MinGW64 Compiler (C++)
command: "mex name_of_the_wrapper.cpp dln.lib user32.lib ws2_32.lib -g -v"
header file declarations:
#pragma once
#pragma comment(lib, "libmx.lib")
#pragma comment(lib, "libmat.lib")
#pragma comment(lib, "libmex.lib")
#pragma comment(lib, "dln.lib")
#include "dln_generic.h"
#include "dln_gpio.h"
#include "mex.h"
struct mxArray_tag {};
void mexFunction(int nlhs, mxArray *plhs[], int nrhs, const mxArray *prhs[]);