From mboxrd@z Thu Jan 1 00:00:00 1970 From: Jesper Skov To: lunn@ma.tech.ascom.ch (Andrew Lunn) Cc: ecos-discuss@sourceware.cygnus.com Subject: Re: [ECOS] linux .rel.got problem Date: Mon, 21 Jun 1999 06:10:00 -0000 Message-id: <14190.14797.183644.99555@lassi.cygnus.co.uk> References: <199906211253.OAA20488@biferten.ma.tech.ascom.ch> <199906211253.OAA20488@biferten.ma.tech.ascom.ch> X-SW-Source: 1999-06/msg00017.html >>>>> "Andrew" == Andrew Lunn writes: Andrew> Hi folks I've run into one of the known problems with the Andrew> synthetic linux system. The problem is with the .rel.got Andrew> section, problem #18956. Andrew> The workaround is "Add a .rel.got linker-defined memory Andrew> section to the memory layout when building eCos under these Andrew> conditions". Could someone turn this in plainer English, ive Andrew> no idea what to do! Im behind a firewall so cannot get at the Andrew> CVS repositry. It's quite plain... but it may not be proper English :) Below's the patch used to fix the PR: Jesper # cvs -q diff -D"05/14/1999 11:49:21 UTC" -D"05/14/1999 11:51:21 UTC" -u Index: ChangeLog =================================================================== RCS file: /cvs/ecc/ecc/hal/i386/arch/current/ChangeLog,v retrieving revision 1.34 retrieving revision 1.35 diff -u -r1.34 -r1.35 --- ChangeLog 1999/05/13 18:00:33 1.34 +++ ChangeLog 1999/05/14 11:50:21 1.35 @@ -1,3 +1,7 @@ +1999-05-14 Jesper Skov + PR 18956 + * src/i386.ld: Fixed problem with rel_got. + 1999-05-13 Hugo Tyson * include/hal_arch.h (HAL_THREAD_INIT_CONTEXT): Align stack Index: src/i386.ld =================================================================== RCS file: /cvs/ecc/ecc/hal/i386/arch/current/src/i386.ld,v retrieving revision 1.12 retrieving revision 1.13 diff -u -r1.12 -r1.13 --- src/i386.ld 1999/04/08 14:04:33 1.12 +++ src/i386.ld 1999/05/14 11:50:22 1.13 @@ -90,10 +90,9 @@ _EXCEPT_END_ = ABSOLUTE(.);} \ > _region_ -#define SECTION_rel__got(_region_, _vma_, _lma_) \ +#define SECTION_rel_got(_region_, _vma_, _lma_) \ .rel.got _vma_ : _lma_ \ - { FORCE_OUTPUT; \ - *(.rel.got) } \ + { *(.rel.got) } \ > _region_ #define SECTION_data(_region_, _vma_, _lma_) \ # cvs -q diff -D"05/14/1999 11:49:24 UTC" -D"05/14/1999 11:51:24 UTC" -u Index: ChangeLog =================================================================== RCS file: /cvs/ecc/ecc/hal/i386/linux/current/ChangeLog,v retrieving revision 1.24 retrieving revision 1.25 diff -u -r1.24 -r1.25 --- ChangeLog 1999/04/08 14:04:34 1.24 +++ ChangeLog 1999/05/14 11:50:24 1.25 @@ -1,3 +1,9 @@ +1999-05-14 Jesper Skov + PR 18956 + * include/pkgconf/mlt_i386_linux_ram.mlt: + * include/pkgconf/mlt_i386_linux_ram.ldi: + Fixed problem with rel_got. + 1999-04-08 John Dallaway * include/pkgconf/mlt_*.*: Use double underscore substitution Index: include/pkgconf/mlt_i386_linux_ram.ldi =================================================================== RCS file: /cvs/ecc/ecc/hal/i386/linux/current/include/pkgconf/mlt_i386_linux_ram.ldi,v retrieving revision 1.5 retrieving revision 1.6 diff -u -r1.5 -r1.6 --- include/pkgconf/mlt_i386_linux_ram.ldi 1999/04/08 14:04:35 1.5 +++ include/pkgconf/mlt_i386_linux_ram.ldi 1999/05/14 11:50:25 1.6 @@ -31,11 +31,6 @@ ram : ORIGIN = 0x00000000, LENGTH = 0x800000 } -// The rel__got section doesn't result in any output but the linker -// complains if it is not present. It is necessary when compiling -// with CYGIMP_LIBC_MALLOC_CXX_DELETE_CALLS_FREE=true but causes -// problems with BFD when this option is false. - SECTIONS { SECTIONS_BEGIN @@ -46,7 +41,7 @@ SECTION_rodata (ram, ALIGN (0x8), LMA_EQ_VMA) SECTION_fixup (ram, ALIGN (0x4), LMA_EQ_VMA) SECTION_gcc_except_table (ram, ALIGN (0x1), LMA_EQ_VMA) -// SECTION_rel__got (ram, ALIGN (0x1), LMA_EQ_VMA) + SECTION_rel_got (ram, ALIGN (0x1), LMA_EQ_VMA) SECTION_data (ram, ALIGN (0x8), LMA_EQ_VMA) SECTION_sbss (ram, ALIGN (0x4), LMA_EQ_VMA) SECTION_bss (ram, ALIGN (0x10), LMA_EQ_VMA) Index: include/pkgconf/mlt_i386_linux_ram.mlt =================================================================== RCS file: /cvs/ecc/ecc/hal/i386/linux/current/include/pkgconf/mlt_i386_linux_ram.mlt,v retrieving revision 1.1 retrieving revision 1.2 diff -u -r1.1 -r1.2 --- include/pkgconf/mlt_i386_linux_ram.mlt 1999/03/04 09:48:58 1.1 +++ include/pkgconf/mlt_i386_linux_ram.mlt 1999/05/14 11:50:26 1.2 @@ -6,7 +6,8 @@ section rodata1 0 8 0 1 0 1 0 1 rodata rodata ! section rodata 0 8 0 1 0 1 0 1 fixup fixup ! section fixup 0 4 0 1 0 1 0 1 gcc_except_table gcc_except_table ! -section gcc_except_table 0 1 0 1 0 1 0 1 data data ! +section gcc_except_table 0 1 0 1 0 1 0 1 rel_got rel_got ! +section rel_got 0 1 0 1 0 1 0 1 data data ! section data 0 8 0 1 0 1 0 1 sbss sbss ! section sbss 0 4 0 1 0 1 0 1 bss bss ! section bss 0 10 0 1 0 0 0 0 !