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

[PATCH v2/pu] perl/Makefile: Unset INSTALL_BASE when making perl.mak

From
Ævar Arnfjörð Bjarmason <avarab@gmail.com>
Date
Aug 12, 2010, 02:48 UTC
Message-ID
<1281581320-4235-1-git-send-email-avarab@gmail.com>
In-Reply-To
<1280831411-4511-1-git-send-email-avarab@gmail.com>

PREFIX and INSTALL_BASE are mutually exclusive. If both are supplied by INSTALL_BASE being set in PERL_MM_OPT ExtUtils::MakeMaker will produce an error:

    $ echo $PERL_MM_OPT
    INSTALL_BASE=/home/avar/perl5
    $ make -C perl  PERL_PATH='/usr/bin/perl' prefix='/home/avar' perl.mak
    make: Entering directory `/home/avar/g/git/perl'
    /usr/bin/perl Makefile.PL PREFIX='/home/avar'
    Only one of PREFIX or INSTALL_BASE can be given.  Not both.
    make: *** [perl.mak] Error 255
    make: Leaving directory `/home/avar/g/git/perl'

Change the perl Makefile to work around this by explicitly unsetting INSTALL_BASE.

INSTALL_BASE is set in PERL_MM_OPT by e.g. the popular local::lib package, from its documentation:

    eval $(perl -I$HOME/perl5/lib/perl5 -Mlocal::lib 2>/dev/null)

Many other environments might also have set PERL_MM_OPT before building Git. This change enables us to build in these environments.

Signed-off-by: Ævar Arnfjörð Bjarmason <avarab@gmail.com>
---

Here's a patch on top of pu instead. This change conflicted with the gettext series.

 perl/Makefile |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)
diff --git a/perl/Makefile b/perl/Makefile
index 4e624ff..b2977cd 100644
--- a/perl/Makefile
+++ b/perl/Makefile
@@ -39,7 +39,7 @@ $(makfile): ../GIT-CFLAGS Makefile
 	echo '	echo $(instdir_SQ)' >> $@
 else
 $(makfile): Makefile.PL ../GIT-CFLAGS
-	$(PERL_PATH) $< PREFIX='$(prefix_SQ)' --localedir='$(localedir_SQ)'
+	$(PERL_PATH) $< PREFIX='$(prefix_SQ)' INSTALL_BASE='' --localedir='$(localedir_SQ)'
 endif
 
 # this is just added comfort for calling make directly in perl dir
-- 
1.7.2.1.327.gfb40
Previous: Jakub Narebski
Message 3 of 3 in “perl/Makefile: Unset INSTALL_BASE when making perl.mak”
  1. perl/Makefile: Unset INSTALL_BASE when making perl.makÆvar Arnfjörð Bjarmason, Aug 3, 2010
  2. Jakub NarebskiAug 3, 2010
  3. perl/Makefile: Unset INSTALL_BASE when making perl.makÆvar Arnfjörð Bjarmason, Aug 12, 2010

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.