[svlug] g++, templates and the STL
Chris Waters
xtifr at dsp.net
Wed Nov 18 02:13:44 PST 1998
Michael K Vance wrote:
> Specifically, I'm finding it impossible to use templates properly
> (getting weird /link/-time errors from g++).
If you're using 2.7.x, you *will* have problems. There is a list of
these problems in the FAQ. You didn't specify exactly what sort of
problems you were having. One thing to check is if your linker is at
least version 2.8; if it's not you have to manually instantiate the
templates somehow (which I don't know how to do).
> I also am finding the implementation of the STL a bit... well,
> incomplete and flaky (no "at" member function for vector?), but I'm not
> sure if it's just me...
Probably not just you. Especially if you're using 2.7.x, which had a
horribly limited version of the STL. But even egcs and 2.8.x have a few
missing template and STL features, I believe.
> I'm also interested in advice on getting egcs to co-exist easily with
> gcc, since it's C++ implementation is supposedly more robust.
It is very doable. Debian even splits them up, so the default C
compiler is gcc2.7.2 and the default C++ compiler is egcs. You may be
able to get an idea of what is required by looking at the build scripts
for the Debian packages. Mostly a whole lot of arguments to
./configure, I believe.
--
Chris Waters xtifr at dsp.net | I have a truly elegant proof of the
or cwaters at systems.DHL.COM | above, but it is too long to fit into
http://www.dsp.net/xtifr | this .signature file.
--
echo "unsubscribe svlug" | mail majordomo at svlug.org
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ to unsubscribe
see http://www.svlug.org/mdstuff/lists.shtml for posting guidelines.
More information about the svlug
mailing list