From mboxrd@z Thu Jan 1 00:00:00 1970 From: "Martin v. Loewis" To: madhur_sharma@hotmail.com Cc: gnu@gnu.org, help-gcc@gnu.org Subject: Re: HELP : gcc compilation for TEMPLATE HANDLING Date: Tue, 14 Mar 2000 12:46:00 -0000 Message-id: <200003142040.VAA00899@loewis.home.cs.tu-berlin.de> References: <200003141921.OAA19609@delysid.gnu.org> X-SW-Source: 2000-03/msg00069.html > 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 From mboxrd@z Thu Jan 1 00:00:00 1970 From: "Martin v. Loewis" To: madhur_sharma@hotmail.com Cc: gnu@gnu.org, help-gcc@gnu.org Subject: Re: HELP : gcc compilation for TEMPLATE HANDLING Date: Sat, 01 Apr 2000 00:00:00 -0000 Message-ID: <200003142040.VAA00899@loewis.home.cs.tu-berlin.de> References: <200003141921.OAA19609@delysid.gnu.org> X-SW-Source: 2000-q1/msg00379.html Message-ID: <20000401000000.I8Leb-SCjDmCVWVNLrycNmOz4h6vT-JdvGg8qkq7jiM@z> > 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