This is the mail archive of the
binutils@sources.redhat.com
mailing list for the binutils project.
Re: PATCH: Fix "make check" in ld for gcc 3.1
- From: "H . J . Lu" <hjl at lucon dot org>
- To: binutils at sources dot redhat dot com
- Date: Sun, 2 Jun 2002 21:58:18 -0700
- Subject: Re: PATCH: Fix "make check" in ld for gcc 3.1
- References: <200206022240.SAA97175@bromo.msbb.uc.edu> <m3r8jp7zjl.fsf@mira.informatik.hu-berlin.de> <20020602214842.A16816@lucon.org>
On Sun, Jun 02, 2002 at 09:48:42PM -0700, H . J . Lu wrote:
> On Mon, Jun 03, 2002 at 06:32:14AM +0200, Martin v. Loewis wrote:
> > Jack Howarth <howarth@bromo.msbb.uc.edu> writes:
> >
> > > Running /home/howarth/debian-binutils/binutils-2.12.90.0.9/build-tree/binutils-2.12.90.0.9/ld/testsuite/ld-srec/srec.exp ...
> > > FAIL: S-records with constructors
> >
> > Pardon my ignorance, but why is this breakage even a problem?
> > I.e. what program on GNU/Linux will ever use this srec format?
> >
>
> I will check in this patch for gcc 3.1 when -fuse-cxa-atexit is used
> as an obvious fix.
>
>
> H.J.
> ---
> 2002-06-02 H.J. Lu <hjl@gnu.org>
>
> * ld-srec/sr3.cc (__dso_handle): Added for gcc 3.1 with
> -fuse-cxa-atexit.
> (__cxa_atexit): Likewise.
>
This is the patch I checked in so that it will work -Wall -W.
H.J.
--- ld-srec/sr3.cc.atexit Fri Jan 28 09:10:53 2000
+++ ld-srec/sr3.cc Sun Jun 2 21:52:57 2002
@@ -116,3 +116,12 @@ Foo::~Foo ()
{
foos--;
}
+
+void *__dso_handle;
+
+extern "C"
+int
+__cxa_atexit (void)
+{
+ return 0;
+}