tech-pkg archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

Re: PYTHONBIN for cross-compilation to different LOCALBASE

Taylor R Campbell <> writes:

> USE_TOOLS+=python isn't a thing (and the USE_TOOLS framework itself
> poses a difficulty with TOOLBASE/LOCALBASE split, with things like

Sure, but I think we're heading that way?

> USE_TOOLS+=sed vs USE_TOOLS+=sed:run, to be addressed separately).

I suspect we need to separate TOOLS into build (cross) and run (target),
and make people express both if that's how it is.  I think right now
:run sort of implies "at build and also at run".

> As you note, many Python packages use Python at build-time (e.g., to
> run _and_ at run-time (e.g., in #! lines), via just
> or  These are the ones that need two
> variables to make the distinction.
> Question is, which use of the existing PYTHONBIN variable is more
> prevalent?

Part of this is what is more prevalent, but also about consistency
naming in the brave new world of full cross.

> Hoping to get a sense of this before committing to a new variable
> scheme that ends up requiring a mass-change later like my mistake with

Sure, but maybe we need to have a plan for whether TOOL means build
only, vs how we talk about runtime, and evaluate the whole plan, in
order to get a logically consistent naming scheme.  I see mass renames
as less harmful than confusing names in the long term.

I guess the first thing to detangle is the difference between
TOOL_DEPENDS and USE_TOOLS.   The basic issue is that we have blurred a
mechanism for naming and finding an adequate implementation of something
with the distinction of whether it needs to be present for the build or
at runtime.

If TOOL_DEPENDS is at build, then perhaps we should add


to express that the tool must be available at runtime.  Which is sort
of like just DEPENDS, which can already end up resolving to a builtin.
It is striking me that USE_TOOLS and DEPENDS/builtin are different
mechanisms that are mostly doing the same thing.

Home | Main Index | Thread Index | Old Index