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

Re: [PATCH 1/1] perl: fix installing modules from contrib

From
Junio C Hamano <gitster@pobox.com>
Date
Apr 9, 2018, 04:54 UTC
Message-ID
<xmqqpo39569k.fsf@gitster-ct.c.googlers.com>
In-Reply-To
<87tvssva2c.fsf@evledraar.gmail.com>
Ævar Arnfjörð Bjarmason <avarab@gmail.com> writes:
>>
>> +perllibdir:
>> +	@echo $(perllibdir_SQ)

This use of _SQ variant is fishy, isn't it? Judging from the output of

    $ git grep _SQ Makefile
e.g.
    Makefile:	$(INSTALL) $^ '$(DESTDIR_SQ)$(gitexec_instdir_SQ)'
    Makefile:	$(INSTALL) $^ '$(DESTDIR_SQ)$(gitexec_instdir_SQ)'
    Makefile:	$(INSTALL) $^ '$(DESTDIR_SQ)$(gitexec_instdir_SQ)'

I'd expect that any _SQ variant must be referenced inside a single quote pair. In fact, that is why a single quote (and nothing else) in the base variable is replaced with the magic "'\''" sequence, first stepping out of the current sq context, append a single sq (escaped with a backslash from the shell), and then stepping back into another sq context.

I think nobody saw breakage only because they do not have two consecutive SPs (or any single quote) in their path to $perllibdir. If we depend on such limitation, there is no point using _SQ variant, but we already have _SQ variant, let's use it correctly.

Previous: Ævar Arnfjörð BjarmasonNext: Christian Hesse
Message 3 of 8 in “perl: fix installing modules from contrib”
  1. 1/1 perl: fix installing modules from contribChristian Hesse, Apr 3, 2018
  2. Ævar Arnfjörð BjarmasonApr 3, 2018
  3. Junio C HamanoApr 9, 2018
  4. 1/1 perl: fix installing modules from contribChristian Hesse, Apr 10, 2018
  5. Junio C HamanoApr 10, 2018
  6. 1/1 perl: fix installing modules from contribChristian Hesse, Apr 11, 2018
  7. Junio C HamanoApr 18, 2018
  8. Christian HesseApr 19, 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.