[M3devel] building CM3 on a Raspberry Pi?

Jay K jay.krell at cornell.edu
Mon Oct 14 19:08:22 CEST 2013


 > Fatal Error: unrecognized target machine: TARGET = ARMEL_LINUX


Darn. That suggests I didn't get as far as..
update m3-sys/m3middle/src/Target.i3 and Target.m3.


 The three facts needed are: 
   endian -- it is somewhat automatic, e.g. I386_anything is little endian  
   word size -- will default to 32 unless "64" is in the name  
   jmpbuf size -- an overestimate is ok, or use https://modula3.elegosoft.com/cgi-bin/cvsweb.cgi/cm3/scripts/config/jmpbuf.c 
     This is particularly high on the list of things to fix/remove. 


You might get a few similar errors around the tree.
Historically there were target lists in a few places,
but I have reduced them significantly, i.e. switching on kernel
and processor instead of kernel/processor cross product.


The main other piece of code that changes for almost every
target is getting the instruction counter out of a context_t
for faults (except NetBSD which abstracts it).
See https://modula3.elegosoft.com/cgi-bin/cvsweb.cgi/cm3/m3-libs/m3core/src/runtime/POSIX/RTSignalC.c
But it looks like I already handled Linux/arm.


  
 - Jay


From: jay.krell at cornell.edu
To: mika at async.caltech.edu
CC: m3devel at elegosoft.com
Subject: RE: [M3devel] building CM3 on a Raspberry Pi?
Date: Mon, 14 Oct 2013 16:59:21 +0000




 > Fatal Error: unrecognized backend mode: C


Make sure you ./update.py your main toolset first.
Also, while the C backend was working a year ago, for quite
a while I did not change the builder to know about it directly.
I was going via m3cgcat.
So you need to be fairly current, or else modify the
config files a different way, and have it be slower.


 - Jay


> To: jay.krell at cornell.edu
> CC: m3devel at elegosoft.com
> Subject: Re: [M3devel] building CM3 on a Raspberry Pi?
> Date: Mon, 14 Oct 2013 09:40:08 -0700
> From: mika at async.caltech.edu
> 
> Jay writes:
> >./../gcc-4.7/libiberty/stack-limit.c:52: error: `u_quad_t' undeclared (first=
> > use in this function)if [ x"" !=3D x ]; then \
> >
> >
> >Maybe I removed too much. I.e. libquadmath. That should be easy to fix and/o=
> >r switch to C backend.
> >
> >
> >I forgot: besides switching the config file: add the parameter "c" to boot1.=
> >py.
> >
> >
> 
> If I put in config-no-install/ARMEL_LINUX
> 
> M3_BACKEND_MODE="C"
> 
> and run
> 
> ./boot1.py c ARMEL_LINUX
> 
> the following happens:
> 
> ...
> rm -f /nfs/site/home/mnystroe/work/cm3/bin/cm3.cfg
> rm -f /nfs/site/home/mnystroe/work/cm3/bin/cm3cfg.common
> rm -f /nfs/site/home/mnystroe/work/cm3/bin/gnuld.common
> cp -Pv /nfs/site/disks/wdisk.133/mnystroe/cm3-anon-cvs/cm3/m3-sys/cminstall/src/config-no-install/cm3.cfg /nfs/site/home/mnystroe/work/cm3/bin/cm3.cfg
> == package /nfs/site/disks/wdisk.133/mnystroe/cm3-anon-cvs/cm3/m3-win/import-libs ==
> 
>  +++ /nfs/site/home/mnystroe/work/cm3/bin/cm3    -build -override -DROOT=/nfs/site/disks/wdisk.133/mnystroe/cm3-anon-cvs/cm3 -boot -keep -DM3CC_TARGET=ARMEL_LINUX +++
> --- building in ARMEL_LINUX ---
> 
>  ==> /nfs/site/disks/wdisk.133/mnystroe/cm3-anon-cvs/cm3/m3-win/import-libs done
> 
> == package /nfs/site/disks/wdisk.133/mnystroe/cm3-anon-cvs/cm3/m3-libs/m3core ==
> 
>  +++ /nfs/site/home/mnystroe/work/cm3/bin/cm3    -build -override -DROOT=/nfs/site/disks/wdisk.133/mnystroe/cm3-anon-cvs/cm3 -boot -keep -DM3CC_TARGET=ARMEL_LINUX +++
> --- building in ARMEL_LINUX ---
> 
> 
> Fatal Error: unrecognized backend mode: C
> 
>  *** execution of [<function _BuildLocalFunction at 0x2aaaab5728c0>] failed ***
> 
> 
> But if I remove M3_BACKEND_MODE from ARMEL_LINUX and run the same command, the following:
> 
> ...
> rm -f /nfs/site/home/mnystroe/work/cm3/bin/cm3cfg.common
> rm -f /nfs/site/home/mnystroe/work/cm3/bin/gnuld.common
> cp -Pv /nfs/site/disks/wdisk.133/mnystroe/cm3-anon-cvs/cm3/m3-sys/cminstall/src/config-no-install/cm3.cfg /nfs/site/home/mnystroe/work/cm3/bin/cm3.cfg
> == package /nfs/site/disks/wdisk.133/mnystroe/cm3-anon-cvs/cm3/m3-win/import-libs ==
> 
>  +++ /nfs/site/home/mnystroe/work/cm3/bin/cm3    -build -override -DROOT=/nfs/site/disks/wdisk.133/mnystroe/cm3-anon-cvs/cm3 -boot -keep -DM3CC_TARGET=ARMEL_LINUX +++
> --- building in ARMEL_LINUX ---
> 
>  ==> /nfs/site/disks/wdisk.133/mnystroe/cm3-anon-cvs/cm3/m3-win/import-libs done
> 
> == package /nfs/site/disks/wdisk.133/mnystroe/cm3-anon-cvs/cm3/m3-libs/m3core ==
> 
>  +++ /nfs/site/home/mnystroe/work/cm3/bin/cm3    -build -override -DROOT=/nfs/site/disks/wdisk.133/mnystroe/cm3-anon-cvs/cm3 -boot -keep -DM3CC_TARGET=ARMEL_LINUX +++
> --- building in ARMEL_LINUX ---
> 
> 
> Fatal Error: unrecognized target machine: TARGET = ARMEL_LINUX
> 
>  *** execution of [<function _BuildLocalFunction at 0x2aaaab5728c0>] failed ***
> 
> 
 		 	   		   		 	   		  
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://m3lists.elegosoft.com/pipermail/m3devel/attachments/20131014/62f58aba/attachment-0002.html>


More information about the M3devel mailing list