2023-03-05 23:25:53

by Bastian Germann

[permalink] [raw]
Subject: [PATCH 0/1] kbuild: deb-pkg: default dpkg-buildpackage --build

deb-pkg's dpkg-buildpackage invocation was changed in v6.2, unnecessarily
adding the --build parameter explicitly. Revert the change.

Bastian Germann (1):
kbuild: deb-pkg: default dpkg-buildpackage --build

scripts/Makefile.package | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)

--
2.39.2



2023-03-05 23:26:03

by Bastian Germann

[permalink] [raw]
Subject: [PATCH 1/1] kbuild: deb-pkg: default dpkg-buildpackage --build

deb-pkg's dpkg-buildpackage invocation was added --build=source,binary
recently. Before, it relied on the default, which is
--build=source,binary,all and makes no difference for the built packages
as there is no "Arch: all" package.

However, the explicit --build eliminates overriding it via DPKG_FLAGS,
which used to fill the gap of generating only a source package without
building it.

Recover the old, default behavior.

Fixes: 7bf4582d7aad ("kbuild: deb-pkg: create source package without cleaning")
Signed-off-by: Bastian Germann <[email protected]>
---
scripts/Makefile.package | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/scripts/Makefile.package b/scripts/Makefile.package
index b941e6341b36..fe1721915a59 100644
--- a/scripts/Makefile.package
+++ b/scripts/Makefile.package
@@ -120,7 +120,7 @@ debian-orig: linux.tar.gz debian
PHONY += deb-pkg
deb-pkg: debian-orig
+dpkg-buildpackage -r$(KBUILD_PKG_ROOTCMD) -a$$(cat debian/arch) $(DPKG_FLAGS) \
- --build=source,binary -nc -us -uc
+ -nc -us -uc

PHONY += bindeb-pkg
bindeb-pkg: debian
--
2.39.2


2023-03-06 14:38:26

by Nicolas Schier

[permalink] [raw]
Subject: Re: [PATCH 0/1] kbuild: deb-pkg: default dpkg-buildpackage --build

On Mon, Mar 06, 2023 at 12:25:34AM +0100, Bastian Germann wrote:
> deb-pkg's dpkg-buildpackage invocation was changed in v6.2, unnecessarily

v6.3

> adding the --build parameter explicitly. Revert the change.
>
> Bastian Germann (1):
> kbuild: deb-pkg: default dpkg-buildpackage --build
>
> scripts/Makefile.package | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> --
> 2.39.2
>

Masahiro prepared a patch [1] for explicitly introducing a 'srcdeb-pkg'
target, but scheduled its inclusion for v6.4.

Kind regards,
Nicolas

[1]: https://lore.kernel.org/linux-kbuild/CAK7LNAR82ZgvKof9VMXRM4A_h22ZNCyoaKoHW-ONJ+4vctCu_A@mail.gmail.com/T/#m59cc003498dab9b7246198ac3172527256bd1304

2023-03-06 14:42:09

by Bastian Germann

[permalink] [raw]
Subject: Re: [PATCH 0/1] kbuild: deb-pkg: default dpkg-buildpackage --build

Am 06.03.23 um 15:30 schrieb Nicolas Schier:
> On Mon, Mar 06, 2023 at 12:25:34AM +0100, Bastian Germann wrote:
>> deb-pkg's dpkg-buildpackage invocation was changed in v6.2, unnecessarily
>
> v6.3
>
>> adding the --build parameter explicitly. Revert the change.
>>
>> Bastian Germann (1):
>> kbuild: deb-pkg: default dpkg-buildpackage --build
>>
>> scripts/Makefile.package | 2 +-
>> 1 file changed, 1 insertion(+), 1 deletion(-)
>>
>> --
>> 2.39.2
>>
>
> Masahiro prepared a patch [1] for explicitly introducing a 'srcdeb-pkg'
> target, but scheduled its inclusion for v6.4.

Thanks for the pointer. I would still find it nice not to break the use case in 6.3.

