All of lore.kernel.org
 help / color / mirror / Atom feed
From: Titouan Christophe <titouan.christophe@railnova.eu>
To: buildroot@busybox.net
Subject: [Buildroot] [PATCH 1/1] package/gst1-validate: allow to use host-python3 and target python3
Date: Tue, 29 Oct 2019 00:19:05 +0100	[thread overview]
Message-ID: <43afbd16-d440-0552-0148-288cbb75ffb5@railnova.eu> (raw)
In-Reply-To: <79878267-e1f5-e992-985b-46d50c18e687@mind.be>

Good evening Arnout,


On 10/28/19 11:35 PM, Arnout Vandecappelle wrote:
> 
> 
> On 28/10/2019 12:15, Titouan Christophe wrote:
>> +++ b/package/gstreamer1/gst1-validate/Config.in
>> @@ -1,9 +1,10 @@
>>   config BR2_PACKAGE_GST1_VALIDATE
>>   	bool "gst1-validate"
>> -	depends on BR2_PACKAGE_PYTHON
>> +	depends on BR2_PACKAGE_PYTHON || BR2_PACKAGE_PYTHON3
> 
>   Not directly related to this patch, but it would be better to use a select
> instead of a depends here. 'depends' is for packages that are really
> Python-related. 'select' is for when it's a package that just happens to be
> implemented in python, like e.g. dstat. The boundary is sometimes a bit thin,
> but I think in this case it's clearly the latter. But anyway, that's a separate
> patch.

Ok

> 
>>   	select BR2_PACKAGE_GST1_PLUGINS_BASE
>>   	select BR2_PACKAGE_JSON_GLIB
>> -	select BR2_PACKAGE_PYTHON_PYEXPAT
>> +	select BR2_PACKAGE_PYTHON_PYEXPAT if BR2_PACKAGE_PYTHON
>> +	select BR2_PACKAGE_PYTHON3_PYEXPAT if BR2_PACKAGE_PYTHON3
> 
>   There is no python3-pyexpat package. Target packages will automatically use the
> python3 version if python3 is selected for the target. It is only when a
> python3-only host package depends on some module that we need those python3-foo
> packages.

Then, there is something I probably do not understand well:

$ git grep BR2_PACKAGE_PYTHON3_PYEXPAT | wc -l
20

> 
>>   	# cairo is autodetected but needs PNG support
>>   	select BR2_PACKAGE_CAIRO_PNG if BR2_PACKAGE_CAIRO
>>   	help
>> @@ -15,3 +16,4 @@ config BR2_PACKAGE_GST1_VALIDATE
>>   
>>   comment "gst1-validate depends on python"
>>   	depends on !BR2_PACKAGE_PYTHON
>> +	depends on !BR2_PACKAGE_PYTHON3
> 
>   Although correct, we typically write this as
> 
> 	depends on !(BR2_PACKAGE_PYTHON || BR2_PACKAGE_PYTHON3)

I already submitted some accepted patche(s?) that had the 2 "depends on" 
form, for instance supervisor. Is there a style guide somewhere I could 
follow ?

(IMHO, the 2 lines form is prettier and easier to understand for humans 
and diffs, but this is definitely a matter of taste </my2cents>)

> 
>   Regards,
>   Arnout

Best regards,

Titouan

  reply	other threads:[~2019-10-28 23:19 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-10-28 11:15 [Buildroot] [PATCH 1/1] package/gst1-validate: allow to use host-python3 and target python3 Titouan Christophe
2019-10-28 22:35 ` Arnout Vandecappelle
2019-10-28 23:19   ` Titouan Christophe [this message]
2019-10-29  8:59     ` Arnout Vandecappelle

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=43afbd16-d440-0552-0148-288cbb75ffb5@railnova.eu \
    --to=titouan.christophe@railnova.eu \
    --cc=buildroot@busybox.net \
    /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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.