public inbox for ecos-discuss@sourceware.org
 help / color / mirror / Atom feed
* [ECOS] MBX860(40MHz) stubs with cvs snapshot - mapping problem?
@ 2000-10-04 13:44 Michael Barker
  2000-10-18 13:08 ` [ECOS] gui doesn't create bss section (was: MBX860(40MHz) stubs with cvs snapshot - mapping problem?) Michael Barker
  0 siblings, 1 reply; 5+ messages in thread
From: Michael Barker @ 2000-10-04 13:44 UTC (permalink / raw)
  To: ecos-discuss

I'm trying to build the GDB stubs for the flash on the MBX board.
I'm using the ftp'd snapshot ecos-000921.tar.gz and the 0.3.1.1 config gui.

First, I get a constraint which I have to resolve manually:
CYGBLD_ISO_ERRNO_CODES_HEADER == "<cyg/error/codes.h>"  so I set the
variable to that using the checkbox under 'Error handling' in the posix
section.

Then,
I'm getting this error:

powerpc-eabi-gcc -msoft-float -mcpu=860 -g -nostdlib -Wl,--gc-sections -Wl,-
static -L//C/Cygwin/src/checkout/ecos/test_install/lib -Ttarget.ld -o
//C/Cygwin/src/checkout/ecos/test_install/bin/gdb_module.img
src/stubrom/gdb_module.o
/tools/H-i686-pc-cygwin/powerpc-eabi/bin/ld: warning: no memory region
specified for section `.bss'
//C/Cygwin/src/checkout/ecos/test_install/lib/vectors.o: In function
`_start':
//C/Cygwin/src/checkout/ecos/test_install/lib/vectors.o(.text+0x142):
undefined reference to `__bss_start'
//C/Cygwin/src/checkout/ecos/test_install/lib/vectors.o(.text+0x146):
undefined reference to `__bss_start'
//C/Cygwin/src/checkout/ecos/test_install/lib/vectors.o(.text+0x14a):
undefined reference to `__bss_end'
//C/Cygwin/src/checkout/ecos/test_install/lib/vectors.o(.text+0x14e):
undefined reference to `__bss_end'
collect2: ld returned 1 exit status
make[1]: *** [//C/Cygwin/src/checkout/ecos/test_install/bin/gdb_module.img]
Error 1
make[1]: Leaving directory
`/src/checkout/ecos/test_build/hal/common/current'
make: *** [build] Error 2

Michael D. Barker, B.A.Sc.
Motorola SPS, Canada


^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: [ECOS] gui doesn't create bss section (was: MBX860(40MHz) stubs with cvs snapshot - mapping problem?)
  2000-10-04 13:44 [ECOS] MBX860(40MHz) stubs with cvs snapshot - mapping problem? Michael Barker
@ 2000-10-18 13:08 ` Michael Barker
  2000-10-18 13:15   ` Michael Barker
  0 siblings, 1 reply; 5+ messages in thread
From: Michael Barker @ 2000-10-18 13:08 UTC (permalink / raw)
  To: ecos-discuss

I tried building with the command-line config tool and target.ld gets
another line, which makes the stub build successfully; here it is -
    .sbss   ALIGN (0x4)  :      { __sbss_start = ABSOLUTE (.);
__SBSS_START__ = ABSOLUTE(.); *(.sbss) __SBSS_END__ = ABSOLUTE(.);
__SBSS2_START__ = ABSOLUTE(.); *(.sbss2) __SBSS2_END__ = ABSOLUTE(.);
*(.scommon) __sbss_end = ABSOLUTE (.); } >  ram

Also an unresolvable error which is there in the gui for this configuration
(see below) is not there when using the command line.
--
Michael

