Clear Filters
Clear Filters

Error while generating C code

30 views (last 30 days)
Ananda Krishnan
Ananda Krishnan on 17 May 2021
Answered: Tasneem on 13 Jul 2022
### Starting build procedure for: mod
### Generating code and artifacts to 'Model specific' folder structure
### Generating code into build folder: D:\mod_ert_rtw
### Invoking Target Language Compiler on mod.rtw
### Using System Target File: E:\SOFTWARE\INSTALLED FILES\MAT2020\Program Files\Polyspace\R2020a\rtw\c\ert\ert.tlc
### Loading TLC function libraries
### Generating TLC interface API for custom data .
### Initial pass through model to cache user defined code
### Caching model source code
### Writing header file mod_types.h
### Writing header file mod.h
### Writing header file rtwtypes.h
### Writing source file mod.c .
### Writing header file mod_private.h
### Writing source file ert_main.c
### TLC code generation complete.
### Creating HTML report file mod_codegen_rpt.html### Using toolchain: LCC-win64 v2.4.1 | gmake (64-bit Windows) ### Build procedure for mod aborted due to an error.
Build process stopped because two files have the same filename in the list of source files: "ert_main.c mod.c ert_main.c"
Encountered the above described error during build process please kindly share any solutions if possible.
  1 Comment
Yi Wang
Yi Wang on 13 Jul 2022
您好,楼主,有解决方法了吗?

Sign in to comment.

Answers (1)

Tasneem
Tasneem on 13 Jul 2022
It is my understanding that you are getting an error in the build process. If you look at the error message, it says that there are two files in the source files list, having same file name "ert_main.c mod.c ert_main.c". Please rename one of the file in the list and try to build it again.

Categories

Find more on Simulink Coder in Help Center and File Exchange

Products

Community Treasure Hunt

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

Start Hunting!