From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 25664 invoked by alias); 9 Apr 2002 12:33:07 -0000 Mailing-List: contact gcc-help-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Archive: List-Post: List-Help: Sender: gcc-help-owner@gcc.gnu.org Received: (qmail 25628 invoked from network); 9 Apr 2002 12:33:03 -0000 Received: from unknown (HELO anchor-post-33.mail.demon.net) (194.217.242.91) by sources.redhat.com with SMTP; 9 Apr 2002 12:33:03 -0000 Received: from mailgate.softwire.co.uk ([62.49.203.138] helo=polarbear) by anchor-post-33.mail.demon.net with esmtp (Exim 3.35 #1) id 16uuo2-000E6V-0X; Tue, 09 Apr 2002 13:33:02 +0100 From: "Rupert Wood" To: Cc: Subject: RE: G++ Date: Tue, 09 Apr 2002 06:11:00 -0000 Message-ID: <616BE6A276E3714788D2AC35C40CD18D561641@whale.softwire.co.uk> MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit X-Priority: 3 (Normal) X-MSMail-Priority: Normal X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2600.0000 In-Reply-To: <616BE6A276E3714788D2AC35C40CD18D5B1B94@whale.softwire.co.uk> Importance: Normal X-SW-Source: 2002-04/txt/msg00084.txt.bz2 Gregor Karzelek wrote: > How can I say to g++ that he should print out the errors in a > file not in the stdout (=screen)? It outputs errors to stderr not stdout. stderr has file descriptor 2; you could use shell redirects, e.g.: g++ -c foo.cc -o foo.o 2>errorfile > If I want to compile a X.o from a X.cpp shall I use gcc or g++? > Both do it, but what shall i Rather use? The main differences between g++ and gcc are that g++ will compile .c files as if they were C++ and that g++ automatically includes libstdc++ when it is asked to link. You should use g++ for your link step. Rup.