On 2023-03-01, anonymous <invalid.nore...@gnu.org> wrote:
> This might be the desired use case, but when cross compiling with
> systems like buildroot one might have the same architecture on
> --build and --host.
>
> Example: Compile on Apple silicon (aarch64-unknown-linux-gnu) for a Cortex
> A75 based system (aarch64-unknown-linux-gnu). Cross compiling isn't
> automatically detected.

By setting --host and --build to the same value, this explicitly forces
non-cross-compilation mode in configure.

If you specify --host without also specifying --build, then configure will
run the auto-detection which I expect will work properly for you.

Probably the "vendor" field of the host triplet should have been set to
something different for these different systems, but I digress...

> And there seems to be no way to force it if we know that we are cross
> compiling.

Nevertheless, you can always force cross compilation mode by explicitly
setting cross_compiling=yes, for example:

  % ./configure cross_compiling=yes

Hope that helps,
  Nick

Reply via email to