>
> Kind regards,
> Nicolas
>
> [1]: https://lore.kernel.org/linux-kbuild/CAK7LNAR82ZgvKof9VMXRM4A_h22ZNCyoaKoHW-ONJ+4vctCu_A@mail.gmail.com/T/#m59cc003498dab9b7246198ac3172527256bd1304

2023-03-06 17:06:30

by Nicolas Schier

[permalink] [raw]
Subject: Re: [PATCH 1/1] kbuild: deb-pkg: default dpkg-buildpackage --build

On Mon, Mar 06, 2023 at 12:25:35AM +0100 Bastian Germann wrote:
> deb-pkg's dpkg-buildpackage invocation was added --build=source,binary
> recently. Before, it relied on the default, which is
> --build=source,binary,all and makes no difference for the built packages
> as there is no "Arch: all" package.
>
> However, the explicit --build eliminates overriding it via DPKG_FLAGS,
> which used to fill the gap of generating only a source package without
> building it.
>
> Recover the old, default behavior.
>
> Fixes: 7bf4582d7aad ("kbuild: deb-pkg: create source package without cleaning")
> Signed-off-by: Bastian Germann <[email protected]>
> ---
> scripts/Makefile.package | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/scripts/Makefile.package b/scripts/Makefile.package
> index b941e6341b36..fe1721915a59 100644
> --- a/scripts/Makefile.package
> +++ b/scripts/Makefile.package
> @@ -120,7 +120,7 @@ debian-orig: linux.tar.gz debian
> PHONY += deb-pkg
> deb-pkg: debian-orig
> +dpkg-buildpackage -r$(KBUILD_PKG_ROOTCMD) -a$$(cat debian/arch) $(DPKG_FLAGS) \
> - --build=source,binary -nc -us -uc
> + -nc -us -uc
>
> PHONY += bindeb-pkg
> bindeb-pkg: debian
> --
> 2.39.2

Reviewed-by: Nicolas Schier <[email protected]>


Attachments:
(No filename) (1.24 kB)
signature.asc (833.00 B)
Download all attachments

2023-03-07 03:21:50

by Masahiro Yamada

[permalink] [raw]
Subject: Re: [PATCH 1/1] kbuild: deb-pkg: default dpkg-buildpackage --build

On Mon, Mar 6, 2023 at 8:25 AM Bastian Germann <[email protected]> wrote:
>
> deb-pkg's dpkg-buildpackage invocation was added --build=source,binary
> recently. Before, it relied on the default, which is
> --build=source,binary,all and makes no difference for the built packages
> as there is no "Arch: all" package.


Is this paragraph true?

--build=source,binary,all sounds strange because
'all' is contained in 'binary'.



According to dpkb-buildpackage(1),

binary = any,all

full = source,binary = source,any,all (default)


--build=source,binary would build everything
even if there were 'Arch: all'.





The code change is fine.
My plan was to use --build=source,binary later,
but I could not finish the entire work in the last cycle.




> However, the explicit --build eliminates overriding it via DPKG_FLAGS,
> which used to fill the gap of generating only a source package without
> building it.
>
> Recover the old, default behavior.
>
> Fixes: 7bf4582d7aad ("kbuild: deb-pkg: create source package without cleaning")
> Signed-off-by: Bastian Germann <[email protected]>
> ---
> scripts/Makefile.package | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/scripts/Makefile.package b/scripts/Makefile.package
> index b941e6341b36..fe1721915a59 100644
> --- a/scripts/Makefile.package
> +++ b/scripts/Makefile.package
> @@ -120,7 +120,7 @@ debian-orig: linux.tar.gz debian
> PHONY += deb-pkg
> deb-pkg: debian-orig
> +dpkg-buildpackage -r$(KBUILD_PKG_ROOTCMD) -a$$(cat debian/arch) $(DPKG_FLAGS) \
> - --build=source,binary -nc -us -uc
> + -nc -us -uc
>
> PHONY += bindeb-pkg
> bindeb-pkg: debian
> --
> 2.39.2
>


--
Best Regards
Masahiro Yamada

2023-03-07 08:44:30

by Bastian Germann

