Why do I get an error similar to "undefined reference to <filename> file" when compiling MATLAB generated code with GCC?
7 Ansichten (letzte 30 Tage)
Ältere Kommentare anzeigen
MathWorks Support Team
am 9 Sep. 2019
Beantwortet: MathWorks Support Team
am 27 Jan. 2020
I am using MATLAB Coder to generate C code. I want to compile this code externally, specifically using GCC and compiling the generated main.c file. but I get errors similar to "undefined reference to <filename> file".
What is the cause and how do I fix this?
Akzeptierte Antwort
MathWorks Support Team
am 9 Sep. 2019
This error arises because the GCC compilation command is incomplete. You need to specify all the C files that are used in the application at the command line when using GCC.
This will resolve issues with undefined references.
0 Kommentare
Weitere Antworten (0)
Siehe auch
Kategorien
Mehr zu MATLAB Support for MinGW-w64 C/C++ Compiler finden Sie in Help Center und File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!