compilation terminated. gmake: *** [xil_interface_lib.obj] Error 1 . need answer

6 次查看(过去 30 天)
### Preparing to start SIL block simulation: P2WarningDeckStructure/P2WarningDeckStructure/P2WarningDeckStructure ... ### Using toolchain: MinGW64 | gmake (64-bit Windows) ### 'D:\sambit\H61L\Step8#2_Testing\Workingfolder\P2WarningDeckStructure\P2WarningDeckStructure0_ert_rtw\sil\P2WarningDeckStructure0.mk' is up to date ### Building 'P2WarningDeckStructure0': "C:\PROGRA~1\MATLAB\R2018b\bin\win64\gmake" -f P2WarningDeckStructure0.mk all D:\sambit\H61L\Step8#2_Testing\Workingfolder\P2WarningDeckStructure\P2WarningDeckStructure0_ert_rtw\sil>cd . D:\sambit\H61L\Step8#2_Testing\Workingfolder\P2WarningDeckStructure\P2WarningDeckStructure0_ert_rtw\sil>if "" == "" ("C:\PROGRA~1\MATLAB\R2018b\bin\win64\gmake" -f P2WarningDeckStructure0.mk all ) else ("C:\PROGRA~1\MATLAB\R2018b\bin\win64\gmake" -f P2WarningDeckStructure0.mk ) "C:\PROGRA~3\MATLAB\SUPPOR~1\R2018b\3P778C~1.INS\MINGW_~1.INS\bin/gcc" -c -std=c99 -pedantic -fwrapv -m64 -O0 -DCLASSIC_INTERFACE=0 -DALLOCATIONFCN=0 -DTERMFCN=1 -DONESTEPFCN=1 -DMAT_FILE=0 -DMULTI_INSTANCE_CODE=0 -DINTEGER_CODE=0 -DMT=0 -DTID01EQ=0 -DXIL_SIGNAL_HANDLER=1 -DCODER_ASSUMPTIONS_ENABLED=1 -DRTIOSTREAM_RX_BUFFER_BYTE_SIZE=50000 -DRTIOSTREAM_TX_BUFFER_BYTE_SIZE=50000 -DMEM_UNIT_BYTES=1 -DMemUnit_T=uint8_T -DMODEL=P2WarningDeckStructure0 -DNUMST=1 -DNCSTATES=0 -DHAVESTDIO -DMODEL_HAS_DYNAMICALLY_LOADED_SFCNS=0 -ID:/sambit/H61L/Step8#2_Testing/Workingfolder/P2WarningDeckStructure -ID:/sambit/H61L/Step8#2_Testing/Workingfolder/P2WarningDeckStructure/P2WarningDeckStructure0_ert_rtw -IC:/PROGRA~1/MATLAB/R2018b/extern/include -IC:/PROGRA~1/MATLAB/R2018b/simulink/include -IC:/PROGRA~1/MATLAB/R2018b/rtw/c/src -IC:/PROGRA~1/MATLAB/R2018b/rtw/c/src/ext_mode/common -IC:/PROGRA~1/MATLAB/R2018b/rtw/c/ert -IC:/PROGRA~1/MATLAB/R2018b/toolbox/rtw/targets/pil/c -ID:/sambit/H61L/STEP8 @P2WarningDeckStructure0_comp.rsp -o "xil_interface_lib.obj" "C:/PROGRA~1/MATLAB/R2018b/toolbox/rtw/targets/pil/c/xil_interface_lib.c" C:/PROGRA~1/MATLAB/R2018b/toolbox/rtw/targets/pil/c/xil_interface_lib.c:16:37: fatal error: XILTgtAppSvc_CInterface.h: No such file or directory #include "XILTgtAppSvc_CInterface.h" ^ compilation terminated. gmake: *** [xil_interface_lib.obj] Error 1 D:\sambit\H61L\Step8#2_Testing\Workingfolder\P2WarningDeckStructure\P2WarningDeckStructure0_ert_rtw\sil>echo The make command returned an error of 2 The make command returned an error of 2 D:\sambit\H61L\Step8#2_Testing\Workingfolder\P2WarningDeckStructure\P2WarningDeckStructure0_ert_rtw\sil>An_error_occurred_during_the_call_to_make 'An_error_occurred_during_the_call_to_make' is not recognized as an internal or external command, operable program or batch file.
An error occurred while calling into the SIL or PIL target connectivity implementation.
Caused by:
  • Error(s) encountered while building "P2WarningDeckStructure0": ### Failed to generate all binary outputs.
Component:Simulink | Category:Model error
  1 个评论
Nishanthraag
Nishanthraag 2024-2-27
Was this issue ever resolved? If yes how? I am having the same issue running SIL. My SIL fails here. I am using MinGw.

请先登录,再进行评论。

回答(1 个)

Satwik
Satwik 2024-9-18
Hi Sambit,
The error message you are facing suggests that the header file ‘XILTgtAppSvc_CInterface.h’ is missing, leading to a compilation failure. This issue can arise due to missing files, incorrect paths, or configuration problems. Here are some steps to help troubleshoot and resolve the issue:
1. Verify the Existence of the Header File:
Check if ‘XILTgtAppSvc_CInterface.h’ is present in your MATLAB installation directory. This file should be included as part of the PIL or SIL support files. If it is missing and meant to be a custom header file, ensure that it has been correctly created and saved in the appropriate directory.
2. Check Include Paths:
Ensure the directory containing ‘XILTgtAppSvc_CInterface.h’ is included in the include path during compilation. The ‘addpath’ command can be used to add specific folders to the search path of the current MATLAB session.
addpath(folderName1,...,folderNameN);
3. Update MATLAB Path:
Use the ‘restoredefaultpath’ command in MATLAB to reset the path to its default state, followed by ‘rehash toolboxcache’ to refresh the toolbox cache. This can help resolve path-related issues.
restoredefaultpath;
rehash toolboxcache;
savepath;
Hope this helps!

Community Treasure Hunt

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

Start Hunting!

Translated by