Effacer les filtres
Effacer les filtres

Unsolved external symbol in C++ interface build

2 vues (au cours des 30 derniers jours)
Hiroyuki Kobayashi
Hiroyuki Kobayashi le 29 Oct 2021
I have a C++ function which I can load on MATLAB with
loadlibrary('nc_driver_x64')
and this works without problem using calllib.
On the other hand, if I try to create interface of the same function like this
clibgen.generateLibraryDefinition(fullfile(workPath,'nc_driver_x64.h'),...
"IncludePath", workPath,...
"Libraries", {fullfile(workPath,'nc_driver_x64.lib'), fullfile(workPath,'nc_driver_x64.dll')},...
"Verbose",true)
It generates definenc_driver_x64.m and definenc_driver_x64.mlx, but then
build(definenc_driver_x64)
returns nc_driver_x64Interface.obj : error LNK2019: on all functions in this file.
.h, .lib and .dll files are all in the same folder and running on R2021b
I really appreciate if you could point out what I should check to make this work!

Réponses (0)

Tags

Produits


Version

R2021b

Community Treasure Hunt

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

Start Hunting!

Translated by