On 30.01.2012 18:44, steve smithers wrote:
michael.vancann...@wisa.be wrote the following on 30/01/12 17:35

I had in mind the following scenario:

1) Somehow we build - using cross-compilation - a first version of the
  compiler that actually runs on the 370. This binary is transferred to a
  370 machine.

I haven't got that far in my notes yet but...  Cross-compilation - yes.
Building a 370 binary on Linux or Windows - Well you can if you want but...
Transfer binary to a 370 machine - Whew.  This is problematic.

It's not any problem to move the binary itself, but there is more required
than the binary itself in order to produce an executable load module on any
OS version.  (I can't comment on VM or DOS cause they are a mystery to me).
An OS binary consists of more than the binary and I know of no way to build
that information on Linux or Windows.

I would very strongly suggest cross-compile fpc on Linux/Windows using a version
that emits, not gas assembler but 370 assembler.  I will be talking about gas vs
370 assembler later.  The assembler output can be in ASCII or EBCDIC as rvmartin
said it's just a character encoding.  The advantage is that you only need to
upload a text file(s).  Feed it into the OS assembler and link programs and you
have a 370 load module.

Once a initial port to 370 has been made and the assembler output generator is implemented (which means that the compiler can basically generate 370 capable assembler files) this is rather easy as FPC can generate "link on target" scripts (and AFAIK also "assemble on target").

2) The sources of the compiler and RTL are transferred to the 370.
  I assume that after the file transfer, the sources are still in ASCII format ?

It depends on the options you use on your file transfer program, but I would
convert to EBCDIC here.

Not at the first step. As long as FPC is not able to understand EBCDIC there is no sense in converting the source to EBCDIC.

Regards,
Sven
_______________________________________________
fpc-devel maillist  -  fpc-devel@lists.freepascal.org
http://lists.freepascal.org/mailman/listinfo/fpc-devel

Reply via email to