public inbox for ecos-discuss@sourceware.org
 help / color / mirror / Atom feed
* [ECOS] Problem with Hello world
@ 2007-04-19 15:07 LONY David
  2007-04-19 15:17 ` Andrew Lunn
  0 siblings, 1 reply; 25+ messages in thread
From: LONY David @ 2007-04-19 15:07 UTC (permalink / raw)
  To: ecos-discuss

Hi all,

I'm new to ecos and I've have some problem with the Hello World program 
on Linux Synthetic Target (default template). I'm sucessfully compile 
eCos on the configtool with these options :
-Wall -Wpointer-arith -Winline -Wundef -Woverloaded-virtual -g -O2 
-ffunction-sections -fdata-sections -fno-rtti -fno-exceptions -fvtable-gc
for Global Compiler Flags

and

-g -nostdlib -Wl,--gc-sections -Wl,-static
for Global Linker Flags

then i compile a small program :

#include <stdio.h>
int main(void)
{
 printf("Hello, eCos world!\n");
 return 0;
}

like this : gcc -g -ILinux_install/include main.c -LLinux_install/lib 
-Ttarget.ld -nostdlib
then I try to debug the final executable with gdb like that :

[lony@localhost eCOS_config]$ gdb
GNU gdb Red Hat Linux (6.3.0.0-1.21rh)
Copyright 2004 Free Software Foundation, Inc.
GDB is free software, covered by the GNU General Public License, and you are
welcome to change it and/or distribute copies of it under certain 
conditions.
Type "show copying" to see the conditions.
There is absolutely no warranty for GDB.  Type "show warranty" for details.
This GDB was configured as "i386-redhat-linux-gnu".
(gdb) file a.out
Reading symbols from /home/lony/eCOS_config/a.out...done.
Using host libthread_db library "/lib/libthread_db.so.1".
(gdb) r
Starting program: /home/lony/eCOS_config/a.out
Reading symbols from shared object read from target memory...done.
Loaded system supplied DSO at 0xbb2000

Program received signal SIGSEGV, Segmentation fault.
0x0100bf46 in _memcpy (s1=0x0, s2=0x100ec68, n=18) at 
/home/lony/ecos/ecos-2.0/packages/infra/v2_0/src/memcpy.c:165
165             *aligned_dst++ = *aligned_src++;
(gdb)

does I make something wrong ?
Thanks you
Best regards

David LONY






-- 
Before posting, please read the FAQ: http://ecos.sourceware.org/fom/ecos
and search the list archive: http://ecos.sourceware.org/ml/ecos-discuss

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

* Re: [ECOS] Problem with Hello world
  2007-04-19 15:07 [ECOS] Problem with Hello world LONY David
@ 2007-04-19 15:17 ` Andrew Lunn
  2007-04-19 15:33   ` David LONY
  0 siblings, 1 reply; 25+ messages in thread
From: Andrew Lunn @ 2007-04-19 15:17 UTC (permalink / raw)
  To: LONY David; +Cc: eCos Disuss

On Thu, Apr 19, 2007 at 05:09:08PM +0200, LONY David wrote:
> Hi all,
> 
> I'm new to ecos and I've have some problem with the Hello World program 
> on Linux Synthetic Target (default template). I'm sucessfully compile 
> eCos on the configtool with these options :
> -Wall -Wpointer-arith -Winline -Wundef -Woverloaded-virtual -g -O2 
> -ffunction-sections -fdata-sections -fno-rtti -fno-exceptions -fvtable-gc
> for Global Compiler Flags
> 
> and
> 
> -g -nostdlib -Wl,--gc-sections -Wl,-static
> for Global Linker Flags
> 
> then i compile a small program :
> 
> #include <stdio.h>
> int main(void)
> {
> printf("Hello, eCos world!\n");
> return 0;
> }
> 
> like this : gcc -g -ILinux_install/include main.c -LLinux_install/lib 
> -Ttarget.ld -nostdlib
> then I try to debug the final executable with gdb like that :
> 
> [lony@localhost eCOS_config]$ gdb
> GNU gdb Red Hat Linux (6.3.0.0-1.21rh)
> Copyright 2004 Free Software Foundation, Inc.
> GDB is free software, covered by the GNU General Public License, and you are
> welcome to change it and/or distribute copies of it under certain 
> conditions.
> Type "show copying" to see the conditions.
> There is absolutely no warranty for GDB.  Type "show warranty" for details.
> This GDB was configured as "i386-redhat-linux-gnu".
> (gdb) file a.out
> Reading symbols from /home/lony/eCOS_config/a.out...done.
> Using host libthread_db library "/lib/libthread_db.so.1".
> (gdb) r
> Starting program: /home/lony/eCOS_config/a.out
> Reading symbols from shared object read from target memory...done.
> Loaded system supplied DSO at 0xbb2000
> 
> Program received signal SIGSEGV, Segmentation fault.
> 0x0100bf46 in _memcpy (s1=0x0, s2=0x100ec68, n=18) at 
> /home/lony/ecos/ecos-2.0/packages/infra/v2_0/src/memcpy.c:165

eCos 2.0 is very, very old. First i suggest you update to anoncvs.

     Andrew

-- 
Before posting, please read the FAQ: http://ecos.sourceware.org/fom/ecos
and search the list archive: http://ecos.sourceware.org/ml/ecos-discuss

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

* Re: [ECOS] Problem with Hello world
  2007-04-19 15:17 ` Andrew Lunn
@ 2007-04-19 15:33   ` David LONY
  2007-04-19 15:41     ` Andrew Lunn
  0 siblings, 1 reply; 25+ messages in thread
From: David LONY @ 2007-04-19 15:33 UTC (permalink / raw)
  To: Andrew Lunn; +Cc: ecos-discuss

Ok I will upgrade my version of eCos. But I have to compile it ? I will 
only download the source of eCos ?
To install eCos on my PC, I used the script  ecos-install.tcl and I just 
update my PATH and export some variable...