> I'm trying to build the GDB stubs for the flash on the MBX board.
> I'm using the ftp'd snapshot ecos-000921.tar.gz and the 0.3.1.1 config
gui.
>
> First, I get a constraint which I have to resolve manually:
> CYGBLD_ISO_ERRNO_CODES_HEADER == "<cyg/error/codes.h>"  so I set the
> variable to that using the checkbox under 'Error handling' in the posix
> section.
>
> Then,
> I'm getting this error:
>
>
powerpc-eabi-gcc -msoft-float -mcpu=860 -g -nostdlib -Wl,--gc-sections -Wl,-
> static -L//C/Cygwin/src/checkout/ecos/test_install/lib -Ttarget.ld -o
> //C/Cygwin/src/checkout/ecos/test_install/bin/gdb_module.img
> src/stubrom/gdb_module.o
> /tools/H-i686-pc-cygwin/powerpc-eabi/bin/ld: warning: no memory region
> specified for section `.bss'
> //C/Cygwin/src/checkout/ecos/test_install/lib/vectors.o: In function
> `_start':
> //C/Cygwin/src/checkout/ecos/test_install/lib/vectors.o(.text+0x142):
> undefined reference to `__bss_start'
> //C/Cygwin/src/checkout/ecos/test_install/lib/vectors.o(.text+0x146):
> undefined reference to `__bss_start'
> //C/Cygwin/src/checkout/ecos/test_install/lib/vectors.o(.text+0x14a):
> undefined reference to `__bss_end'
> //C/Cygwin/src/checkout/ecos/test_install/lib/vectors.o(.text+0x14e):
> undefined reference to `__bss_end'
> collect2: ld returned 1 exit status
> make[1]: ***
[//C/Cygwin/src/checkout/ecos/test_install/bin/gdb_module.img]
> Error 1
> make[1]: Leaving directory
> `/src/checkout/ecos/test_build/hal/common/current'
> make: *** [build] Error 2
>
> Michael D. Barker, B.A.Sc.
> Motorola SPS, Canada
>
>
>


^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: [ECOS] gui doesn't create bss section (was: MBX860(40MHz) stubs with cvs snapshot - mapping problem?)
  2000-10-18 13:08 ` [ECOS] gui doesn't create bss section (was: MBX860(40MHz) stubs with cvs snapshot - mapping problem?) Michael Barker
@ 2000-10-18 13:15   ` Michael Barker
  2000-10-20  5:47     ` Jesper Skov
  0 siblings, 1 reply; 5+ messages in thread
From: Michael Barker @ 2000-10-18 13:15 UTC (permalink / raw)
  To: ecos-discuss

Oops - wrong line - here it is - it adds the bss section.

    .bss   ALIGN (0x10)  :      { __bss_start = ABSOLUTE (.); . = . ;
*(.dynbss) *(.bss) *(COMMON) __bss_end = ABSOLUTE (.); } >  ram
    . = ALIGN(4); _end = .; PROVIDE (end = .);

I'm using 1.3.1.1 config tools, and a repository checked out yesterday from
anoncvs.
--
Michael Barker
michael.d.barker@motorola.com



^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: [ECOS] gui doesn't create bss section (was: MBX860(40MHz) stubs with cvs snapshot - mapping problem?)
  2000-10-18 13:15   ` Michael Barker
@ 2000-10-20  5:47     ` Jesper Skov
  2000-10-20  6:16       ` Jonathan Larmour
  0 siblings, 1 reply; 5+ messages in thread
From: Jesper Skov @ 2000-10-20  5:47 UTC (permalink / raw)
  To: Michael Barker; +Cc: ecos-discuss

>>>>> "Michael" == Michael Barker <Michael.D.Barker@Motorola.com> writes:

Michael> Oops - wrong line - here it is - it adds the bss section.
Michael> .bss ALIGN (0x10) : { __bss_start = ABSOLUTE (.); . = . ;
Michael> *(.dynbss) *(.bss) *(COMMON) __bss_end = ABSOLUTE (.); } >
Michael> ram . = ALIGN(4); _end = .; PROVIDE (end = .);

Michael> I'm using 1.3.1.1 config tools, and a repository checked out
Michael> yesterday from anoncvs.

I've experienced the same problem with the SH targets. 

The problem stems from, as far as I can tell, the config tool being
confused when having to relocate sections following a user section.

I adopted a workaround of not adding reserved regions (i.e.,
reserved_vectors, reserved_vsr_table, reserved_virtual_vector_table
and reserved_for_rom), but instead either adjust the memory region to
skip the necessary part at the start of memory, or force the first
(relocated) section (.vectors/.data) to appear at 0x10000.

I'm pretty sure I filed a problem report for this issue, and I don't
seem to be able to find it, so the bug is probably fixed in the next
release (for which I don't know the release date).

Jesper

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: [ECOS] gui doesn't create bss section (was: MBX860(40MHz) stubs with cvs snapshot - mapping problem?)
  2000-10-20  5:47     ` Jesper Skov
@ 2000-10-20  6:16       ` Jonathan Larmour
  0 siblings, 0 replies; 5+ messages in thread
From: Jonathan Larmour @ 2000-10-20  6:16 UTC (permalink / raw)
  To: Jesper Skov; +Cc: Michael Barker, ecos-discuss

Jesper Skov wrote:
> The problem stems from, as far as I can tell, the config tool being
> confused when having to relocate sections following a user section.
> 
> I adopted a workaround of not adding reserved regions (i.e.,
> reserved_vectors, reserved_vsr_table, reserved_virtual_vector_table
> and reserved_for_rom), but instead either adjust the memory region to
> skip the necessary part at the start of memory, or force the first
> (relocated) section (.vectors/.data) to appear at 0x10000.
> 
> I'm pretty sure I filed a problem report for this issue, and I don't
> seem to be able to find it, so the bug is probably fixed in the next
> release (for which I don't know the release date).

I see the following in the ChangeLog:

2000-06-19  John Dallaway  <jld@redhat.com>
[snip]
        * common/win32/memmap.cpp:

        Modify add_relative_sections_to_list() to skip sections
        which have already been added and track whether sections
        should be skipped.

This was committed a fortnight after the 1.3.1.1 tools were put up, so it
won't be in those.

The config tool is open source... feel free to rebuild it, although you
need VC++ :-/. I'll see if I can find time to build one that's usable
publically but don't hold your breath :-/.

Jifl
-- 
Red Hat, 35 Cambridge Place, Cambridge, UK. CB2 1NS  Tel: +44 (1223) 728762
"Plan to be spontaneous tomorrow."  ||  These opinions are all my own fault

^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2000-10-20  6:16 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2000-10-04 13:44 [ECOS] MBX860(40MHz) stubs with cvs snapshot - mapping problem? Michael Barker
2000-10-18 13:08 ` [ECOS] gui doesn't create bss section (was: MBX860(40MHz) stubs with cvs snapshot - mapping problem?) Michael Barker
2000-10-18 13:15   ` Michael Barker
2000-10-20  5:47     ` Jesper Skov
2000-10-20  6:16       ` Jonathan Larmour

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).