From: Nicholas Clark Date: Mon, 7 Sep 2009 14:48:18 +0000 (+0100) Subject: Use $ENV{PERL_LIB} rather than an -I argument to pass in the library location. X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=commitdiff_plain;h=73402eba5d70043b96ba0e48baa0b161e86c8605;p=p5sagit%2Fp5-mst-13.2.git Use $ENV{PERL_LIB} rather than an -I argument to pass in the library location. (This will scale to multiple library locations, and to subprocess perls, which is necessary if we want to move build-time dual-life modules from lib to ext/...) --- diff --git a/make_ext.pl b/make_ext.pl index 85bbacc..507f047 100644 --- a/make_ext.pl +++ b/make_ext.pl @@ -215,6 +215,7 @@ sub build_extension { $perl ||= "$up/miniperl"; my $return_dir = $up; my $lib_dir = "$up/lib"; + $ENV{PERL5LIB} = $lib_dir; unless (chdir "$ext_dir") { warn "Cannot cd to $ext_dir: $!"; @@ -286,7 +287,7 @@ EOM @cross = '-MCross'; } - my @args = ("-I$lib_dir", @cross, 'Makefile.PL'); + my @args = (@cross, 'Makefile.PL'); if ($is_VMS) { my $libd = VMS::Filespec::vmspath($lib_dir); push @args, "INST_LIB=$libd", "INST_ARCHLIB=$libd";