Hi guys,
I try to compile a program with a main.c, file.c and file.h files
The file.c and file.h are in another directory than the main.c
I included the file.h in both main.c and file.c
When I compile the program I get the the undefined reference error of myName(); that is declared in file.h and defined in file.c
I followed the suggestion in VS Code documentation to edit the tasks.json but it didn't work. I tried both the .cpp and c extension in the tasks.json. Now the file is like this:
If I build the files from the terminal gcc main.c Library/file.c it works fine
I do not know what else I am missing. Any suggestion?