Subject: Re: Standard Template Library
From: [email-masked] (Mumit Khan)

1 Jul 1997 23:42:05 -0700
Approved: [email-masked]
Distribution: cygnus
Message-ID: <[email-masked]>
Original-To: Cheung Kwok Hung <[email-masked]>, [email-masked]
In-Reply-To: Your message of "Wed, 02 Jul 1997 02:41:25 +0800."
             <[email-masked]> 
Original-Sender: [email-masked]

Cheung Kwok Hung <[email-masked]> writes:
> Hi,
> 
> Is there anybody try to use the gcc for Win32 with STL? I encounter a lot
> of multiple definition errors during linking phase if I use STL container
> in more than one source files. When I trace into the system header files.
> I find that there is a header file "alloc.h" in /usr/include/g++ which
> declare some static variables, which originate multiple declaration. I
> also find that the STL headers provided in beta 18 is different from that
> I got in "normal" gcc v.2.7.2. What is the problem?
> 

I use quite a bit of STL in my code, and some of it works under gnu-win32
(unfortunately, g++ can't grok most of the most the recent code I've 
written, so I have to stick to EDG based compilers).

It'll be helpful to know what options you use. I tend to instantiate 
explicitly using instantiation files, and supply -fno-implicit-templates 
for everything (except for the instantiation files). See my STL Newbie
guide (horribly outdated, but still has some useful info IMO) for more
info on using STL with g++. URL after sig.

regards,
Mumit -- [email-masked]
http://www.xraylith.wisc.edu/~khan/
http://www.xraylith.wisc.edu/~khan/software/stl/STL.newbie.html

Cc: gnu-win32 mailing list, Cheung Kwok Hung <[email-masked]>
-
For help on using this list (especially unsubscribing), send a message to
"[email-masked]" with one line of text: "help".