workflows.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] Documentation: changes.rst: add entry for git
@ 2023-08-03  9:07 Rasmus Villemoes
  2023-08-03 10:19 ` Greg KH
  0 siblings, 1 reply; 6+ messages in thread
From: Rasmus Villemoes @ 2023-08-03  9:07 UTC (permalink / raw)
  To: Jonathan Corbet
  Cc: Masahiro Yamada, Linus Torvalds, Rasmus Villemoes, workflows,
	linux-doc, linux-kernel

git is obviously used for development, directly and also
indirectly (via checkpatch, get_maintainer and other helper
scripts). But it is also invoked during the build to produce the
`uname -r` string.

It's useful to have some minimal git version one can expect people to
use. For now, set a somewhat conservative minimum of 1.8.0, which is
already more then ten years old.

Signed-off-by: Rasmus Villemoes <linux@rasmusvillemoes.dk>
---
 Documentation/process/changes.rst | 8 ++++++++
 1 file changed, 8 insertions(+)

diff --git a/Documentation/process/changes.rst b/Documentation/process/changes.rst
index 5561dae94f85..a82c619f4bb2 100644
--- a/Documentation/process/changes.rst
+++ b/Documentation/process/changes.rst
@@ -62,6 +62,7 @@ Sphinx\ [#f1]_         1.7              sphinx-build --version
 cpio                   any              cpio --version
 GNU tar                1.28             tar --version
 gtags (optional)       6.6.5            gtags --version
+git                    1.8.0            git --version
 ====================== ===============  ========================================
 
 .. [#f1] Sphinx is needed only to build the Kernel documentation
@@ -189,6 +190,13 @@ The kernel build requires GNU GLOBAL version 6.6.5 or later to generate
 tag files through ``make gtags``.  This is due to its use of the gtags
 ``-C (--directory)`` flag.
 
+git
+---
+
+When building with CONFIG_LOCALVERSION_AUTO=y, the build system uses
+git to produce a version string of the form
+6.4.6-00128-gd78b7f406397, which will be shown e.g. by running `uname -r`.
+
 System utilities
 ****************
 
-- 
2.37.2


^ permalink raw reply related	[flat|nested] 6+ messages in thread

* Re: [PATCH] Documentation: changes.rst: add entry for git
  2023-08-03  9:07 [PATCH] Documentation: changes.rst: add entry for git Rasmus Villemoes
@ 2023-08-03 10:19 ` Greg KH
  2023-08-04  9:41   ` Masahiro Yamada
  0 siblings, 1 reply; 6+ messages in thread
From: Greg KH @ 2023-08-03 10:19 UTC (permalink / raw)
  To: Rasmus Villemoes
  Cc: Jonathan Corbet, Masahiro Yamada, Linus Torvalds, workflows,
	linux-doc, linux-kernel

On Thu, Aug 03, 2023 at 11:07:10AM +0200, Rasmus Villemoes wrote:
> git is obviously used for development, directly and also
> indirectly (via checkpatch, get_maintainer and other helper
> scripts). But it is also invoked during the build to produce the
> `uname -r` string.
> 
> It's useful to have some minimal git version one can expect people to
> use. For now, set a somewhat conservative minimum of 1.8.0, which is
> already more then ten years old.
> 
> Signed-off-by: Rasmus Villemoes <linux@rasmusvillemoes.dk>
> ---
>  Documentation/process/changes.rst | 8 ++++++++
>  1 file changed, 8 insertions(+)
> 
> diff --git a/Documentation/process/changes.rst b/Documentation/process/changes.rst
> index 5561dae94f85..a82c619f4bb2 100644
> --- a/Documentation/process/changes.rst
> +++ b/Documentation/process/changes.rst
> @@ -62,6 +62,7 @@ Sphinx\ [#f1]_         1.7              sphinx-build --version
>  cpio                   any              cpio --version
>  GNU tar                1.28             tar --version
>  gtags (optional)       6.6.5            gtags --version
> +git                    1.8.0            git --version
>  ====================== ===============  ========================================
>  
>  .. [#f1] Sphinx is needed only to build the Kernel documentation
> @@ -189,6 +190,13 @@ The kernel build requires GNU GLOBAL version 6.6.5 or later to generate
>  tag files through ``make gtags``.  This is due to its use of the gtags
>  ``-C (--directory)`` flag.
>  
> +git
> +---
> +
> +When building with CONFIG_LOCALVERSION_AUTO=y, the build system uses
> +git to produce a version string of the form
> +6.4.6-00128-gd78b7f406397, which will be shown e.g. by running `uname -r`.

Isn't this optional?  If git is not installed it just will not use git
to determine the local version.

So you should put "(optional)" above on the list of tools.

And also, don't pick a specific version like this unless it is that way
for a reason.  Why not pick a newer one?  Or the last one that the local
version script can handle properly?

thanks,

greg k-h

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: [PATCH] Documentation: changes.rst: add entry for git
  2023-08-03 10:19 ` Greg KH
