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:   Fri, 30 Jul 2021 13:38:46 -0400
From:   John S Gruber <johnsgruber@...il.com>
To:     Masahiro Yamada <masahiroy@...nel.org>
Cc:     linux-kbuild@...r.kernel.org,
        Michal Marek <michal.lkml@...kovi.net>,
        linux-kernel@...r.kernel.org
Subject: Re: [PATCH] kbuild: cancel sub_make_done for the install target to
 fix DKMS

On Wed, Jul 28, 2021 at 8:13 PM Masahiro Yamada <masahiroy@...nel.org> wrote:
>
> Since commit bcf637f54f6d ("kbuild: parse C= and M= before changing the
> working directory"), external modules invoked by DKMS fail to build
> because M= option is not parsed.
>
> I wanted to add 'unset sub_make_done' in install.sh but similar scripts,
> arch/*/boot/install.sh, are duplicated, so I set sub_make_done empty
> in the top Makefile.
>
> Fixes: bcf637f54f6d ("kbuild: parse C= and M= before changing the working directory")
> Reported-by: John S Gruber <johnsgruber@...il.com>
> Signed-off-by: Masahiro Yamada <masahiroy@...nel.org>
> ---
>
>  Makefile | 10 ++++++++++
>  1 file changed, 10 insertions(+)
>
> diff --git a/Makefile b/Makefile
> index bb10a93edf5c..4193092f7c38 100644
> --- a/Makefile
> +++ b/Makefile
> @@ -1316,6 +1316,16 @@ PHONY += scripts_unifdef
>  scripts_unifdef: scripts_basic
>         $(Q)$(MAKE) $(build)=scripts scripts/unifdef
>
> +# ---------------------------------------------------------------------------
> +# Install
> +
> +# Many distros have the custom install script, /sbin/kernelinstall.
> +# If DKMS is installed, 'make install' will eventually recuses back
> +# to the this Makefile to build and install external modules.
> +# Cancel sub_make_done so that options such as M=, V=, etc. are parsed.
> +
> +install: sub_make_done=
> +
>  # ---------------------------------------------------------------------------
>  # Tools
>
> --
> 2.27.0
>

This patch tested successfully on my system on 5.14.0-rc3.

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