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

[PATCH v3] perl: regenerate perl.mak if perl -V changes

From
Ævar Arnfjörð Bjarmason <avarab@gmail.com>
Date
Mar 29, 2017, 13:57 UTC
Message-ID
<20170329135703.18860-1-avarab@gmail.com>
In-Reply-To
<39b203e9-c3a9-80c3-ec24-649e04ef5620@atlas-elektronik.com>

Change the perl/perl.mak build process so that the file is regenerated if the output of "perl -V" changes.

Before this change updating e.g. /usr/bin/perl to a new major version would cause the next "make" command to fail, since perl.mak has hardcoded paths to perl library paths retrieved from its first run.

Now the logic added in commit ee9be06770 ("perl: detect new files in MakeMaker builds", 2012-07-27) is extended to regenerate perl/perl.mak if there's any change to "perl -V".

This will in some cases redundantly trigger perl/perl.mak to be re-made, e.g. if @INC is modified in ways the build process doesn't care about through sitecustomize.pl, but the common case is that we just do the right thing and re-generate perl/perl.mak when needed.

Signed-off-by: Ævar Arnfjörð Bjarmason <avarab@gmail.com>
---
On Wed, Mar 29, 2017 at 3:36 PM,  <stefan.naewe@atlas-elektronik.com> wrote:
Show 11 quoted lines
> Am 29.03.2017 um 15:33 schrieb Ævar Arnfjörð Bjarmason:
> [...]
>> Now the logic added in commit ee9be06770 ("perl: detect new files in
>> MakeMaker builds", 2012-07-27) is extended to regeneratio
>
> s/regeneratio/regenerate/
>
>> [...]
>
>
> /S
Thanks!
 Makefile | 1 +
 1 file changed, 1 insertion(+)
diff --git a/Makefile b/Makefile
index 9f8b35ad41..485c453ca2 100644
--- a/Makefile
+++ b/Makefile
@@ -1851,6 +1851,7 @@ perl/perl.mak: perl/PM.stamp
 
 perl/PM.stamp: FORCE
 	@$(FIND) perl -type f -name '*.pm' | sort >$@+ && \
+	$(PERL_PATH) -V >>$@+ && \
 	{ cmp $@+ $@ >/dev/null 2>/dev/null || mv $@+ $@; } && \
 	$(RM) $@+
 
-- 
2.11.0
Previous: stefan.naewe@atlas-elektronik.comNext: Jeff King
Message 6 of 10 in “Can't locate ExtUtils/MakeMaker.pm in @INC”
  1. Jeffrey WaltonMar 29, 2017
  2. Jeff KingMar 29, 2017
  3. perl: regenerate perl.mak if perl -V changesÆvar Arnfjörð Bjarmason, Mar 29, 2017
  4. perl: regenerate perl.mak if perl -V changesÆvar Arnfjörð Bjarmason, Mar 29, 2017
  5. stefan.naewe@atlas-elektronik.comMar 29, 2017
  6. perl: regenerate perl.mak if perl -V changesÆvar Arnfjörð Bjarmason, Mar 29, 2017
  7. Jeff KingMar 29, 2017
  8. Ævar Arnfjörð BjarmasonMar 29, 2017
  9. Junio C HamanoMar 29, 2017
  10. Jeffrey WaltonMar 29, 2017

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.