Clear Filters
Clear Filters

'No such file or directory' when trying to generate .dll file

18 views (last 30 days)
I am trying to generate a c/c++ dynamic library file from some image processing code to use in visual studio. However when I run the coder and verify the code, I get an error saying it cannot open include file 'stddef.h' I did a search on my C: drive and found three versions of it in the following locations:
  1. C:\Program Files (x86)\Windows Kits\10\Include\10.0.10150.0\ucrt
  2. C:\Program Files (x86)\Windows Kits\10\Include\10.0.10240.0\ucrt
  3. C:\Program Files (x86)\Windows Kits\10\Include\10.0.10586.0\km\crt
At first I tried adding only one of the locations to the search path and when that didn't work I added the three paths to the MATLAB search path but the error is still there.
The build log is shown below
2 Microsoft (R) Program Maintenance Utility Version 14.00.23506.0
3 Copyright (C) Microsoft Corporation. All rights reserved.
5 cl /TP -c -DCRTAPI1=_cdecl -DCRTAPI2=_cdecl -nologo -GS -D_AMD64_=1 -DWIN64 -D_WIN64 -DWIN32 -D_WIN32 -W4 -D_WINNT -D_WIN32_WINNT=0x0502 -DNTDDI_VERSION=0x05020000 -D_WIN32_IE=0x0600 -DWINVER=0x0502 -D_MT -MT -EHs -D_CRT_SECURE_NO_WARNINGS /Od /Oy- -DMODEL=line_detectf -DHAVESTDIO -DUSE_RTMODEL -Fo"line_detectf_rtwutil.obj" "C:\Users\Sam\Documents\MATLAB\codegen\dll\line_detectf\line_detectf_rtwutil.cpp"
6 line_detectf_rtwutil.cpp
7 c:\users\sam\documents\matlab\codegen\dll\line_detectf\rt_nonfinite.h(18): fatal error C1083: Cannot open include file: 'stddef.h': No such file or directory
8 NMAKE : fatal error U1077: '"C:\Program Files (x86)\Microsoft Visual Studio 14.0\VC\BIN\amd64\cl.EXE"' : return code '0x2'
9 Stop.
10 The make command returned an error of 2
11 'An_error_occurred_during_the_call_to_make' is not recognized as an internal or external command,
12 operable program or batch file.
14 Error(s) encountered while building "line_detectf":
15 ### Failed to generate all binary outputs.

Answers (1)

Co Melissant
Co Melissant on 18 Apr 2016


Find more on Introduction to Installation and Licensing in Help Center and File Exchange


Community Treasure Hunt

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

Start Hunting!