Andy Wingo <[email protected]> writes:
> On Sat 05 Mar 2011 20:47, Neil Jerram <[email protected]> writes:
>
>> In principle, how should Guile 2.0 be cross-compiled? I'm thinking
>> mostly of the part of the build that compiles all the installed
>> modules.
>
> I have never cross-compiled anything, so I really don't know.
>
> Ideally we could make a cross-compiling Guile that executed on the host,
> but produced .go files for the target.
>
> Hummmmmm. Does that mean that for cross-compile builds, that we should
> not add the $builddir to the LOAD_COMPILED_PATH? Probably so, right? A
> cross-compiler probably doesn't autocompile either. So then the
> cross-compiler receives as its inputs the source files from a project,
> then produces .go files for the target, but does not load .go files from
> the target.
>
> Does that sound right to you?
Thanks for your input on this.
Yes. In principle I think the cross-compiler could simultaneously
auto-compile, for itself, and non-auto-compile for the target, but
that's a bit mind-blowing and would require careful handling of what's
being written and read from where. Instead of that, we could do two
separate steps: one where the cross-compiler compiles for itself, and
one to compile for the target.
What architectural dependencies are there in the .go format? If there
aren't too many, a cross-compiler is probably the nicest solution,
because the other two options (QEMU, and compiling after installation on
the target) are probably going to be ridiculously slow.
Neil