@ 2023-08-04  9:41   ` Masahiro Yamada
  2023-08-04 10:17     ` Greg KH
  0 siblings, 1 reply; 6+ messages in thread
From: Masahiro Yamada @ 2023-08-04  9:41 UTC (permalink / raw)
  To: Greg KH
  Cc: Rasmus Villemoes, Jonathan Corbet, Linus Torvalds, workflows,
	linux-doc, linux-kernel

On Thu, Aug 3, 2023 at 7:19 PM Greg KH <gregkh@linuxfoundation.org> wrote:
>
> On Thu, Aug 03, 2023 at 11:07:10AM +0200, Rasmus Villemoes wrote:
> > git is obviously used for development, directly and also
> > indirectly (via checkpatch, get_maintainer and other helper
> > scripts). But it is also invoked during the build to produce the
> > `uname -r` string.
> >
> > It's useful to have some minimal git version one can expect people to
> > use. For now, set a somewhat conservative minimum of 1.8.0, which is
> > already more then ten years old.
> >
> > Signed-off-by: Rasmus Villemoes <linux@rasmusvillemoes.dk>
> > ---
> >  Documentation/process/changes.rst | 8 ++++++++
> >  1 file changed, 8 insertions(+)
> >
> > diff --git a/Documentation/process/changes.rst b/Documentation/process/changes.rst
> > index 5561dae94f85..a82c619f4bb2 100644
> > --- a/Documentation/process/changes.rst
> > +++ b/Documentation/process/changes.rst
> > @@ -62,6 +62,7 @@ Sphinx\ [#f1]_         1.7              sphinx-build --version
> >  cpio                   any              cpio --version
> >  GNU tar                1.28             tar --version
> >  gtags (optional)       6.6.5            gtags --version
> > +git                    1.8.0            git --version
> >  ====================== ===============  ========================================
> >
> >  .. [#f1] Sphinx is needed only to build the Kernel documentation
> > @@ -189,6 +190,13 @@ The kernel build requires GNU GLOBAL version 6.6.5 or later to generate
> >  tag files through ``make gtags``.  This is due to its use of the gtags
> >  ``-C (--directory)`` flag.
> >
> > +git
> > +---
> > +
> > +When building with CONFIG_LOCALVERSION_AUTO=y, the build system uses
> > +git to produce a version string of the form
> > +6.4.6-00128-gd78b7f406397, which will be shown e.g. by running `uname -r`.
>
> Isn't this optional?  If git is not installed it just will not use git
> to determine the local version.

Right.
Without git, the suffix "-00128-gd78b7f406397" is not
appended, but you can build the kernel.


>
> So you should put "(optional)" above on the list of tools.
>
> And also, don't pick a specific version like this unless it is that way
> for a reason.  Why not pick a newer one?  Or the last one that the local
> version script can handle properly?



CentOS 7 (plans to retire in 2024) unfortunately
uses a ten-year-old git version.

In CentOS 7,

$ git --version
git version 1.8.3.1



Tagger: Junio C Hamano <gitster@pobox.com>
Date:   Mon Jun 10 12:34:56 2013 -0700

Git 1.8.3.1





If we are allowed to abandon conservative distros,
I prefer git >= 2.14.0

That supports 'git status --no-optional-locks'



-- 
Best Regards
Masahiro Yamada

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: [PATCH] Documentation: changes.rst: add entry for git
  2023-08-04  9:41   ` Masahiro Yamada
@ 2023-08-04 10:17     ` Greg KH
  2023-08-05  8:02       ` Masahiro Yamada
  0 siblings, 1 reply; 6+ messages in thread
From: Greg KH @ 2023-08-04 10:17 UTC (permalink / raw)
  To: Masahiro Yamada
  Cc: Rasmus Villemoes, Jonathan Corbet, Linus Torvalds, workflows,
	linux-doc, linux-kernel

On Fri, Aug 04, 2023 at 06:41:54PM +0900, Masahiro Yamada wrote:
> On Thu, Aug 3, 2023 at 7:19 PM Greg KH <gregkh@linuxfoundation.org> wrote:
> >
> > On Thu, Aug 03, 2023 at 11:07:10AM +0200, Rasmus Villemoes wrote:
> > > git is obviously used for development, directly and also
> > > indirectly (via checkpatch, get_maintainer and other helper
> > > scripts). But it is also invoked during the build to produce the
> > > `uname -r` string.
> > >
> > > It's useful to have some minimal git version one can expect people to
> > > use. For now, set a somewhat conservative minimum of 1.8.0, which is
> > > already more then ten years old.
> > >
> > > Signed-off-by: Rasmus Villemoes <linux@rasmusvillemoes.dk>
> > > ---
> > >  Documentation/process/changes.rst | 8 ++++++++
> > >  1 file changed, 8 insertions(+)
> > >
> > > diff --git a/Documentation/process/changes.rst b/Documentation/process/changes.rst
> > > index 5561dae94f85..a82c619f4bb2 100644
> > > --- a/Documentation/process/changes.rst
> > > +++ b/Documentation/process/changes.rst
> > > @@ -62,6 +62,7 @@ Sphinx\ [#f1]_         1.7              sphinx-build --version
> > >  cpio                   any              cpio --version
> > >  GNU tar                1.28             tar --version
> > >  gtags (optional)       6.6.5            gtags --version
> > > +git                    1.8.0            git --version
> > >  ====================== ===============  ========================================
> > >
> > >  .. [#f1] Sphinx is needed only to build the Kernel documentation
> > > @@ -189,6 +190,13 @@ The kernel build requires GNU GLOBAL version 6.6.5 or later to generate
> > >  tag files through ``make gtags``.  This is due to its use of the gtags
> > >  ``-C (--directory)`` flag.
> > >
> > > +git
> > > +---
> > > +
> > > +When building with CONFIG_LOCALVERSION_AUTO=y, the build system uses
> > > +git to produce a version string of the form
> > > +6.4.6-00128-gd78b7f406397, which will be shown e.g. by running `uname -r`.
> >
> > Isn't this optional?  If git is not installed it just will not use git
> > to determine the local version.
> 
> Right.
> Without git, the suffix "-00128-gd78b7f406397" is not
> appended, but you can build the kernel.
> 
> 
> >
> > So you should put "(optional)" above on the list of tools.
> >
> > And also, don't pick a specific version like this unless it is that way
> > for a reason.  Why not pick a newer one?  Or the last one that the local
> > version script can handle properly?
> 
> 
> 
> CentOS 7 (plans to retire in 2024) unfortunately
> uses a ten-year-old git version.
> 
> In CentOS 7,
> 
> $ git --version
> git version 1.8.3.1

I doubt CentOS 7 can build a modern-day kernel anyway, so why is this a
requirement?  We shouldn't be beholden to the necro-distros just because
they have not moved into this decade :)

> If we are allowed to abandon conservative distros,
> I prefer git >= 2.14.0
> 
> That supports 'git status --no-optional-locks'

That makes sense, and is a valid reason to require this.

thanks,

greg k-h

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: [PATCH] Documentation: changes.rst: add entry for git
  2023-08-04 10:17     ` Greg KH
@ 2023-08-05  8:02       ` Masahiro Yamada
  2023-08-05 10:43         ` Tetsuo Handa
  0 siblings, 1 reply; 6+ messages in thread
From: Masahiro Yamada @ 2023-08-05  8:02 UTC (permalink / raw)
  To: Greg KH
  Cc: Rasmus Villemoes, Jonathan Corbet, Linus Torvalds, workflows,
	linux-doc, linux-kernel, Tetsuo Handa

On Fri, Aug 4, 2023 at 7:17 PM Greg KH <gregkh@linuxfoundation.org> wrote:
>
> On Fri, Aug 04, 2023 at 06:41:54PM +0900, Masahiro Yamada wrote:
> > On Thu, Aug 3, 2023 at 7:19 PM Greg KH <gregkh@linuxfoundation.org> wrote:
> > >
> > > On Thu, Aug 03, 2023 at 11:07:10AM +0200, Rasmus Villemoes wrote:
> > > > git is obviously used for development, directly and also
> > > > indirectly (via checkpatch, get_maintainer and other helper
> > > > scripts). But it is also invoked during the build to produce the
> > > > `uname -r` string.
> > > >
> > > > It's useful to have some minimal git version one can expect people to
> > > > use. For now, set a somewhat conservative minimum of 1.8.0, which is
> > > > already more then ten years old.
> > > >
> > > > Signed-off-by: Rasmus Villemoes <linux@rasmusvillemoes.dk>
> > > > ---
> > > >  Documentation/process/changes.rst | 8 ++++++++
> > > >  1 file changed, 8 insertions(+)
> > > >
> > > > diff --git a/Documentation/process/changes.rst b/Documentation/process/changes.rst
> > > > index 5561dae94f85..a82c619f4bb2 100644
> > > > --- a/Documentation/process/changes.rst
> > > > +++ b/Documentation/process/changes.rst
> > > > @@ -62,6 +62,7 @@ Sphinx\ [#f1]_         1.7              sphinx-build --version
> > > >  cpio                   any              cpio --version
> > > >  GNU tar                1.28             tar --version
> > > >  gtags (optional)       6.6.5            gtags --version
> > > > +git                    1.8.0            git --version
> > > >  ====================== ===============  ========================================
> > > >
> > > >  .. [#f1] Sphinx is needed only to build the Kernel documentation
> > > > @@ -189,6 +190,13 @@ The kernel build requires GNU GLOBAL version 6.6.5 or later to generate
> > > >  tag files through ``make gtags``.  This is due to its use of the gtags
> > > >  ``-C (--directory)`` flag.
> > > >
> > > > +git
> > > > +---
> > > > +
> > > > +When building with CONFIG_LOCALVERSION_AUTO=y, the build system uses
> > > > +git to produce a version string of the form
> > > > +6.4.6-00128-gd78b7f406397, which will be shown e.g. by running `uname -r`.
> > >
> > > Isn't this optional?  If git is not installed it just will not use git
> > > to determine the local version.
> >
> > Right.
> > Without git, the suffix "-00128-gd78b7f406397" is not
> > appended, but you can build the kernel.
> >
> >
> > >
> > > So you should put "(optional)" above on the list of tools.
> > >
> > > And also, don't pick a specific version like this unless it is that way
> > > for a reason.  Why not pick a newer one?  Or the last one that the local
> > > version script can handle properly?
> >
> >
> >
> > CentOS 7 (plans to retire in 2024) unfortunately
> > uses a ten-year-old git version.
> >
> > In CentOS 7,
> >
> > $ git --version
> > git version 1.8.3.1
>
> I doubt CentOS 7 can build a modern-day kernel anyway, so why is this a
> requirement?  We shouldn't be beholden to the necro-distros just because
> they have not moved into this decade :)



The default GCC on CentOS 7 is GCC 4.8,
which is too old to build the kernel.

I am not so sure how RHEL/CentOS 7 users are working
on the kernel development, but it is possible to
install a newer gcc version from Developer Toolset.


FWFW, this is how to set up GCC 11 on CentOS 7
so you can build the kernel.

# yum install centos-release-scl
# yum install devtoolset-11-gcc
$ PATH=/opt/rh/devtoolset-11/root/usr/bin:$PATH
$ gcc --version
gcc (GCC) 11.2.1 20220127 (Red Hat 11.2.1-9)
Copyright (C) 2021 Free Software Foundation, Inc.
This is free software; see the source for copying conditions.  There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.






Recently, I got a regression report on RHEL/CentOS 7.
So, some people might still care about this.





commit f5983dab0ead92dc2690d147f0604a0badcac6a8
Author: Masahiro Yamada <masahiroy@kernel.org>
Date:   Wed Jun 28 01:32:05 2023 +0900

    modpost: define more R_ARM_* for old distributions

    On CentOS 7, the following build error occurs.








-- 
Best Regards
Masahiro Yamada

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: [PATCH] Documentation: changes.rst: add entry for git
  2023-08-05  8:02       ` Masahiro Yamada
@ 2023-08-05 10:43         ` Tetsuo Handa
  0 siblings, 0 replies; 6+ messages in thread
From: Tetsuo Handa @ 2023-08-05 10:43 UTC (permalink / raw)
  To: Masahiro Yamada, Greg KH
  Cc: Rasmus Villemoes, Jonathan Corbet, Linus Torvalds, workflows,
	linux-doc, linux-kernel

On 2023/08/05 17:02, Masahiro Yamada wrote:
>>>>> It's useful to have some minimal git version one can expect people to
>>>>> use. For now, set a somewhat conservative minimum of 1.8.0, which is
>>>>> already more then ten years old.

No problem with requiring git >= 1.8.0.

> 
> The default GCC on CentOS 7 is GCC 4.8,
> which is too old to build the kernel.
> 
> I am not so sure how RHEL/CentOS 7 users are working
> on the kernel development, but it is possible to
> install a newer gcc version from Developer Toolset.

CentOS 7 users can install a newer git version as well as gcc.

> commit f5983dab0ead92dc2690d147f0604a0badcac6a8
> Author: Masahiro Yamada <masahiroy@kernel.org>
> Date:   Wed Jun 28 01:32:05 2023 +0900
> 
>     modpost: define more R_ARM_* for old distributions
> 
>     On CentOS 7, the following build error occurs.

It is glibc-headers-2.17-326.el7_9 package. Neither gcc nor git problem.


^ permalink raw reply	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2023-08-05 10:44 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2023-08-03  9:07 [PATCH] Documentation: changes.rst: add entry for git Rasmus Villemoes
2023-08-03 10:19 ` Greg KH
2023-08-04  9:41   ` Masahiro Yamada
2023-08-04 10:17     ` Greg KH
2023-08-05  8:02       ` Masahiro Yamada
2023-08-05 10:43         ` Tetsuo Handa

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).