On Fri, Feb 14, 2025 at 02:20:50PM +0100, Erez wrote:
> My real question is why do we have gcc-14-aarch64-linux-gnu:arm64 in the
> pool?

It's the native compiler used for natively building arm64 packages.
Without it, we cannot build any packages on arm64.

> Cross compilers using the same host and target architecture are not really
> cross.

It's not a cross compiler. It's a native compiler.

> In plain English this package (and similar to this) should not be in the
> pool.

Of course it should. Removing it amounts to removing the entire arm64
architecture.

> When building the cross compilers, the target and the host should not be
> identical.

I suppose the problem you are facing here is that Debian now blends the
cross and native toolchains together. There is gcc-14-aarch64-linux-gnu
as a package name and it says that it is building for aarch64-linux-gnu.
What it does not say is whether that's done using a cross or native
compiler. From a packaging dependency pov, you no longer can depend on a
cross toolchain. You merely can depend on a toolchain targeting a
particular architecture.

Of course you usually don't want the native toolchain for a foreign
architecture. If a package is declared M-A:foreign (such as is the case
with toolchains), you usually want the native one. You can tell apt
about this:

    APT::BarbarianArchitectures {"arm64"};

Once you do it, it'll refuse installing gcc-14-aarch64-linux-gnu:arm64,
but still allow installing gcc-14-aarch64-linux-gnu:amd64 which really
is a cross toolchain.

Helmut

Reply via email to