Thanks you for all
Best regards
David LONY

Andrew Lunn a écrit :
> On Thu, Apr 19, 2007 at 05:09:08PM +0200, LONY David wrote:
>   
>> Hi all,
>>
>> I'm new to ecos and I've have some problem with the Hello World program 
>> on Linux Synthetic Target (default template). I'm sucessfully compile 
>> eCos on the configtool with these options :
>> -Wall -Wpointer-arith -Winline -Wundef -Woverloaded-virtual -g -O2 
>> -ffunction-sections -fdata-sections -fno-rtti -fno-exceptions -fvtable-gc
>> for Global Compiler Flags
>>
>> and
>>
>> -g -nostdlib -Wl,--gc-sections -Wl,-static
>> for Global Linker Flags
>>
>> then i compile a small program :
>>
>> #include <stdio.h>
>> int main(void)
>> {
>> printf("Hello, eCos world!\n");
>> return 0;
>> }
>>
>> like this : gcc -g -ILinux_install/include main.c -LLinux_install/lib 
>> -Ttarget.ld -nostdlib
>> then I try to debug the final executable with gdb like that :
>>
>> [lony@localhost eCOS_config]$ gdb
>> GNU gdb Red Hat Linux (6.3.0.0-1.21rh)
>> Copyright 2004 Free Software Foundation, Inc.
>> GDB is free software, covered by the GNU General Public License, and you are
>> welcome to change it and/or distribute copies of it under certain 
>> conditions.
>> Type "show copying" to see the conditions.
>> There is absolutely no warranty for GDB.  Type "show warranty" for details.
>> This GDB was configured as "i386-redhat-linux-gnu".
>> (gdb) file a.out
>> Reading symbols from /home/lony/eCOS_config/a.out...done.
>> Using host libthread_db library "/lib/libthread_db.so.1".
>> (gdb) r
>> Starting program: /home/lony/eCOS_config/a.out
>> Reading symbols from shared object read from target memory...done.
>> Loaded system supplied DSO at 0xbb2000
>>
>> Program received signal SIGSEGV, Segmentation fault.
>> 0x0100bf46 in _memcpy (s1=0x0, s2=0x100ec68, n=18) at 
>> /home/lony/ecos/ecos-2.0/packages/infra/v2_0/src/memcpy.c:165
>>     
>
> eCos 2.0 is very, very old. First i suggest you update to anoncvs.
>
>      Andrew
>
>
>   



-- 
Before posting, please read the FAQ: http://ecos.sourceware.org/fom/ecos
and search the list archive: http://ecos.sourceware.org/ml/ecos-discuss

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

* Re: [ECOS] Problem with Hello world
  2007-04-19 15:33   ` David LONY
@ 2007-04-19 15:41     ` Andrew Lunn
  2007-04-20 13:16       ` David LONY
  0 siblings, 1 reply; 25+ messages in thread
From: Andrew Lunn @ 2007-04-19 15:41 UTC (permalink / raw)
  To: David LONY; +Cc: Andrew Lunn, ecos-discuss

On Thu, Apr 19, 2007 at 05:34:55PM +0200, David LONY wrote:
> Ok I will upgrade my version of eCos. But I have to compile it ? I will 
> only download the source of eCos ?

You can keep the host tools if they are working O.K. for you. But you
need to compile eCos itself new.

     Andrew

-- 
Before posting, please read the FAQ: http://ecos.sourceware.org/fom/ecos
and search the list archive: http://ecos.sourceware.org/ml/ecos-discuss

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

* Re: [ECOS] Problem with Hello world
  2007-04-19 15:41     ` Andrew Lunn
@ 2007-04-20 13:16       ` David LONY
  2007-04-20 13:54         ` Andrew Lunn
  0 siblings, 1 reply; 25+ messages in thread
From: David LONY @ 2007-04-20 13:16 UTC (permalink / raw)
  To: Andrew Lunn, ecos-discuss

Fantastic!!!!
It works well!!!
I upgrade to the next version and after compile the library I can 
compile my Hello World program and see the output.
I used the Linux Synthetic template with default profile on my Linux 
distro (Fedora Core 4). But, if I use the same template on cygwin, It 
will work?

However, I have another question... It is possible to use the Linux 
Synthetic template and compile eCos for ARM ?
I just have to change the compiler (gcc -> arm-elf-gcc) and compile my 
Hello World again (with the good compiler) ?

If not, does the configtool program contains a ARM profile (template) 
which allow me to test the same Hello World but for ARM processor ?

Thanks you Andrew for all.
Best regards.

David LONY

Andrew Lunn a écrit :
> On Thu, Apr 19, 2007 at 05:34:55PM +0200, David LONY wrote:
>   
>> Ok I will upgrade my version of eCos. But I have to compile it ? I will 
>> only download the source of eCos ?
>>     
>
> You can keep the host tools if they are working O.K. for you. But you
> need to compile eCos itself new.
>
>      Andrew
>
>   



-- 
Before posting, please read the FAQ: http://ecos.sourceware.org/fom/ecos
and search the list archive: http://ecos.sourceware.org/ml/ecos-discuss

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

* Re: [ECOS] Problem with Hello world
  2007-04-20 13:16       ` David LONY
@ 2007-04-20 13:54         ` Andrew Lunn
  2007-04-20 14:16           ` David LONY
  0 siblings, 1 reply; 25+ messages in thread
From: Andrew Lunn @ 2007-04-20 13:54 UTC (permalink / raw)
  To: David LONY; +Cc: Andrew Lunn, ecos-discuss

On Fri, Apr 20, 2007 at 03:18:15PM +0200, David LONY wrote:
> Fantastic!!!!
> It works well!!!
> I upgrade to the next version and after compile the library I can 
> compile my Hello World program and see the output.
> I used the Linux Synthetic template with default profile on my Linux 
> distro (Fedora Core 4). But, if I use the same template on cygwin, It 
> will work?

So you want to cross compile a Linux binary on cygwin. In theory, it
should work, but i see no sane reason to do it.

> However, I have another question... It is possible to use the Linux 
> Synthetic template and compile eCos for ARM ?

No. The target is hardware target dependent. You need to configure
eCos for your specific ARM platform. What development board are you
using.

        Andrew

-- 
Before posting, please read the FAQ: http://ecos.sourceware.org/fom/ecos
and search the list archive: http://ecos.sourceware.org/ml/ecos-discuss

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

* Re: [ECOS] Problem with Hello world
  2007-04-20 13:54         ` Andrew Lunn
