develooper Front page | perl.perl5.porters | Postings from September 2009

Re: Make makedef.pl build the command line from its own @INC

Thread Previous
From:
Nicholas Clark
Date:
September 24, 2009 13:42
Subject:
Re: Make makedef.pl build the command line from its own @INC
Message ID:
20090924204227.GA60303@plum.flirble.org
On Thu, Sep 24, 2009 at 10:03:25PM +0200, Max Maischein wrote:
> Hello Nick,
> 
> >>Currently, makedef.pl hardcodes lib/ when it runs $^X to output 
> >>variables from Config.pm. This is bad, because on Windows, it is run 
> >>from win32/ instead. The attached patch lets makedef.pl build the 
> >>command line dynamically by adding all of @INC as -I switches.
> >
> >Would it also work to do
> >
> >    $ENV{PERL5LIB} = join $Config{path_sep}, @INC;
> >
> >before the ``?
> >
> >That was the approach I took in make_ext.pl, and feels a bit more robust,
> >as it should cope with any legal filename on the platform in question.
> >(Except for anyone who puts ':' in a directory name on Unix. Or anywhere 
> >with
> >shorter limits on environment variable length than command line length)
> Yes. That approach is safer and it also works. Patch attached, but I 
> fear it's on top of my previous patch.

Merged and applied as 9d6c7f2eccef26a6d6eb46a8192949a88c6aaf8f

I wasn't sure of the best way to merge them, so I made them on a branch, and
merged it with --squash
At which point I found I had to fix up the commit messages and the author.

Nicholas Clark

Thread Previous


nntp.perl.org: Perl Programming lists via nntp and http.
Comments to Ask Bjørn Hansen at ask@perl.org | Group listing | About