lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:   Tue, 18 Apr 2023 10:17:42 +0900
From:   Masahiro Yamada <masahiroy@...nel.org>
To:     Ben Hutchings <ben@...adent.org.uk>
Cc:     linux-kbuild@...r.kernel.org, linux-kernel@...r.kernel.org,
        Bastian Germann <bage@...utronix.de>,
        Nicolas Schier <nicolas@...sle.eu>,
        Nathan Chancellor <nathan@...nel.org>,
        Nick Desaulniers <ndesaulniers@...gle.com>
Subject: Re: [PATCH 1/2] kbuild: add srcdeb-pkg target

On Mon, Apr 17, 2023 at 11:52 PM Ben Hutchings <ben@...adent.org.uk> wrote:
>
> On Mon, 2023-04-17 at 23:25 +0900, Masahiro Yamada wrote:
> > This new target builds only the debian source package.
> >
> > Unify the build rules of deb-pkg, srcdeb-pkg, bindeb-pkg to avoid
> > code duplication.
> >
> > Signed-off-by: Masahiro Yamada <masahiroy@...nel.org>
> > Reviewed-by: Nicolas Schier <nicolas@...sle.eu>
> > ---
> [...]
> >  bindeb-pkg: debian
> > -     +dpkg-buildpackage -r$(KBUILD_PKG_ROOTCMD) -a$$(cat debian/arch) $(DPKG_FLAGS) -b -nc -uc
> > +deb-pkg srcdeb-pkg bindeb-pkg:
> > +     +$(strip dpkg-buildpackage \
> > +     --build=$(build-type) --no-pre-clean --unsigned-changes \
> > +     $(if $(findstring source, $(build-type)), \
> > +             --unsigned-source) \
> > +     $(if $(findstring binary, $(build-type)), \
> > +             -r$(KBUILD_PKG_ROOTCMD) -a$$(cat debian/arch), \
> > +             --no-check-builddeps) \
> [...]
>
> There is no need to make the use of --unsigned-source (-us) or -r
> conditional on the build type.  They will be ignored if not applicable.



True, but you can also say there is no need
to pass options that we know are unnecessary.


My motivation is to make unneeded options
really don't-care.



2/2 will add KDEB_SOURCE_COMPRESS.

If I do not make it optional,
"KDEB_SOURCE_COMPRESS=foo make bindeb-pkg"
would fail.




dpkg-buildpackage --build=binary --no-pre-clean --unsigned-changes
--unsigned-source --compression=foo -r'fakeroot -u' -a$(cat
debian/arch)
dpkg-buildpackage: info: source package linux-upstream
dpkg-buildpackage: info: source version 6.3.0-rc7-00003-geb58366b57fe-33
dpkg-buildpackage: info: source distribution kinetic
dpkg-buildpackage: info: source changed by Masahiro Yamada
<masahiro.yamada@...onical.com>
dpkg-buildpackage: info: host architecture amd64
 dpkg-source --compression=foo --before-build .
dpkg-source: error: foo is not a supported compression

Use --help for program usage information.





"dpkg-buildpackage --build=binary" does not
generate a source package, but still checks
if --compression=foo is correct.



> This is also adding --no-check-builddeps (-d), which is not explained
> in the commit message.  It might be valid to add this for srcdeb-pkg,
> but the build dependency check is valuable for bindeb-pkg and deb-pkg.


Yes.
So, I added --no-check-builddeps to the else arm.



I will add the following commit description:


--no-check-builddeps is added to srcbin-pkg
so that build dependencies will not be checked.





>
> Ben.
>
> --
> Ben Hutchings
> Sturgeon's Law: Ninety percent of everything is crap.



-- 
Best Regards
Masahiro Yamada

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