On Fri, Nov 16, 2001 at 15:59:04 +0200, Shaul Karl wrote:
> [15:50:23 tmp]$ g++-3.0 -Wall -ggdb -o main main.cc
> main.cc:1:20: hash_map: No such file or directory
> [15:50:27 tmp]$ wc /usr/include/g++-3/hash_map

Add a '-v' to your command line, and you'll see that that directory isn't
searched:
        #include <...> search starts here:
         /usr/include/g++-v3/ext
         /usr/include/g++-v3
         /usr/include/g++-v3/i386-linux
         /usr/include/g++-v3/backward
         /usr/local/include
         /usr/lib/gcc-lib/i386-linux/3.0.2/include
         /usr/include
and that's the correct behaviour: "dpkg -S /usr/include/g++-3/hash_map"
shows that that "hash_map" is part of the "libstdc++2.10-dev" package which
is for use with g++ 2.95, not with g++ 3.

> Is this reproducible by others? The distro is testing.

I get the same behaviour with unstable.

There is a /usr/include/g++-v3/ext/hash_map that's part of "libstdc++3-dev"
which is for use with g++ 3, but that file says
        /* NOTE: This is an internal header file, included by other STL headers.
         *   You should not attempt to use it directly.
         */

> It does compile cleanly when replacing <hash_map> with <map> or with
> <hash_map.h>.

It may be that that is the proper way to do it; I'm not familiar enough with
STL to know. Perhaps someone on debian-gcc can comment on this?

Ray
-- 
We do not worry about Microsoft developing Open Source applications. Their
revenue stream is based on a heroin addiction of selling ever more software.
        Red Hat's Bob Young quoted in
        http://www.theregister.co.uk/content/1/11321.html


Reply via email to