rattler-build icon indicating copy to clipboard operation
rattler-build copied to clipboard

docs: Update to reference `host_platform` instead of `target_platform`

Open mgorny opened this issue 9 months ago • 5 comments

Update the documentation throughout to replace the references to target_platform with host_platform where appropriate. That said, unless I've missed some fine point, this means pretty much everywhere.

mgorny avatar Mar 17 '25 18:03 mgorny

Thanks for the changes! I am wondering which one is "clearer" to the user ... target_platform or host_platform?

wolfv avatar Mar 18 '25 10:03 wolfv

I think cross-builds are inherently "hard" difficulty, and all terms are hard. In Gentoo, I personally went for explicit CBUILD, CHOST, CTARGET to avoid ambiguity.

mgorny avatar Mar 18 '25 10:03 mgorny

This change was basically prompted by https://github.com/regro/cf-scripts/pull/3832#issuecomment-2706852422

mgorny avatar Mar 18 '25 10:03 mgorny

Thanks for the changes! I am wondering which one is "clearer" to the user ... target_platform or host_platform?

@isuruf has been making the case for following build/host/target (and fixing conda's inconsistent usage of these terms). This matches autotools conventions, but not only. For example, I like meson's write-up on this topic, which comes to the same conclusion.

The "problem" is that the vast majority of cross-compiled cases (already not the most common concern itself) only care about two architectures - where it's built and where it's run. But if you use "target" for the latter, it becomes very confusing in those cases where the full generality is actually necessary (e.g. "canadian cross" compilers).

This is, for example, why our compiler feedstocks need to hack around this by using cross_target_platform, because conda-build uses target_platform for what should be host_platform.

In short: I agree that we should use v1 as an opportunity to clean up these inaccuracies, and +1 for using host_platform.

h-vetinari avatar Mar 21 '25 23:03 h-vetinari

I think the easiest way to explain to users is

  1. build_platform is the platform for requirements/build
  2. host_platform is the platform for requirements/host.
  3. target_platform is for advanced users (compiler package authors) only.

isuruf avatar Mar 25 '25 18:03 isuruf