[CMake] getting undefined error to my own libs.

eial at cs.bgu.ac.il eial at cs.bgu.ac.il
Tue Dec 29 10:31:53 EST 2009


On Tue 29 Dec 17:16 2009 Eric Noulard wrote:
> 2009/12/29 eial at cs.bgu.ac.il <eial at cs.bgu.ac.il>:
> > hello Eric, thanks for the response.
> > I'd like to solve the Array issue first, then the boost because I have a feeling it is a different one because when I disable the relevant code it doesn't generates the error even when other parts of the program (such as the threadpool).
> > here are the array files content: http://codepad.org/klDWMowB
> 
> I assume the content of the .hpp is between #ifndef CARRAY_HPP
> then the code is the .cpp file.
> 
yes, your right.
> The trouble comes from the fact that your class is a template one,
> so that the content of the .cpp file may not be compiled independently
> "as-is" because it must be instantiated first.
> 
> I invite you to read this:
> http://www.parashift.com/c++-faq-lite/templates.html#faq-35.12
> and may be this one too:
> http://corfield.org/index.cfm/event/cplusplus.section/section/ptexp
> 
> Note that the "export keyword" solution may not be a good one
> because many compilers do not implement it, beginning with gcc:
> http://gcc.gnu.org/bugs/#nonbugs_cxx
> 
> > beside a strange typo that I've done, I don't thing I've miss configured it somehow.
> 
> I think may be you did not played a lot with templated classes.
> (just a guess I may be wrong).
> 
I have some but if you say that I'm doing it wrong, then there is a good chance I am.
> Concerning this issue, I'm pretty sure this is not a CMake one.
I've posted it here because what I had before have compiled well without any problems and uncommenting that part generated the error.
will take
> 
> -- 
> Erk
> Membre de l'April - « promouvoir et défendre le logiciel libre » -
> http://www.april.org
> 






More information about the CMake mailing list