|
How can i include global variables in multifile project. The method which i have adopted is: 1) declare global variables and global define directive in the header file "def.h"(including ifdef directive too.) 2) Add this header file in the different files of my project by #include directive Problem: CCS v2.10 gives the compilation error of "multiple variables declaration" Then i have adopted the following method: 1) declare global variables and global define directive in the header file "def.h"(including ifdef directive too.) 2)Made another header file"def_extern.h" in which redeclare all global variables with the "extern" directive. 3)add "def.h" in the main file with the "#include" directive 4) add "def_extern.h" in the other files with the "#include" directive recompiled the project.This time i donot get the compilation error but the linking error "unable to add in .text ". Can anyone help me in this regard. I am using CCS v2.1 and curently using it in the tms320c6711 IDK Thanks |