http://qs1969.pair.com?node_id=11139705


in reply to How to do a true cross compilation

I believe your understanding of cross-compiling is flawed. What it actually means is that you compile code for a target that's different than the native architecture. For example, I wrote C on a VAX 11/780 that was cross-compiled to 68000 assembler, and then downloaded to the target system (yeah, OK, it was the early 80's).

If you're compiling on the local system for use on that system .. that's not cross-compiling.

I imagine that there are tools that will cross-compile for iOS on other architectures -- then all you need to do is to load that executable on the target system, possibly by creating an iOS app. I don't actually know about any of this -- I'm just hand-waving at this point.

Alex / talexb / Toronto

Thanks PJ. We owe you so much. Groklaw -- RIP -- 2003 to 2013.

Replies are listed 'Best First'.
Re^2: How to do a true cross compilation
by Joride (Initiate) on Dec 18, 2021 at 17:15 UTC
    I see what you are saying Alex, thank you for your quick response. Your description of cross compiling matches my understanding (but I can see how my write up could have been more clear). However, my understanding of Perl's way of 'cross compiling' is different, and consists of 2 steps: First, build something called 'miniperl'. This miniperl is then supposed to be transferred to the target machine, where miniperl will then build actual Perl. Of course, in your explanation, only the first step would be cross-compiling: building on macos (x86_64) for a machine (iPhone) running arm64. So I am hoping there is a way to cross-compile Perl in the way you described, without having to transfer minperl (or any access at all before building) to the target machine/system. And maybe my understanding of Perl-specific cross compilation is flawed of incomplete too, I found quite some information on the topic, but mostly not in agreement with each other.