From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 29713 invoked by alias); 10 Mar 2002 20:58:24 -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 29565 invoked from network); 10 Mar 2002 20:58:23 -0000 Received: from unknown (HELO smtp03.eresmas.com) (62.81.160.123) by sources.redhat.com with SMTP; 10 Mar 2002 20:58:23 -0000 Received: from K7 ([62.83.48.195]) by smtp03.eresmas.com (Netscape Messaging Server 4.15) with ESMTP id GSRZL301.HPC; Sun, 10 Mar 2002 21:58:15 +0100 To: Pete Barrie Cc: gcc-help@gcc.gnu.org Subject: Re: cygwin gcc 3.0.4 problem References: <5.1.0.14.0.20020310200531.021ebcd0@pophost.cs.strath.ac.uk> From: Oscar Fuentes Date: Sun, 10 Mar 2002 12:58:00 -0000 In-Reply-To: <5.1.0.14.0.20020310200531.021ebcd0@pophost.cs.strath.ac.uk> Message-ID: User-Agent: Gnus/5.09 (Gnus v5.9.0) Emacs/21.1 MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-SW-Source: 2002-03/txt/msg00081.txt.bz2 Pete Barrie writes: > Win2000 Cygwin 1.3.10-1 binutils 2.11.2 > > Hi. I've just built 3.0.4 native on Cygwin. Build seemed to > go fine and I can compile/run C prog hello.c > > However C++ hello.cpp fails as shown below. Is this something > trivial I am missing? > > Thanks for any help > > Pete > > $ cat hello.cpp > #include > > int main () > { > cout << "Hello World!"; > return 0; > } > > > > $ gcc -v hello.cpp Does it fail with $ g++ hello.cpp ??? g++ automatically links the libraries needed by the C++ library. GCC not. BTW, #include is not standard C++. Use #include -- Oscar