public inbox for gentoo-python@lists.gentoo.org
 help / color / mirror / Atom feed
From: Mike Gilbert <floppym@gentoo.org>
To: "Michał Górny" <mgorny@gentoo.org>
Cc: gentoo-python <gentoo-python@lists.gentoo.org>,
	 Gentoo Python Project <python@gentoo.org>
Subject: [gentoo-python] Re: The future of PYTHON_SINGLE_TARGET
Date: Sun, 30 Nov 2014 13:12:18 -0500	[thread overview]
Message-ID: <CAJ0EP42VaZr+bQDsEQbV8E=5p0W0fdH0GpKs1yhaeEyaUcjjjA@mail.gmail.com> (raw)
In-Reply-To: <20141128235927.771a6e8b@pomiot.lan>

On Fri, Nov 28, 2014 at 5:59 PM, Michał Górny <mgorny@gentoo.org> wrote:
> Friends!
>
> The current state of python-single-r1 bothered me a lot lately,
> and while _AxS_ did some neat improvements to the eclass, it's still
> far from perfect solution to our users.
>
> The PYTHON_SINGLE_TARGET flags were added to make it easier to handle
> single-impl packages that support both Python 2 & Python 3 which we
> enable both in our profiles. It serves that purpose well -- however, it
> isn't that good for single-impl packages that don't support the most
> common choice of implementations.
>
> In particular, it has two major issues:
>
> 1. We have no sane, clear and universal way of providing users with
> sensible defaults. It's always one trade-off over another.
>
> 2. Matching USE dependencies against multi-impl packages introduces
> a second set of USE flags (PYTHON_TARGETS) that are semi-virtual.
> Sadly, they introduce confusion and cause issues.
>
>
> As far as the first issue is concerned, I think enough has been said
> already. Right now we are fine-tuned for two cases:
>
> a. packages that support one impl only -- then they have a single
> PYTHON_TARGET that's enabled by default,
>
> b. packages that support python2.7 -- then we have the profile default
> of python2.7 for them.
>
> We have no good way of handling packages that support Python 3 only.
>

I'm thinking we need to move the default PYTHON_SINGLE_TARGET setting
from profiles to IUSE defaults computed in the eclass.

What are the problems associated with that?

>
> The other issue comes into game in two cases I've seen:
>
> A. when we try to improve setting of PYTHON_SINGLE_TARGET, we force
> the user to enable matching PYTHON_TARGET anyway -- so in the end
> manual intervention is required,

That would seem to be the exception rather than the norm. This would
only happen if we somehow defaulted PYTHON_SINGLE_TARGET to something
that is not in PYTHON_TARGETS by default. How would that ever happen?

> B. they cause issues with REQUIRED_USE on other packages (like libpeas
> that supports only one version of python2 and one of python3). Even
> though PYTHON_SINGLE_TARGET results in effective use of a single impl,
> PYTHON_TARGET USE-dep requests full PYTHON_TARGETS match on the dep.
> Therefore, the user needs to disable other implementations anyway to
> get the expected result.

I don't understand this part. Can you please explain it? Maybe an example?

> So, what are your thoughts? What are your solutions?

I don't really understand the problems well enough to propose
solutions. Hopefully answering my questions above will help with that.


  reply	other threads:[~2014-11-30 18:12 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-11-28 22:59 [gentoo-python] The future of PYTHON_SINGLE_TARGET Michał Górny
2014-11-30 18:12 ` Mike Gilbert [this message]
2014-11-30 20:50   ` [gentoo-python] " Michał Górny
2014-11-30 21:02     ` Mike Gilbert
2014-11-30 21:20       ` Michał Górny

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to='CAJ0EP42VaZr+bQDsEQbV8E=5p0W0fdH0GpKs1yhaeEyaUcjjjA@mail.gmail.com' \
    --to=floppym@gentoo.org \
    --cc=gentoo-python@lists.gentoo.org \
    --cc=mgorny@gentoo.org \
    --cc=python@gentoo.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox