From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 20956 invoked by alias); 23 May 2002 23:26:03 -0000 Mailing-List: contact gcc-prs-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Archive: List-Post: List-Help: Sender: gcc-prs-owner@gcc.gnu.org Received: (qmail 20932 invoked by uid 71); 23 May 2002 23:26:02 -0000 Resent-Date: 23 May 2002 23:26:02 -0000 Resent-Message-ID: <20020523232602.20931.qmail@sources.redhat.com> Resent-From: gcc-gnats@gcc.gnu.org (GNATS Filer) Resent-To: nobody@gcc.gnu.org Resent-Cc: gcc-prs@gcc.gnu.org, gcc-bugs@gcc.gnu.org Resent-Reply-To: gcc-gnats@gcc.gnu.org, sandic@xtra.co.nz Received:(qmail 18613 invoked by uid 61); 23 May 2002 23:18:17 -0000 Message-Id:<20020523231817.18612.qmail@sources.redhat.com> Date: Thu, 23 May 2002 16:26:00 -0000 From: sandic@xtra.co.nz Reply-To: sandic@xtra.co.nz To: gcc-gnats@gcc.gnu.org X-Send-Pr-Version:gnatsweb-2.9.3 (1.1.1.1.2.31) Subject: c++/6789: Error including 'fstream' on Solaris 2.6 X-SW-Source: 2002-05/txt/msg00752.txt.bz2 List-Id: >Number: 6789 >Category: c++ >Synopsis: Error including 'fstream' on Solaris 2.6 >Confidential: no >Severity: serious >Priority: medium >Responsible: unassigned >State: open >Class: rejects-legal >Submitter-Id: net >Arrival-Date: Thu May 23 16:26:01 PDT 2002 >Closed-Date: >Last-Modified: >Originator: sandic@xtra.co.nz >Release: unknown-1.0 >Organization: >Environment: sparc-sun-solaris2.6 SunOS hutt 5.6 Generic_105181-30 sun4u sparc SUNW,Ultra-Enterprise >Description: When the program includes the /include/g++-v3/bits/basic_file.h is included before the /include/g++-v3/sparc-sun-solaris2.6/bits/basic_file.h, causing the compiler to not to recognise the typedef __c_file. The order of include search seems to be wrong. The text below shows the full output from a simple compile session. ------------------------------------------------- n179339:programs$ g++ -v -c hello_world.cpp Reading specs from /home/ap_share/lib/gcc-lib/sparc-sun-solaris2.6/3.1/specs Configured with: ../gcc-3.1/configure --prefix=/home/ap_share --enable-languages=c,c++,java --with-gnu-ld --with-ld=/home/ap_share/bin/gnu-ld --with-gnu-as --with-as=/home/ap_share/bin/gnu-as Thread model: posix gcc version 3.1 /home/ap_share/lib/gcc-lib/sparc-sun-solaris2.6/3.1/cc1plus -v -D__GNUC__=3 -D__GNUC_MINOR__=1 -D__GNUC_PATCHLEVEL__=0 -Dsparc -Dsun -Dunix -D__svr4__ -D__SVR4 -D__PRAGMA_REDEFINE_EXTNAME -D__sparc__ -D__sun__ -D__unix__ -D__svr4__ -D__SVR4 -D__PRAGMA_REDEFINE_EXTNAME -D__sparc -D__sun -D__unix -Asystem=unix -Asystem=svr4 -D__NO_INLINE__ -D__STDC_HOSTED__=1 -D_XOPEN_SOURCE=500 -D_LARGEFILE_SOURCE=1 -D_LARGEFILE64_SOURCE=1 -D__EXTENSIONS__ -D__GCC_NEW_VARARGS__ -Acpu=sparc -Amachine=sparc hello_world.cpp -D__GNUG__=3 -D__DEPRECATED -D__EXCEPTIONS -D__GXX_ABI_VERSION=100 -quiet -dumpbase hello_world.cpp -version -o /var/tmp//ccdEbzWL.s GNU CPP version 3.1 (cpplib) (sparc ELF) GNU C++ version 3.1 (sparc-sun-solaris2.6) compiled by GNU C version 3.1. #include "..." search starts here: #include <...> search starts here: /home/ap_share/include/g++-v3 /home/ap_share/include/g++-v3/sparc-sun-solaris2.6 /home/ap_share/include/g++-v3/backward /usr/local/include /home/ap_share/include /home/ap_share/lib/gcc-lib/sparc-sun-solaris2.6/3.1/include /home/ap_share/sparc-sun-solaris2.6/include /usr/include End of search list. /home/ap_share/bin/gnu-as --traditional-format -V -Qy -s -o hello_world.o /var/tmp//ccdEbzWL.s GNU assembler version 2.12 (sparc-sun-solaris2.6) using BFD version 2.12 >How-To-Repeat: Just say: #include at the top of your source, and try compiling. >Fix: Temporary fix: Renamed the /include/g++-v3/bits/basic_file.h to something else (or remove it completely) and the one from the platform include directory will be picked up. >Release-Note: >Audit-Trail: >Unformatted: