| delorie.com/archives/browse.cgi | search |
| X-Recipient: | archive-cygwin AT delorie DOT com |
| X-SWARE-Spam-Status: | No, hits=-1.1 required=5.0 tests=AWL,BAYES_00,DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,FREEMAIL_FROM,RCVD_IN_DNSWL_NONE |
| X-Spam-Check-By: | sourceware.org |
| Message-ID: | <429418.12106.qm@web25508.mail.ukl.yahoo.com> |
| Date: | Thu, 16 Sep 2010 21:59:40 +0000 (GMT) |
| From: | Marco Atzeri <marco_atzeri AT yahoo DOT it> |
| Subject: | Re: Compiling with G++ and segment fault on vector declaration |
| To: | John Yoon <seatpost AT gmail DOT com> |
| Cc: | cygwin AT cygwin DOT com |
| In-Reply-To: | <AANLkTimKikGmzE57JgwTuzCLR6R_QxfXpQwC38fqYMbb@mail.gmail.com> |
| MIME-Version: | 1.0 |
| X-IsSubscribed: | yes |
| Mailing-List: | contact cygwin-help AT cygwin DOT com; run by ezmlm |
| List-Id: | <cygwin.cygwin.com> |
| List-Unsubscribe: | <mailto:cygwin-unsubscribe-archive-cygwin=delorie DOT com AT cygwin DOT com> |
| List-Subscribe: | <mailto:cygwin-subscribe AT cygwin DOT com> |
| List-Archive: | <http://sourceware.org/ml/cygwin/> |
| List-Post: | <mailto:cygwin AT cygwin DOT com> |
| List-Help: | <mailto:cygwin-help AT cygwin DOT com>, <http://sourceware.org/ml/#faqs> |
| Sender: | cygwin-owner AT cygwin DOT com |
| Mail-Followup-To: | cygwin AT cygwin DOT com |
| Delivered-To: | mailing list cygwin AT cygwin DOT com |
--- Gio 16/9/10, John Yoon <xxxxxxxxxxxx> ha scritto:
> Thanks Marco. It worked!
> I don't know how you got g++ version 4.3.4
> Because the only version I see available is 3.4.4
>=20
> I would like to understand the cause of this.
> Does gcc work differently in cygwin?
> How come I don't need to specify the header file?
>=20
> Thank you
>=20
> John
first: don't top post
>=20
> On Thu, Sep 16, 2010 at 1:28 PM, Marco Atzeri <xxxxxxxxxxxx>
^^^^^^^^^^^^=20
second: don't feed spammers
third: install gcc4 compiler
On any system, not only on cygwin, you don't need to compile=20
the header as it is already included in the sources
see cards.cpp
#include "cards.h"
> wrote:
> > --- Gio 16/9/10, John Yoon ha scritto:
> >
> >> Hi there!
> >> I have set the links to the files I used below:
> >> http://dl.dropbox.com/u/1729951/cards.cpp
> >> http://dl.dropbox.com/u/1729951/cards.h
> >> http://dl.dropbox.com/u/1729951/hw8.cpp
> >>
> >> I run this on cygwin:
> >> $ g++ cards.h cards.cpp hw8.cpp
> >> cards.h:74: internal compiler error: Segmentation
> fault
> >> Please submit a full bug report,
> >> with preprocessed source if appropriate.
> >> See <URL:http://cygwin.com/problems.html> for
> >> instructions.
> >>
> >> These files run fine on Ubuntu and LinuxMint
> >> Any idea what the problem could be?
> >> John
> >
> > also on cygwin
> >
> > $ g++ -c cards.cpp -o cards.o
> > $ g++ -c hw8.cpp -o hw8.o
> > $ g++ =A0hw8.o cards.o -o cards
> >
> > or
> > $ g++ =A0hw8.cpp cards.cpp =A0-o cards
> >
> > $ g++ --version
> > g++ (GCC) 4.3.4 20090804 (release) 1
> >
> > Regards
> > Marco
> >
--
Problem reports: http://cygwin.com/problems.html
FAQ: http://cygwin.com/faq/
Documentation: http://cygwin.com/docs.html
Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple
| webmaster | delorie software privacy |
| Copyright © 2019 by DJ Delorie | Updated Jul 2019 |