@ 2007-04-20 14:16           ` David LONY
  2007-04-20 14:51             ` Andrew Lunn
  0 siblings, 1 reply; 25+ messages in thread
From: David LONY @ 2007-04-20 14:16 UTC (permalink / raw)
  To: Andrew Lunn, ecos-discuss

I tried to compile eCos on cygwin but I obtain an error :

/opt/ecos/ecoscvs/ecos/packages/io/common/current/src/ioinit.cxx
/opt/ecos/ecoscvs/ecos/packages/io/common/current/src/ioinit.cxx:1: 
warning: -ffunction-sections may affect debugging on some targets
make[1]: Leaving directory 
`/ecos-d/cygwin/home/lony/Linux_build/io/common/current'
/tmp/ccucSUU4.s: Assembler messages:
make: Leaving directory `/ecos-d/cygwin/home/lony/Linux_build'
/tmp/ccucSUU4.s:157: Error: junk at end of line, first unrecognized 
character is `"'
/tmp/ccucSUU4.s:159: Warning: .type pseudo-op used outside of 
.def/.endef ignored.
/tmp/ccucSUU4.s:159: Error: junk at end of line, first unrecognized 
character is `_'
/tmp/ccucSUU4.s:162: Error: unknown pseudo-op: `.previous'
/tmp/ccucSUU4.s:164: Error: junk at end of line, first unrecognized 
character is `"'
/tmp/ccucSUU4.s:166: Warning: .type pseudo-op used outside of 
.def/.endef ignored.
/tmp/ccucSUU4.s:166: Error: junk at end of line, first unrecognized 
character is `_'
/tmp/ccucSUU4.s:169: Error: unknown pseudo-op: `.previous'
make[1]: *** [src/ioinit.o.d] Error 1
make: *** [build] Error 2

I just change in Global Build Options -> Global command prefix -> 
"empty", because I don't have i686-pc-linux-gcc (I tried with 
i686-pc-cygwin but I don't have i686-pc-cygwin-ar)

I don't have any ARM platform... Only a ARM compiler (arm-elf-gcc) and 
another tools like arm-elf-run or arm-elf-gdb.
So, it is not possible to configure my profile to compile for an ARM 
platform but without a specific ARM hardware?

Andrew Lunn a écrit :
> On Fri, Apr 20, 2007 at 03:18:15PM +0200, David LONY wrote:
>   
>> Fantastic!!!!
>> It works well!!!
>> I upgrade to the next version and after compile the library I can 
>> compile my Hello World program and see the output.
>> I used the Linux Synthetic template with default profile on my Linux 
>> distro (Fedora Core 4). But, if I use the same template on cygwin, It 
>> will work?
>>     
>
> So you want to cross compile a Linux binary on cygwin. In theory, it
> should work, but i see no sane reason to do it.
>
>   
>> However, I have another question... It is possible to use the Linux 
>> Synthetic template and compile eCos for ARM ?
>>     
>
> No. The target is hardware target dependent. You need to configure
> eCos for your specific ARM platform. What development board are you
> using.
>
>         Andrew
>
>
>   



-- 
Before posting, please read the FAQ: http://ecos.sourceware.org/fom/ecos
and search the list archive: http://ecos.sourceware.org/ml/ecos-discuss

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

* Re: [ECOS] Problem with Hello world
  2007-04-20 14:16           ` David LONY
@ 2007-04-20 14:51             ` Andrew Lunn
  2007-04-20 15:04               ` David LONY
  0 siblings, 1 reply; 25+ messages in thread
From: Andrew Lunn @ 2007-04-20 14:51 UTC (permalink / raw)
  To: David LONY; +Cc: Andrew Lunn, ecos-discuss

> I just change in Global Build Options -> Global command prefix -> 
> "empty", because I don't have i686-pc-linux-gcc (I tried with 
> i686-pc-cygwin but I don't have i686-pc-cygwin-ar)

So you are trying to compile with the native cygwin tools. I've no
idea if that will work. 

> I don't have any ARM platform... Only a ARM compiler.

So pick any of the arm targets. 

   Andrew

-- 
Before posting, please read the FAQ: http://ecos.sourceware.org/fom/ecos
and search the list archive: http://ecos.sourceware.org/ml/ecos-discuss

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

* Re: [ECOS] Problem with Hello world
  2007-04-20 14:51             ` Andrew Lunn
@ 2007-04-20 15:04               ` David LONY
  2007-04-20 17:22                 ` Andrew Lunn
  0 siblings, 1 reply; 25+ messages in thread
From: David LONY @ 2007-04-20 15:04 UTC (permalink / raw)
  To: Andrew Lunn, ecos-discuss

Yes I tried to compile with native cygwin tools but it seem to not work...
I will compile another version of gcc toolchain.. (it is perhaps the 
version of these tools which are too old)

But for the ARM question...
I compile eCos with the ARM7TDMI template but when I compile my hello 
world program I can't see the output.
It is normal ?

I compile my program like that :
arm-elf-gcc -g -I arm7tdmi_install/include test.c -Larm7tdmi_install/lib 
-Ttarget.ld -nostdlib

