Re: [PATCH] perl/Makefile: use 'installsitelib' even with NO_PERL_MAKEMAKER

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



This is a boring patch, I know, but it affects anyone doing a vanilla git installation on an os that bundles perl but not ExtUtils::MakeMaker, which is quite common.  Git's own utilities in perl can use Git.pm, but any other perl programs will fail to 'use Git;'

Any takers?

On Jan 30, 2012, at 11:51 AM, Nicholas Harteau wrote:

> perl/Makefile installs Git.pm into $prefix/lib when ExtUtils::MakeMaker
> is not present.  perl can't "use Git;" in that scenario, as $prefix/lib
> isn't in perl's include path.
> 
> This patch installs Git.pm into perl's 'installsitelib', generally
> $prefix/lib/perl5/site_perl, so that even when ExtUtils::MakeMaker isn't
> present, Git.pm gets installed in a location where 'use Git;' just
> works.
> 
> for some additional discussion, see:
> https://github.com/mxcl/homebrew/pull/8643
> https://github.com/mxcl/homebrew/issues/8620
> ---
> perl/Makefile |    2 +-
> 1 files changed, 1 insertions(+), 1 deletions(-)
> 
> diff --git a/perl/Makefile b/perl/Makefile
> index b2977cd..2199eb1 100644
> --- a/perl/Makefile
> +++ b/perl/Makefile
> @@ -21,7 +21,7 @@ clean:
> 	$(RM) $(makfile).old
> 
> ifdef NO_PERL_MAKEMAKER
> -instdir_SQ = $(subst ','\'',$(prefix)/lib)
> +instdir_SQ = $(subst ','\'',$(subst installsitelib=,'',$(shell $(PERL_PATH_SQ) -V:installsitelib)))
> $(makfile): ../GIT-CFLAGS Makefile
> 	echo all: private-Error.pm Git.pm > $@
> 	echo '	mkdir -p blib/lib' >> $@
> -- 
> 1.7.8.3
> 
> --
> nicholas harteau
> nrh@xxxxxxxxxxx
> 
> 
> 
> 

--
nicholas harteau
nrh@xxxxxxxxxxx




--
To unsubscribe from this list: send the line "unsubscribe git" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[Index of Archives]     [Linux Kernel Development]     [Gcc Help]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [V4L]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]     [Fedora Users]