This is the mail archive of the gcc-help@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

Re: HELP : gcc compilation for TEMPLATE HANDLING


> was using the gcc compiler for compiling my programs which use
> internal templates . with the default option -fno-external-templates
> . while linking the programs i got a lot of symbol refersncing
> errors and they were for the templates only .

> i cud not understand how to fix this problem using #pragma interface in my 
> header files which use templates.
> 	please cud u help me on this issue.

I'm not sure I can help; you did not say what processor and operating
system you are using gcc on. On Linux and other ELF-based systems, I
recommend to forget about -fno-external-templates, and trust the
instantiation mechanism provided by the compiler. At latest, the
linker will remove duplicate instantiations should they happen.

Regards,
Martin


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]