And I try to debug it like that :
$ arm-elf-gdb -quiet
(gdb) file a.out
Reading symbols from /home/lony/a.out...done.
(gdb) target sim
Connected to the simulator.
(gdb) load
Loading section .rom_vectors, size 0x40 vma 0x40000
Loading section .text, size 0x120d4 vma 0x40040
Loading section .rodata, size 0x9c0 vma 0x52114
Loading section .data, size 0x31c vma 0x52ad4
Start address 0x40040
Transfer rate: 618368 bits in <1 sec.
(gdb) b main
Breakpoint 1 at 0x40558: file test.c, line 5.
(gdb) l
1       #include <stdio.h>
2
3       main()
4       {
5       printf("Hello\n");
6
7       return 0;
8
9       }
(gdb) r
Starting program: /home/lony/a.out

Breakpoint 1, main () at test.c:5
5       printf("Hello\n");
(gdb) c
Continuing.

But I never get my "Hello", whats wrong? Do you have any idea?

Thanks you.
Best regards

David LONY

Andrew Lunn a écrit :
>> I just change in Global Build Options -> Global command prefix -> 
>> "empty", because I don't have i686-pc-linux-gcc (I tried with 
>> i686-pc-cygwin but I don't have i686-pc-cygwin-ar)
>>     
>
> So you are trying to compile with the native cygwin tools. I've no
> idea if that will work. 
>
>   
>> I don't have any ARM platform... Only a ARM compiler.
>>     
>
> So pick any of the arm targets. 
>
>    Andrew
>
>
>   



-- 
Before posting, please read the FAQ: http://ecos.sourceware.org/fom/ecos
and search the list archive: http://ecos.sourceware.org/ml/ecos-discuss

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

* Re: [ECOS] Problem with Hello world
  2007-04-20 15:04               ` David LONY
@ 2007-04-20 17:22                 ` Andrew Lunn
  2007-04-23  9:46                   ` David LONY
  0 siblings, 1 reply; 25+ messages in thread
From: Andrew Lunn @ 2007-04-20 17:22 UTC (permalink / raw)
  To: David LONY; +Cc: eCos Disuss

On Fri, Apr 20, 2007 at 05:05:19PM +0200, David LONY wrote:
> Yes I tried to compile with native cygwin tools but it seem to not work...
> I will compile another version of gcc toolchain.. (it is perhaps the 
> version of these tools which are too old)

Why do you want to compile it using the native tools?

 
> But for the ARM question...
> I compile eCos with the ARM7TDMI template but when I compile my hello 
> world program I can't see the output.
> It is normal ?

Does the simulator simulate the serial port? Which serial port does it
simulate? Is there a device driver for the serial port? 

          Andrew


-- 
Before posting, please read the FAQ: http://ecos.sourceware.org/fom/ecos
and search the list archive: http://ecos.sourceware.org/ml/ecos-discuss

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

* Re: [ECOS] Problem with Hello world
  2007-04-20 17:22                 ` Andrew Lunn
@ 2007-04-23  9:46                   ` David LONY
  2007-04-23 10:05                     ` Andrew Lunn
  0 siblings, 1 reply; 25+ messages in thread
From: David LONY @ 2007-04-23  9:46 UTC (permalink / raw)
  To: Andrew Lunn, ecos-discuss

Andrew Lunn a écrit :
> On Fri, Apr 20, 2007 at 05:05:19PM +0200, David LONY wrote:
>   
>> Yes I tried to compile with native cygwin tools but it seem to not work...
>> I will compile another version of gcc toolchain.. (it is perhaps the 
>> version of these tools which are too old)
>>     
>
> Why do you want to compile it using the native tools?
>   
Because my environment is Windows and I want to compile eCos under 
Cygwin (with the Linux Synthetic target)
>  
>   
>> But for the ARM question...
>> I compile eCos with the ARM7TDMI template but when I compile my hello 
>> world program I can't see the output.
>> It is normal ?
>>     
>
> Does the simulator simulate the serial port? Which serial port does it
> simulate? Is there a device driver for the serial port? 
>
>           Andrew
>
>   
I'm a newbie under ARM questions... I just want to know if it possible 
to compile eCos for ARM (with arm-elf-gcc) and seems to the Linux 
Synthetic target debug it with arm-elf-gdb and see an output when I 
compile a Hello world application? Does I need a simulator (like qemu or 
vmware) ?


-- 
Before posting, please read the FAQ: http://ecos.sourceware.org/fom/ecos
and search the list archive: http://ecos.sourceware.org/ml/ecos-discuss

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

* Re: [ECOS] Problem with Hello world
  2007-04-23  9:46                   ` David LONY
@ 2007-04-23 10:05                     ` Andrew Lunn
  2007-04-23 12:36                       ` Robin Randhawa
                                         ` (2 more replies)
  0 siblings, 3 replies; 25+ messages in thread
From: Andrew Lunn @ 2007-04-23 10:05 UTC (permalink / raw)
  To: David LONY; +Cc: Andrew Lunn, ecos-discuss

> >Why do you want to compile it using the native tools?
> >  
> Because my environment is Windows and I want to compile eCos under 
> Cygwin (with the Linux Synthetic target)

So you need to build a cross compiler, since the cynwin tools are
going to produce a MS binary which is not going to run on Linux.
You need a Linux toolchain which runs on cygwin. 

http://metamod-p.sourceforge.net/cross-compiling.on.windows.for.linux.html

> >>But for the ARM question...
> >>I compile eCos with the ARM7TDMI template but when I compile my hello 
> >>world program I can't see the output.
> >>It is normal ?
> >>    
> >
> >Does the simulator simulate the serial port? Which serial port does it
> >simulate? Is there a device driver for the serial port? 

> I'm a newbie under ARM questions... I just want to know if it possible 
> to compile eCos for ARM (with arm-elf-gcc) and seems to the Linux 
> Synthetic target debug it with arm-elf-gdb and see an output when I 
> compile a Hello world application? Does I need a simulator (like qemu or 
> vmware) ?

qemu or vmware will give you i386 environments, not ARM, so they are
no use to you. You probably want to either use the synthetic target on
Linux, or use a real ARM development board which eCos supports.

       Andrew

