From owner-freebsd-hackers Sun Feb 15 14:00:59 1998 Return-Path: Received: (from majordom@localhost) by hub.freebsd.org (8.8.8/8.8.8) id OAA28219 for freebsd-hackers-outgoing; Sun, 15 Feb 1998 14:00:59 -0800 (PST) (envelope-from owner-freebsd-hackers@FreeBSD.ORG) Received: from smtp01.primenet.com (smtp01.primenet.com [206.165.6.131]) by hub.freebsd.org (8.8.8/8.8.8) with ESMTP id OAA28204 for ; Sun, 15 Feb 1998 14:00:54 -0800 (PST) (envelope-from tlambert@usr01.primenet.com) Received: (from daemon@localhost) by smtp01.primenet.com (8.8.8/8.8.8) id PAA12715; Sun, 15 Feb 1998 15:00:53 -0700 (MST) Received: from usr01.primenet.com(206.165.6.201) via SMTP by smtp01.primenet.com, id smtpd012709; Sun Feb 15 15:00:49 1998 Received: (from tlambert@localhost) by usr01.primenet.com (8.8.5/8.8.5) id PAA03843; Sun, 15 Feb 1998 15:00:48 -0700 (MST) From: Terry Lambert Message-Id: <199802152200.PAA03843@usr01.primenet.com> Subject: Re: Problems getting GCC 2.8 working on 3.0-971225-SNAP To: njs3@doc.ic.ac.uk (Niall Smart) Date: Sun, 15 Feb 1998 22:00:47 +0000 (GMT) Cc: hackers@FreeBSD.ORG In-Reply-To: from "Niall Smart" at Feb 15, 98 01:32:34 pm X-Mailer: ELM [version 2.4 PL25] MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.ORG > I've searched the list for answers to this question but came up with > nothing so here goes: > > I'm trying to get GCC 2.8 working to play with the better support for > C++ exceptions and templates. However, exceptions don't work at all, > has anyone else experienced this? Configuring GCC 2.8.0 from the GNU distribution rather than the port, I have not seen a problem with exceptions. Are you using the port? Make sure that you have installed and are using the new libgcc.a, not the old one. > I looked at the EGCS FAQ, and it said that problems with exceptions could > be caused by using an old assembler, current uses the one from binutils > 1.92.3 which sounds pretty ancient. I tried building binutils 2.8.1 with > no success: GCC 2.8.0 from the FSF works. The Cygnus stuff has broken handing for exceptions. Specifically, you have to decide at runtime instead of compile time whether you are going to allow it to be threaded or not. If you use the recently checked in changes to libc_r *and* you use GCC 2.8.0 from FSF, then the per thread exception stacks work at runtime instead of at compiler build time. If you are using threads, and expecting exceptions to work, then you *must* use this code combination (our work on the patches was done for ACAPD, which relies heavily on pthreads, exceptions, and the standard template library). You *can* use the new libc_r code with the released FreeBSD compiler, *but* if you do not use 2.8.0, then exceptions and pthreads *will NOT work*. If you are using the STL, do *NOT* use the GNU STL. Instead use the STL from http://www.ipmce.su/~fbp/stl/ . There is a conflict with libio derived code. The code here is the SGI STL, as modified by HP, as modified by the Moscow Center for SPARC Technology. There are a number of problems you will have to overcome if you plan on using pthreads; specifically, FreeBSD's pthreads are still draft 4, and do not allow static initialization of pthreads mutexes. I have a number of patches to fix this in stl_alloc.h, but since our use didn't require stl_lock.h, ropeimpl.h, or stl_rope.h, it's not fixed there (yet). I hope that FreeBSD's pthreads are standards compliant before this becomes an issue. Terry Lambert terry@lambert.org --- Any opinions in this posting are my own and not those of my present or previous employers. To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message