Fix probing for already installed Error.pm

The syntax for 'require' was wrong, and it was always failing, which
resulted in installing our own version of Error.pm anyways.

Now we used to ship our own Error.pm in the same directory, so after
fixing the syntax, 'require' always succeeds, but it does not test if
the platform has Error.pm module installed anymore.  So rename the
source we ship to private-Error.pm, and install that as Error.pm when
the platform does not have one already.

Signed-off-by: Pavel Roskin <proski@gnu.org>
Signed-off-by: Junio C Hamano <junkio@cox.net>
This commit is contained in:
Pavel Roskin 2006-06-30 01:09:23 -04:00 committed by Junio C Hamano
parent 3553309f5b
commit 1d8c9dc47d
2 changed files with 2 additions and 2 deletions

View file

@ -12,9 +12,9 @@ my %pm = ('Git.pm' => '$(INST_LIBDIR)/Git.pm');
# We come with our own bundled Error.pm. It's not in the set of default
# Perl modules so install it if it's not available on the system yet.
eval { require 'Error' };
eval { require Error };
if ($@) {
$pm{'Error.pm'} = '$(INST_LIBDIR)/Error.pm';
$pm{'private-Error.pm'} = '$(INST_LIBDIR)/Error.pm';
}
WriteMakefile(