-- 
Before posting, please read the FAQ: http://ecos.sourceware.org/fom/ecos
and search the list archive: http://ecos.sourceware.org/ml/ecos-discuss

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

* Re: [ECOS] Problem with Hello world
  2007-04-23 10:05                     ` Andrew Lunn
@ 2007-04-23 12:36                       ` Robin Randhawa
  2007-04-23 14:28                       ` David LONY
  2007-04-23 14:30                       ` Grant Edwards
  2 siblings, 0 replies; 25+ messages in thread
From: Robin Randhawa @ 2007-04-23 12:36 UTC (permalink / raw)
  To: Andrew Lunn; +Cc: David LONY, ecos-discuss

On Mon, 2007-04-23 at 12:05 +0200, Andrew Lunn wrote:

> 
> > I'm a newbie under ARM questions... I just want to know if it possible 
> > to compile eCos for ARM (with arm-elf-gcc) and seems to the Linux 
> > Synthetic target debug it with arm-elf-gdb and see an output when I 
> > compile a Hello world application? Does I need a simulator (like qemu or 
> > vmware) ?
> 
> qemu or vmware will give you i386 environments, not ARM, so they are
> no use to you. You probably want to either use the synthetic target on
> Linux, or use a real ARM development board which eCos supports.

If it helps, skyeye [ http://www.skyeye.org/index.shtml ] is capable of
emulating some popular ARM Cores, boards built around them and run eCos
on top.

This thread
[ http://lists.gro.clinux.org/pipermail/skyeye-developer/2006-September/001029.html ]
claims to describe building skyeye for cygwin and might be of benefit
too.

Cheers,
Robin


-- 
Before posting, please read the FAQ: http://ecos.sourceware.org/fom/ecos
and search the list archive: http://ecos.sourceware.org/ml/ecos-discuss

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

* Re: [ECOS] Problem with Hello world
  2007-04-23 10:05                     ` Andrew Lunn
  2007-04-23 12:36                       ` Robin Randhawa
@ 2007-04-23 14:28                       ` David LONY
  2007-04-23 14:48                         ` Andrew Lunn
  2007-04-23 14:50                         ` [ECOS] " Grant Edwards
  2007-04-23 14:30                       ` Grant Edwards
  2 siblings, 2 replies; 25+ messages in thread
From: David LONY @ 2007-04-23 14:28 UTC (permalink / raw)
  To: Andrew Lunn, ecos-discuss

Andrew Lunn a écrit :
>>> Why do you want to compile it using the native tools?
>>>  
>>>       
>> Because my environment is Windows and I want to compile eCos under 
>> Cygwin (with the Linux Synthetic target)
>>     
>
> So you need to build a cross compiler, since the cynwin tools are
> going to produce a MS binary which is not going to run on Linux.
> You need a Linux toolchain which runs on cygwin. 
>
> http://metamod-p.sourceforge.net/cross-compiling.on.windows.for.linux.html
>
>   

I don't want to cross compile for Linux. I want to compile eCos under 
Cygwin. But I don't know why the build of eCos doesn't work...
Does I need to compile it under Linux ?

Best regards
David LONY


-- 
Before posting, please read the FAQ: http://ecos.sourceware.org/fom/ecos
and search the list archive: http://ecos.sourceware.org/ml/ecos-discuss

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

* [ECOS]  Re: Problem with Hello world
  2007-04-23 10:05                     ` Andrew Lunn
  2007-04-23 12:36                       ` Robin Randhawa
  2007-04-23 14:28                       ` David LONY
@ 2007-04-23 14:30                       ` Grant Edwards
  2007-04-23 14:54                         ` Andrew Lunn
  2007-04-23 15:09                         ` David LONY
  2 siblings, 2 replies; 25+ messages in thread
From: Grant Edwards @ 2007-04-23 14:30 UTC (permalink / raw)
  To: ecos-discuss

On 2007-04-23, Andrew Lunn <andrew@lunn.ch> wrote:

>> I'm a newbie under ARM questions... I just want to know if it possible 
>> to compile eCos for ARM (with arm-elf-gcc) and seems to the Linux 
>> Synthetic target debug it with arm-elf-gdb and see an output when I 
>> compile a Hello world application? Does I need a simulator (like qemu or 
>> vmware) ?
>
> qemu or vmware will give you i386 environments, not ARM,

Qemu will emulate an ARM.  It will emulate either an Arm
Integrator/CP or an ARM Versatile baseboard.  Both emulations
include serial ports, Ethernet, PS/2 keyboard/mouse, and LCD
controllers.

http://fabrice.bellard.free.fr/qemu/qemu-doc.html#SEC53

> so they are no use to you.

Qemu certainly should be.

> You probably want to either use the synthetic target on Linux,
> or use a real ARM development board which eCos supports.

Doesn't eCos uspport the ARM Integrator?

-- 
Grant Edwards                   grante             Yow! My EARS are GONE!!
                                  at               
                               visi.com            


-- 
Before posting, please read the FAQ: http://ecos.sourceware.org/fom/ecos
and search the list archive: http://ecos.sourceware.org/ml/ecos-discuss

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

* Re: [ECOS] Problem with Hello world
  2007-04-23 14:28                       ` David LONY
@ 2007-04-23 14:48                         ` Andrew Lunn
  2007-04-23 14:50                         ` [ECOS] " Grant Edwards
  1 sibling, 0 replies; 25+ messages in thread
From: Andrew Lunn @ 2007-04-23 14:48 UTC (permalink / raw)
  To: David LONY; +Cc: Andrew Lunn, ecos-discuss

On Mon, Apr 23, 2007 at 04:30:17PM +0200, David LONY wrote:
> Andrew Lunn a ?crit :
> >>>Why do you want to compile it using the native tools?
> >>> 
> >>>      
> >>Because my environment is Windows and I want to compile eCos under 
> >>Cygwin (with the Linux Synthetic target)
> >>    
> >
> >So you need to build a cross compiler, since the cynwin tools are
> >going to produce a MS binary which is not going to run on Linux.
> >You need a Linux toolchain which runs on cygwin. 
> >
> >http://metamod-p.sourceforge.net/cross-compiling.on.windows.for.linux.html
> >
> >  
> 
> I don't want to cross compile for Linux. I want to compile eCos under 
> Cygwin.


You said you wanted to compile the Linux Synthetic Target on Cygwin.
As the name suggests, this is for Linux. So if you want to build it on
Cygwin, you will need to cross compile it. This is very unusual, which
is why i originally asked why you wanted to do this. The way this
conversation is going makes me think you miss understand what the
Linux synthetic target is. It allows you to run eCos on top of linux
instead of on real hardware. It will only work on Linux. It will not
work on cygwin. There is no cygwin synthetic target. There is no M$
Windows Synthetic target. So if you want to run a synthetic version of
eCos on top of another operating system, it currently has to be Linux.

     Andrew



-- 
Before posting, please read the FAQ: http://ecos.sourceware.org/fom/ecos
and search the list archive: http://ecos.sourceware.org/ml/ecos-discuss

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

* [ECOS]  Re: Problem with Hello world
  2007-04-23 14:28                       ` David LONY
  2007-04-23 14:48                         ` Andrew Lunn
@ 2007-04-23 14:50                         ` Grant Edwards
  1 sibling, 0 replies; 25+ messages in thread
From: Grant Edwards @ 2007-04-23 14:50 UTC (permalink / raw)
  To: ecos-discuss

On 2007-04-23, David LONY <david.lony@pragmadev.com> wrote:

>>> Because my environment is Windows and I want to compile eCos
>>> under Cygwin (with the Linux Synthetic target)
>>
>> So you need to build a cross compiler, since the cynwin tools
>> are going to produce a MS binary which is not going to run on
>> Linux. You need a Linux toolchain which runs on cygwin. 
>>
>> http://metamod-p.sourceforge.net/cross-compiling.on.windows.for.linux.html
>
> I don't want to cross compile for Linux.

You said you did.  Look at the first quoted paragraph above.
You state you want to use the Linux synthetic target. That
means you need to cmpile for Linux.

> I want to compile eCos under Cygwin.

For what target?  You need a Cygwin-hosted cross compiler for
the desired target.  Above you stated you wanted to build eCos
for the Linux synthetic target, so you need a Cygwin-hosted,
Linux-targetted cross compiler.

> But I don't know why the build of eCos doesn't work...

Because it appears you were using a Cygwin targetted compiler
(one that produces Win32 binaries instead of Linux ELF
binaries).  That won't work.

> Does I need to compile it under Linux ?

It's certainly a lot easier to build eCos under Linux, but you
don't have to.  You do have to compile it with an appropriate
cross-compiler.

-- 
Grant Edwards                   grante             Yow! Being a BALD HERO
                                  at               is almost as FESTIVE as a
                               visi.com            TATTOOED KNOCKWURST.


-- 
Before posting, please read the FAQ: http://ecos.sourceware.org/fom/ecos
and search the list archive: http://ecos.sourceware.org/ml/ecos-discuss

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

* Re: [ECOS]  Re: Problem with Hello world
  2007-04-23 14:30                       ` Grant Edwards
@ 2007-04-23 14:54                         ` Andrew Lunn
  2007-04-23 15:26                           ` Grant Edwards
  2007-04-23 15:30                           ` David LONY
  2007-04-23 15:09                         ` David LONY
  1 sibling, 2 replies; 25+ messages in thread
From: Andrew Lunn @ 2007-04-23 14:54 UTC (permalink / raw)
  To: Grant Edwards; +Cc: ecos-discuss

> Qemu will emulate an ARM.  It will emulate either an Arm
> Integrator/CP or an ARM Versatile baseboard.  Both emulations
> include serial ports, Ethernet, PS/2 keyboard/mouse, and LCD
> controllers.
> 
> http://fabrice.bellard.free.fr/qemu/qemu-doc.html#SEC53

Upps, sorry. My error. I was thinking of that old dos extender which
has a similar name..., not that i can remember its exact name, now
that i think about it.

     Andrew

-- 
Before posting, please read the FAQ: http://ecos.sourceware.org/fom/ecos
and search the list archive: http://ecos.sourceware.org/ml/ecos-discuss

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

* Re: [ECOS]  Re: Problem with Hello world
  2007-04-23 14:30                       ` Grant Edwards
  2007-04-23 14:54                         ` Andrew Lunn
@ 2007-04-23 15:09                         ` David LONY
  2007-04-23 15:12                           ` Andrew Lunn
  2007-04-23 15:35                           ` Grant Edwards
  1 sibling, 2 replies; 25+ messages in thread
From: David LONY @ 2007-04-23 15:09 UTC (permalink / raw)
  To: Grant Edwards; +Cc: ecos-discuss

Grant Edwards a écrit :
> On 2007-04-23, Andrew Lunn <andrew@lunn.ch> wrote:
>
>   
>>> I'm a newbie under ARM questions... I just want to know if it possible 
>>> to compile eCos for ARM (with arm-elf-gcc) and seems to the Linux 
>>> Synthetic target debug it with arm-elf-gdb and see an output when I 
>>> compile a Hello world application? Does I need a simulator (like qemu or 
>>> vmware) ?
>>>       
>> qemu or vmware will give you i386 environments, not ARM,
>>     
>
> Qemu will emulate an ARM.  It will emulate either an Arm
> Integrator/CP or an ARM Versatile baseboard.  Both emulations
> include serial ports, Ethernet, PS/2 keyboard/mouse, and LCD
> controllers.
>
> http://fabrice.bellard.free.fr/qemu/qemu-doc.html#SEC53
>
>   
>> so they are no use to you.
>>     
>
> Qemu certainly should be.
>   
So.. I just need to compile eCos with the ARM 7 TDMI INTEGRATOR template 
(with the Redboot profile), with all options to default (compiler = 
arm-elf-gcc....etc)
Then I use arm-elf-objcopy to copy the elf to a bin format... and just 
use Qemu-arm with good options ? It will work?

>   
>> You probably want to either use the synthetic target on Linux,
>> or use a real ARM development board which eCos supports.
>>     
>
> Doesn't eCos uspport the ARM Integrator?
>
>   
What is the ARM Integrator?


-- 
Before posting, please read the FAQ: http://ecos.sourceware.org/fom/ecos
and search the list archive: http://ecos.sourceware.org/ml/ecos-discuss

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

* Re: [ECOS]  Re: Problem with Hello world
  2007-04-23 15:09                         ` David LONY
@ 2007-04-23 15:12                           ` Andrew Lunn
  2007-04-23 15:35                           ` Grant Edwards
  1 sibling, 0 replies; 25+ messages in thread
From: Andrew Lunn @ 2007-04-23 15:12 UTC (permalink / raw)
  To: David LONY; +Cc: Grant Edwards, ecos-discuss

> What is the ARM Integrator?

An ARM development board. Try google!

    Andrew

-- 
Before posting, please read the FAQ: http://ecos.sourceware.org/fom/ecos
and search the list archive: http://ecos.sourceware.org/ml/ecos-discuss

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

* [ECOS]  Re: Problem with Hello world
  2007-04-23 14:54                         ` Andrew Lunn
@ 2007-04-23 15:26                           ` Grant Edwards
  2007-04-23 15:30                           ` David LONY
  1 sibling, 0 replies; 25+ messages in thread
From: Grant Edwards @ 2007-04-23 15:26 UTC (permalink / raw)
  To: ecos-discuss

On 2007-04-23, Andrew Lunn <andrew@lunn.ch> wrote:

>> Qemu will emulate an ARM.  It will emulate either an Arm
>> Integrator/CP or an ARM Versatile baseboard.  Both emulations
>> include serial ports, Ethernet, PS/2 keyboard/mouse, and LCD
>> controllers.
>> 
>> http://fabrice.bellard.free.fr/qemu/qemu-doc.html#SEC53
>
> Upps, sorry. My error. I was thinking of that old dos extender which
> has a similar name..., not that i can remember its exact name, now
> that i think about it.

Dosemu?  http://dosemu.sourceforge.net/

It did 16-bit DOS emulation as it ran in virtual 8086 mode (it
emulated some common protected mode DOS extensions). All in
all, it was a pretty cool hack.  I used it for years to run the
DOS version of the software to control a 68HC11 in-circuit
emulator.

I've wondered if the ARM Integrator HAL would run on the Qemu
Integrator.  The Qemu Integrator platform is for the
Integrator/CP board (an ARM926E or ARM1026E).  

Unfortunately the eCos page doesn't say which board it supports
(there are about a half-dozen different "Integrator" boards). I
haven't found anything in the HAL sources, cdl, or Changelog
that specifies which board it's for.  Does anybody know what
board(s) the "Integrator" HAL supports?

Some concrete info on what board a HAL is for (e.g. an actual
part or model number) sure would be a good thing to put into
the CDL...  ;)

-- 
Grant Edwards                   grante             Yow! Did I do an INCORRECT
                                  at               THING??
                               visi.com            


-- 
Before posting, please read the FAQ: http://ecos.sourceware.org/fom/ecos
and search the list archive: http://ecos.sourceware.org/ml/ecos-discuss

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

* Re: [ECOS]  Re: Problem with Hello world
  2007-04-23 14:54                         ` Andrew Lunn
  2007-04-23 15:26                           ` Grant Edwards
@ 2007-04-23 15:30                           ` David LONY
  2007-04-23 15:40                             ` Grant Edwards
  1 sibling, 1 reply; 25+ messages in thread
From: David LONY @ 2007-04-23 15:30 UTC (permalink / raw)
  To: Grant Edwards, ecos-discuss

Andrew Lunn a écrit :
>> Qemu will emulate an ARM.  It will emulate either an Arm
>> Integrator/CP or an ARM Versatile baseboard.  Both emulations
>> include serial ports, Ethernet, PS/2 keyboard/mouse, and LCD
>> controllers.
>>
>> http://fabrice.bellard.free.fr/qemu/qemu-doc.html#SEC53
>>     
>
> Upps, sorry. My error. I was thinking of that old dos extender which
> has a similar name..., not that i can remember its exact name, now
> that i think about it.
>
>      Andrew
>
>   

How I can build an eCos kernel which will work on Qemu (ARM) ?
Does anybody make it before ?

Best regards.
David LONY


-- 
Before posting, please read the FAQ: http://ecos.sourceware.org/fom/ecos
and search the list archive: http://ecos.sourceware.org/ml/ecos-discuss

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

* [ECOS]  Re: Problem with Hello world
  2007-04-23 15:09                         ` David LONY
  2007-04-23 15:12                           ` Andrew Lunn
@ 2007-04-23 15:35                           ` Grant Edwards
  1 sibling, 0 replies; 25+ messages in thread
From: Grant Edwards @ 2007-04-23 15:35 UTC (permalink / raw)
  To: ecos-discuss

On 2007-04-23, David LONY <david.lony@pragmadev.com> wrote:

>> Qemu will emulate an ARM.  It will emulate either an Arm
>> Integrator/CP or an ARM Versatile baseboard.  Both emulations
>> include serial ports, Ethernet, PS/2 keyboard/mouse, and LCD
>> controllers.
>>
>> http://fabrice.bellard.free.fr/qemu/qemu-doc.html#SEC53
>
> So.. I just need to compile eCos with the ARM 7 TDMI INTEGRATOR template 
> (with the Redboot profile), with all options to default (compiler = 
> arm-elf-gcc....etc)
> Then I use arm-elf-objcopy to copy the elf to a bin format... and just 
> use Qemu-arm with good options ? It will work?

Possibly.  As I pointed out in a different posting, there are a
bunch of different "Integrator" boards, and there's nothing in
the eCos docs which says which "Integrator" it's for.

In the worst case, I would think the Integrator HAL would work
with Qemu's Integrator/CP emulation with some minimal amount of
tweaking.

>>> You probably want to either use the synthetic target on Linux,
>>> or use a real ARM development board which eCos supports.
>>
>> Doesn't eCos uspport the ARM Integrator?
>>   
> What is the ARM Integrator?

Go read the Qemu link I posted.  

Learn how to use Google.  

Read.

http://www.arm.com/documentation/Boards_and_Firmware/index.html

-- 
Grant Edwards                   grante             Yow! I'm not an Iranian!!
                                  at               I voted for Dianne
                               visi.com            Feinstein!!


-- 
Before posting, please read the FAQ: http://ecos.sourceware.org/fom/ecos
and search the list archive: http://ecos.sourceware.org/ml/ecos-discuss

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

* [ECOS]  Re: Problem with Hello world
  2007-04-23 15:30                           ` David LONY
@ 2007-04-23 15:40                             ` Grant Edwards
  2007-04-23 19:15                               ` Grant Edwards
  0 siblings, 1 reply; 25+ messages in thread
From: Grant Edwards @ 2007-04-23 15:40 UTC (permalink / raw)
  To: ecos-discuss

On 2007-04-23, David LONY <david.lony@pragmadev.com> wrote:

>>> Qemu will emulate an ARM.  It will emulate either an Arm
>>> Integrator/CP or an ARM Versatile baseboard.  Both emulations
>>> include serial ports, Ethernet, PS/2 keyboard/mouse, and LCD
>>> controllers.
>>>
>>> http://fabrice.bellard.free.fr/qemu/qemu-doc.html#SEC53
>>
>> Upps, sorry. My error. I was thinking of that old dos extender
>> which has a similar name..., not that i can remember its exact
>> name, now that i think about it.
>
> How I can build an eCos kernel which will work on Qemu (ARM) ?
> Does anybody make it before ?

Oh for pete's sake, go buy a book:

  http://www.amazon.com/Embedded-Software-Development-Anthony-Massa/dp/0130354732

Sign up for eCos training:

  http://www.ecoscentric.com/train.shtml
  
Learn to use Google:

http://www-128.ibm.com/developerworks/power/library/pa-tams2/?ca=dgr-lnxw16TestTAMSP2
http://en.wikipedia.org/wiki/ECos
  
-- 
Grant Edwards                   grante             Yow! Clear the laundromat!!
                                  at               This whirl-o-matic just had
                               visi.com            a nuclear meltdown!!


-- 
Before posting, please read the FAQ: http://ecos.sourceware.org/fom/ecos
and search the list archive: http://ecos.sourceware.org/ml/ecos-discuss

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

* [ECOS]  Re: Problem with Hello world
  2007-04-23 15:40                             ` Grant Edwards
@ 2007-04-23 19:15                               ` Grant Edwards
  0 siblings, 0 replies; 25+ messages in thread
From: Grant Edwards @ 2007-04-23 19:15 UTC (permalink / raw)
  To: ecos-discuss

On 2007-04-23, Grant Edwards <grante@visi.com> wrote:
> On 2007-04-23, David LONY <david.lony@pragmadev.com> wrote:
>
>>>> Qemu will emulate an ARM.  It will emulate either an Arm
>>>> Integrator/CP or an ARM Versatile baseboard.  Both emulations
>>>> include serial ports, Ethernet, PS/2 keyboard/mouse, and LCD
>>>> controllers.
>>>>
>>>> http://fabrice.bellard.free.fr/qemu/qemu-doc.html#SEC53
>>>
>>> Upps, sorry. My error. I was thinking of that old dos extender
>>> which has a similar name..., not that i can remember its exact
>>> name, now that i think about it.
>>
>> How I can build an eCos kernel which will work on Qemu (ARM) ?
>> Does anybody make it before ?
>
> Oh for pete's sake, go buy a book:
>
>   http://www.amazon.com/Embedded-Software-Development-Anthony-Massa/dp/0130354732

That may have appeared to be a bit harsh.  If so, you might
also want to give this a read:

http://www.catb.org/~esr/faqs/smart-questions.html

-- 
Grant Edwards                   grante             Yow! I appoint you
                                  at               ambassador to Fantasy
                               visi.com            Island!!!


-- 
Before posting, please read the FAQ: http://ecos.sourceware.org/fom/ecos
and search the list archive: http://ecos.sourceware.org/ml/ecos-discuss

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

end of thread, other threads:[~2007-04-23 19:15 UTC | newest]

Thread overview: 25+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2007-04-19 15:07 [ECOS] Problem with Hello world LONY David
2007-04-19 15:17 ` Andrew Lunn
2007-04-19 15:33   ` David LONY
2007-04-19 15:41     ` Andrew Lunn
2007-04-20 13:16       ` David LONY
2007-04-20 13:54         ` Andrew Lunn
2007-04-20 14:16           ` David LONY
2007-04-20 14:51             ` Andrew Lunn
2007-04-20 15:04               ` David LONY
2007-04-20 17:22                 ` Andrew Lunn
2007-04-23  9:46                   ` David LONY
2007-04-23 10:05                     ` Andrew Lunn
2007-04-23 12:36                       ` Robin Randhawa
2007-04-23 14:28                       ` David LONY
2007-04-23 14:48                         ` Andrew Lunn
2007-04-23 14:50                         ` [ECOS] " Grant Edwards
2007-04-23 14:30                       ` Grant Edwards
2007-04-23 14:54                         ` Andrew Lunn
2007-04-23 15:26                           ` Grant Edwards
2007-04-23 15:30                           ` David LONY
2007-04-23 15:40                             ` Grant Edwards
2007-04-23 19:15                               ` Grant Edwards
2007-04-23 15:09                         ` David LONY
2007-04-23 15:12                           ` Andrew Lunn
2007-04-23 15:35                           ` Grant Edwards

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).