* [Buildroot] [PATCH 1/1] pkg-infra/show-info: dump install_{staging, target} info
@ 2019-07-23 12:33 Vadim Kochan
2019-07-23 12:44 ` Thomas Petazzoni
0 siblings, 1 reply; 5+ messages in thread
From: Vadim Kochan @ 2019-07-23 12:33 UTC (permalink / raw)
To: buildroot
provide info if the package will be installed to staging/target
destinations. Might be useful for analyzing the packages which
installed only for target/staging.
Signed-off-by: Vadim Kochan <vadim4j@gmail.com>
---
package/pkg-utils.mk | 8 ++++++++
1 file changed, 8 insertions(+)
diff --git a/package/pkg-utils.mk b/package/pkg-utils.mk
index b7280e930f..81222565bf 100644
--- a/package/pkg-utils.mk
+++ b/package/pkg-utils.mk
@@ -94,6 +94,14 @@ endef
define _json-info-pkg-details
"version": "$($(1)_DL_VERSION)",
"licenses": "$($(1)_LICENSE)",
+ $(if $($(1)_INSTALL_TARGET), \
+ "install_target": true$(comma),
+ "install_target": false$(comma)
+ )
+ $(if $($(1)_INSTALL_STAGING), \
+ "install_staging": true$(comma),
+ "install_staging": false$(comma)
+ )
"downloads": [
$(foreach dl,$(sort $($(1)_ALL_DOWNLOADS)),
{
--
2.17.1
^ permalink raw reply related [flat|nested] 5+ messages in thread
* [Buildroot] [PATCH 1/1] pkg-infra/show-info: dump install_{staging, target} info
2019-07-23 12:33 [Buildroot] [PATCH 1/1] pkg-infra/show-info: dump install_{staging, target} info Vadim Kochan
@ 2019-07-23 12:44 ` Thomas Petazzoni
2019-07-28 9:56 ` Yann E. MORIN
2019-08-07 7:18 ` Peter Korsgaard
0 siblings, 2 replies; 5+ messages in thread
From: Thomas Petazzoni @ 2019-07-23 12:44 UTC (permalink / raw)
To: buildroot
On Tue, 23 Jul 2019 15:33:55 +0300
Vadim Kochan <vadim4j@gmail.com> wrote:
> provide info if the package will be installed to staging/target
> destinations. Might be useful for analyzing the packages which
> installed only for target/staging.
>
> Signed-off-by: Vadim Kochan <vadim4j@gmail.com>
> ---
> package/pkg-utils.mk | 8 ++++++++
> 1 file changed, 8 insertions(+)
>
> diff --git a/package/pkg-utils.mk b/package/pkg-utils.mk
> index b7280e930f..81222565bf 100644
> --- a/package/pkg-utils.mk
> +++ b/package/pkg-utils.mk
> @@ -94,6 +94,14 @@ endef
> define _json-info-pkg-details
> "version": "$($(1)_DL_VERSION)",
> "licenses": "$($(1)_LICENSE)",
> + $(if $($(1)_INSTALL_TARGET), \
> + "install_target": true$(comma),
> + "install_target": false$(comma)
> + )
> + $(if $($(1)_INSTALL_STAGING), \
> + "install_staging": true$(comma),
> + "install_staging": false$(comma)
> + )
I would prefer install-target and install-staging for the JSON property
names, I prefer - over _.
Also, maybe you can write it like this:
"install-target": $(if $($(1)_INSTALL_TARGET),true,false),
"install-staging": $(if $($(1)_INSTALL_STAGING),true,false),
Note: I haven't thought about whether those properties are actually
useful or not to have in the JSON output. I mainly react to the
implementation details.
Thomas
--
Thomas Petazzoni, CTO, Bootlin
Embedded Linux and Kernel engineering
https://bootlin.com
^ permalink raw reply [flat|nested] 5+ messages in thread
* [Buildroot] [PATCH 1/1] pkg-infra/show-info: dump install_{staging, target} info
2019-07-23 12:44 ` Thomas Petazzoni
@ 2019-07-28 9:56 ` Yann E. MORIN
2019-07-28 10:01 ` Yann E. MORIN
2019-08-07 7:18 ` Peter Korsgaard
1 sibling, 1 reply; 5+ messages in thread
From: Yann E. MORIN @ 2019-07-28 9:56 UTC (permalink / raw)
To: buildroot
On 2019-07-23 14:44 +0200, Thomas Petazzoni spake thusly:
> On Tue, 23 Jul 2019 15:33:55 +0300
> Vadim Kochan <vadim4j@gmail.com> wrote:
>
> > provide info if the package will be installed to staging/target
> > destinations. Might be useful for analyzing the packages which
> > installed only for target/staging.
> >
> > Signed-off-by: Vadim Kochan <vadim4j@gmail.com>
> > ---
> > package/pkg-utils.mk | 8 ++++++++
> > 1 file changed, 8 insertions(+)
> >
> > diff --git a/package/pkg-utils.mk b/package/pkg-utils.mk
> > index b7280e930f..81222565bf 100644
> > --- a/package/pkg-utils.mk
> > +++ b/package/pkg-utils.mk
> > @@ -94,6 +94,14 @@ endef
> > define _json-info-pkg-details
> > "version": "$($(1)_DL_VERSION)",
> > "licenses": "$($(1)_LICENSE)",
> > + $(if $($(1)_INSTALL_TARGET), \
> > + "install_target": true$(comma),
> > + "install_target": false$(comma)
> > + )
> > + $(if $($(1)_INSTALL_STAGING), \
> > + "install_staging": true$(comma),
> > + "install_staging": false$(comma)
> > + )
>
> I would prefer install-target and install-staging for the JSON property
> names, I prefer - over _.
I do too, but Thomas DS. suggested we use _ and that's what we have in
"reverse_depenencies".
> Also, maybe you can write it like this:
>
> "install-target": $(if $($(1)_INSTALL_TARGET),true,false),
> "install-staging": $(if $($(1)_INSTALL_STAGING),true,false),
+1
> Note: I haven't thought about whether those properties are actually
> useful or not to have in the JSON output. I mainly react to the
> implementation details.
I think it is interesting to have.
Regards,
Yann E. MORIN.
--
.-----------------.--------------------.------------------.--------------------.
| Yann E. MORIN | Real-Time Embedded | /"\ ASCII RIBBON | Erics' conspiracy: |
| +33 662 376 056 | Software Designer | \ / CAMPAIGN | ___ |
| +33 561 099 427 `------------.-------: X AGAINST | \e/ There is no |
| http://ymorin.is-a-geek.org/ | _/*\_ | / \ HTML MAIL | v conspiracy. |
'------------------------------^-------^------------------^--------------------'
^ permalink raw reply [flat|nested] 5+ messages in thread
* [Buildroot] [PATCH 1/1] pkg-infra/show-info: dump install_{staging, target} info
2019-07-28 9:56 ` Yann E. MORIN
@ 2019-07-28 10:01 ` Yann E. MORIN
0 siblings, 0 replies; 5+ messages in thread
From: Yann E. MORIN @ 2019-07-28 10:01 UTC (permalink / raw)
To: buildroot
Vadim, Thomas, All,
On 2019-07-28 11:56 +0200, Yann E. MORIN spake thusly:
> On 2019-07-23 14:44 +0200, Thomas Petazzoni spake thusly:
> > On Tue, 23 Jul 2019 15:33:55 +0300
> > Vadim Kochan <vadim4j@gmail.com> wrote:
> > > provide info if the package will be installed to staging/target
> > > destinations. Might be useful for analyzing the packages which
> > > installed only for target/staging.
[--SNIP--]
> > Also, maybe you can write it like this:
> > "install-target": $(if $($(1)_INSTALL_TARGET),true,false),
> > "install-staging": $(if $($(1)_INSTALL_STAGING),true,false),
> +1
And I missed Carlos' reply that this does not work, in fact.
So maybe something like:
$(if $(subst NO,,$($(1)_INSTALL_TARGET)),true,false)
Regards,
Yann E. MORIN.
--
.-----------------.--------------------.------------------.--------------------.
| Yann E. MORIN | Real-Time Embedded | /"\ ASCII RIBBON | Erics' conspiracy: |
| +33 662 376 056 | Software Designer | \ / CAMPAIGN | ___ |
| +33 561 099 427 `------------.-------: X AGAINST | \e/ There is no |
| http://ymorin.is-a-geek.org/ | _/*\_ | / \ HTML MAIL | v conspiracy. |
'------------------------------^-------^------------------^--------------------'
^ permalink raw reply [flat|nested] 5+ messages in thread
* [Buildroot] [PATCH 1/1] pkg-infra/show-info: dump install_{staging, target} info
2019-07-23 12:44 ` Thomas Petazzoni
2019-07-28 9:56 ` Yann E. MORIN
@ 2019-08-07 7:18 ` Peter Korsgaard
1 sibling, 0 replies; 5+ messages in thread
From: Peter Korsgaard @ 2019-08-07 7:18 UTC (permalink / raw)
To: buildroot
>>>>> "Thomas" == Thomas Petazzoni <thomas.petazzoni@bootlin.com> writes:
> On Tue, 23 Jul 2019 15:33:55 +0300
> Vadim Kochan <vadim4j@gmail.com> wrote:
>> provide info if the package will be installed to staging/target
>> destinations. Might be useful for analyzing the packages which
>> installed only for target/staging.
>>
>> Signed-off-by: Vadim Kochan <vadim4j@gmail.com>
>> ---
>> package/pkg-utils.mk | 8 ++++++++
>> 1 file changed, 8 insertions(+)
>>
>> diff --git a/package/pkg-utils.mk b/package/pkg-utils.mk
>> index b7280e930f..81222565bf 100644
>> --- a/package/pkg-utils.mk
>> +++ b/package/pkg-utils.mk
>> @@ -94,6 +94,14 @@ endef
>> define _json-info-pkg-details
>> "version": "$($(1)_DL_VERSION)",
>> "licenses": "$($(1)_LICENSE)",
>> + $(if $($(1)_INSTALL_TARGET), \
>> + "install_target": true$(comma),
>> + "install_target": false$(comma)
>> + )
>> + $(if $($(1)_INSTALL_STAGING), \
>> + "install_staging": true$(comma),
>> + "install_staging": false$(comma)
>> + )
> I would prefer install-target and install-staging for the JSON property
> names, I prefer - over _.
Notice that some programming languages handle json like variables
(object.property.subproperty), and '-' is typically not allowed in
variable names.
--
Bye, Peter Korsgaard
^ permalink raw reply [flat|nested] 5+ messages in thread
end of thread, other threads:[~2019-08-07 7:18 UTC | newest]
Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2019-07-23 12:33 [Buildroot] [PATCH 1/1] pkg-infra/show-info: dump install_{staging, target} info Vadim Kochan
2019-07-23 12:44 ` Thomas Petazzoni
2019-07-28 9:56 ` Yann E. MORIN
2019-07-28 10:01 ` Yann E. MORIN
2019-08-07 7:18 ` Peter Korsgaard
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox