gcl-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Gcl-devel] Re: latest patches


From: Camm Maguire
Subject: [Gcl-devel] Re: latest patches
Date: 25 Nov 2004 13:10:29 -0500
User-agent: Gnus/5.09 (Gnus v5.9.0) Emacs/21.2

Greetings!  OK, without having time right now to investigate this
completely, I'm making an educated guess that you happen to have the
very old bfd.h header on your system commensurate with that which we
have locally in the binutils directory, and that you are configuring
with the default --enable-statsysbfd.  I had not thought of this
posibility, and so therefore the following patch *on top of what I
sent previously* is better in any case (now in CVS as well):

=============================================================================
Index: o/sfaslbfd.c
===================================================================
RCS file: /cvsroot/gcl/gcl/o/sfaslbfd.c,v
retrieving revision 1.19
diff -u -r1.19 sfaslbfd.c
--- o/sfaslbfd.c        24 Nov 2004 16:01:04 -0000      1.19
+++ o/sfaslbfd.c        25 Nov 2004 18:03:52 -0000
@@ -337,6 +337,8 @@
 
    for (s=b->sections;s;s=s->next) {
      
+     unsigned long ss=bfd_section_size(b,s);
+
      if (!(s->flags & SEC_LOAD))
        continue;
      
@@ -346,9 +348,10 @@
                                             v,0,q)) 
        FEerror("Cannot get relocated section contents\n",0);
 
-     memcpy((void *)(unsigned 
long)s->output_section->vma,v,bfd_section_size(b,s));
+     memcpy((void *)(unsigned long)s->output_section->vma,v,ss);
      
    }
+
  }
    
   dum.sm.sm_object1=faslfile;
Index: binutils/bfd/bfd-in.h
===================================================================
RCS file: /cvsroot/gcl/gcl/binutils/bfd/bfd-in.h,v
retrieving revision 1.2
diff -u -r1.2 bfd-in.h
--- binutils/bfd/bfd-in.h       24 Nov 2004 18:46:15 -0000      1.2
+++ binutils/bfd/bfd-in.h       25 Nov 2004 18:03:52 -0000
@@ -337,8 +337,7 @@
 #define bfd_get_section_lma(bfd, ptr) ((ptr)->lma + 0)
 #define bfd_get_section_alignment(bfd, ptr) ((ptr)->alignment_power + 0)
 #define bfd_section_name(bfd, ptr) ((ptr)->name)
-#define bfd_section_size(bfd, ptr) ((ptr)->_raw_size)
-/* #define bfd_section_size(bfd, ptr) (bfd_get_section_size_before_reloc(ptr)) 
*/
+#define bfd_section_size(bfd, ptr) (bfd_get_section_size_before_reloc(ptr))
 #define bfd_section_vma(bfd, ptr) ((ptr)->vma)
 #define bfd_section_lma(bfd, ptr) ((ptr)->lma)
 #define bfd_section_alignment(bfd, ptr) ((ptr)->alignment_power)
Index: binutils/bfd/bfd-in2.h
===================================================================
RCS file: /cvsroot/gcl/gcl/binutils/bfd/bfd-in2.h,v
retrieving revision 1.4
diff -u -r1.4 bfd-in2.h
--- binutils/bfd/bfd-in2.h      24 Nov 2004 18:46:16 -0000      1.4
+++ binutils/bfd/bfd-in2.h      25 Nov 2004 18:03:53 -0000
@@ -342,8 +342,7 @@
 #define bfd_get_section_lma(bfd, ptr) ((ptr)->lma + 0)
 #define bfd_get_section_alignment(bfd, ptr) ((ptr)->alignment_power + 0)
 #define bfd_section_name(bfd, ptr) ((ptr)->name)
-#define bfd_section_size(bfd, ptr) ((ptr)->_raw_size)
-/*#define bfd_section_size(bfd, ptr) (bfd_get_section_size_before_reloc(ptr))*/
+#define bfd_section_size(bfd, ptr) (bfd_get_section_size_before_reloc(ptr))
 #define bfd_section_vma(bfd, ptr) ((ptr)->vma)
 #define bfd_section_lma(bfd, ptr) ((ptr)->lma)
 #define bfd_section_alignment(bfd, ptr) ((ptr)->alignment_power)
=============================================================================
=============================================================================

I'm testing this now.  You can either wait until I run the gamut of
tests (a few days), or try this patch now if you have the time, and
think my guess is right.  You should have seen errors on the first
attempted load of a .o file ('aborted') if this hypothesis is right.

Take care,

root <address@hidden> writes:

> Camm,
> 
> I applied the patches you sent and the system build fails:
> 
> =============================================================
> make[3]: *** [/tmp/axiom/obj/linux/bin/bootsys] Error 134
> make[3]: Leaving directory `/tmp/axiom/src/boot'
> make[2]: *** [bootdir] Error 2
> make[2]: Leaving directory `/tmp/axiom/src'
> make[1]: *** [srcdir] Error 2
> make[1]: Leaving directory `/tmp/axiom'
> make: *** [all] Error 2
> =============================================================
> 
> at this point we've build a lisp image, used it to compile a
> bunch of lisp files, then exited the image. We've saved the
> image as "bootsys".
> 
> The bootsys image won't start.
> 
> Tim
> 
> 
> 
> 

-- 
Camm Maguire                                            address@hidden
==========================================================================
"The earth is but one country, and mankind its citizens."  --  Baha'u'llah




reply via email to

[Prev in Thread] Current Thread [Next in Thread]