[permalink] [raw]
Subject: Re: [PATCH 1/1] kbuild: deb-pkg: default dpkg-buildpackage --build

Am 07.03.23 um 04:21 schrieb Masahiro Yamada:
> On Mon, Mar 6, 2023 at 8:25 AM Bastian Germann <[email protected]> wrote:
>>
>> deb-pkg's dpkg-buildpackage invocation was added --build=source,binary
>> recently. Before, it relied on the default, which is
>> --build=source,binary,all and makes no difference for the built packages
>> as there is no "Arch: all" package.
>
>
> Is this paragraph true?
>
> --build=source,binary,all sounds strange because
> 'all' is contained in 'binary'.
>
>
>
> According to dpkb-buildpackage(1),
>
> binary = any,all
>
> full = source,binary = source,any,all (default)
>
>
> --build=source,binary would build everything
> even if there were 'Arch: all'.

You are right. The point was that it does not change the output.

>
> The code change is fine.
> My plan was to use --build=source,binary later,
> but I could not finish the entire work in the last cycle.
>
>
>
>
>> However, the explicit --build eliminates overriding it via DPKG_FLAGS,
>> which used to fill the gap of generating only a source package without
>> building it.
>>
>> Recover the old, default behavior.
>>
>> Fixes: 7bf4582d7aad ("kbuild: deb-pkg: create source package without cleaning")
>> Signed-off-by: Bastian Germann <[email protected]>
>> ---
>> scripts/Makefile.package | 2 +-
>> 1 file changed, 1 insertion(+), 1 deletion(-)
>>
>> diff --git a/scripts/Makefile.package b/scripts/Makefile.package
>> index b941e6341b36..fe1721915a59 100644
>> --- a/scripts/Makefile.package
>> +++ b/scripts/Makefile.package
>> @@ -120,7 +120,7 @@ debian-orig: linux.tar.gz debian
>> PHONY += deb-pkg
>> deb-pkg: debian-orig
>> +dpkg-buildpackage -r$(KBUILD_PKG_ROOTCMD) -a$$(cat debian/arch) $(DPKG_FLAGS) \
>> - --build=source,binary -nc -us -uc
>> + -nc -us -uc
>>
>> PHONY += bindeb-pkg
>> bindeb-pkg: debian
>> --
>> 2.39.2
>>
>
>

2023-03-07 11:16:40

by Masahiro Yamada

[permalink] [raw]
Subject: Re: [PATCH 1/1] kbuild: deb-pkg: default dpkg-buildpackage --build

On Tue, Mar 7, 2023 at 5:44 PM Bastian Germann <[email protected]> wrote:
>
> Am 07.03.23 um 04:21 schrieb Masahiro Yamada:
> > On Mon, Mar 6, 2023 at 8:25 AM Bastian Germann <[email protected]> wrote:
> >>
> >> deb-pkg's dpkg-buildpackage invocation was added --build=source,binary
> >> recently. Before, it relied on the default, which is
> >> --build=source,binary,all and makes no difference for the built packages
> >> as there is no "Arch: all" package.
> >
> >
> > Is this paragraph true?
> >
> > --build=source,binary,all sounds strange because
> > 'all' is contained in 'binary'.
> >
> >
> >
> > According to dpkb-buildpackage(1),
> >
> > binary = any,all
> >
> > full = source,binary = source,any,all (default)
> >
> >
> > --build=source,binary would build everything
> > even if there were 'Arch: all'.
>
> You are right. The point was that it does not change the output.
>


How do you want to rephrase this?




--
Best Regards
Masahiro Yamada

2023-03-07 11:20:52

by Bastian Germann

[permalink] [raw]
Subject: [PATCH v2 0/1] kbuild: deb-pkg: default dpkg-buildpackage --build

deb-pkg's dpkg-buildpackage invocation was changed in v6.2, unnecessarily
adding the --build parameter explicitly. Revert the change.

Changelog:
v2:
* Rephrase the commit message not to misrepresent the build options

Bastian Germann (1):
kbuild: deb-pkg: default dpkg-buildpackage --build

scripts/Makefile.package | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)

--
2.39.2