git/list[1] front-page[2] threads[3] people[4] search[5] about
 

Re: [PATCH] Makefile: generate Git(3pm) as dependency of the 'doc' and 'man' targets

From
Junio C Hamano <gitster@pobox.com>
Date
Feb 15, 2018, 18:05 UTC
Message-ID
<xmqqo9kq9lii.fsf@gitster-ct.c.googlers.com>
In-Reply-To
<87vaeyfxdu.fsf@evledraar.gmail.com>
Ævar Arnfjörð Bjarmason <avarab@gmail.com> writes:
Show 25 quoted lines
> On Thu, Feb 15 2018, SZEDER Gábor jotted:
>
>> Since commit 20d2a30f8f (Makefile: replace perl/Makefile.PL with
>> simple make rules, 2017-12-10), the Git(3pm) man page is only
>> generated as an indirect dependency of the 'install-doc' and
>> 'install-man' Makefile targets.  Consequently, if someone runs 'make
>> man && sudo make install-man' (or their 'doc' counterparts), then
>> Git(3pm) will be generated as root, and the resulting root-owned files
>> and directories will in turn cause the next user-run 'make clean' to
>> fail.  This was not an issue in the past, because Git(3pm) was
>> generated when 'make all' descended into 'perl/', which is usually not
>> run as root.
>>
>> List Git(3pm) as a dependency of the 'doc' and 'man' Makefile targets,
>> too, so it gets generated by targets that are usually built as
>> ordinary users.
>>
>> While at it, add 'install-man-perl' to the list of .PHONY targets.
>
> Thanks for the fixup of my crappy 'make' skills. I tested this before
> the patch and it indeed has the problem you describe, and this fixes
> it. Thanks! CC-ing Junio because I think it makes sense to pick this up
> as-is.
>
> Reviewed-by: Ævar Arnfjörð Bjarmason <avarab@gmail.com>
Thanks.  

It is better late than never to have fixes like this, but I am a bit disturbed to notice that for the last few batches, we see fixes to topics after they land 'master', not while they are in 'next'.

Will apply.
Previous: Ævar Arnfjörð Bjarmason
Message 3 of 3 in “Makefile: generate Git(3pm) as dependency of the 'doc' and 'man' targets”
  1. Makefile: generate Git(3pm) as dependency of the 'doc' and 'man' targetsSZEDER Gábor, Feb 15, 2018
  2. Ævar Arnfjörð BjarmasonFeb 15, 2018
  3. Junio C HamanoFeb 15, 2018

Read the whole thread, see it on lore, or plain text.

$ cat FOOTERMessages come from the public archive at lore.kernel.org/git, fetched every hour. The front page is chosen and written each morning by an AI editor and can be wrong; the threads themselves are the record. About and API. For agents: an MCP server at https://gitlist.dev/mcp, and any thread, story or person page as Markdown by adding .md to its URL (or sending Accept: text/markdown). Details in /llms.txt.