Create and use external component
Posted: Mon Sep 23, 2024 6:00 pm
Hi, I'm trying to use the following component: "https://github.com/bitfixer/esp32s3vga/tree/main". I created the folder for components and made the necessary changes in the CMakeLists.txt to add it. The problem occurs when I try to build it: if I keep the main.c file as a C file, the compiler treats VGA.h as a C file as well and doesn't recognize the type name 'class'. However, if I change main.c to main.cpp, the compiler recognizes 'class' but then I get the error "undefined reference to 'app_main'".
I’m not sure why it won't let me compile in C++, even after changing the CMakeLists.txt to reference main.cpp. If anyone knows how to work with C++ files in this context, could you help me out?
I’m not sure why it won't let me compile in C++, even after changing the CMakeLists.txt to reference main.cpp. If anyone knows how to work with C++ files in this context, could you help me out?