Closed p5pRT closed 20 years ago
A default build goes fine\, but building with -Duseperlio\, things come grinding to a halt while making Encode:
/usr/local/bin/perl -I../../lib -I../../lib ../../lib/ExtUtils/xsubpp -typemap ../../lib/ExtUtils/typemap Encode.xs > Encode.xsc && mv Encode.xsc Encode.c /usr/local/bin/perl compile iso8859.c Encode/ascii.enc Encode/iso8859*.enc Encode/cp1250.enc Can't locate File/Glob.pm in @INC (@INC contains: ../../lib) at compile line 41. BEGIN failed--compilation aborted at compile line 41. make[1]: *** [iso8859.c] Error 2 make[1]: Leaving directory `/usr/local/src/perl@8150-perlio/ext/Encode' make: *** [lib/auto/Encode/Encode.a] Error 2
This is really weird: MakeMaker (well\, MM_Unix) should have picked up ../../miniperl as the value for PERL in the Makefile\, but instead it's lighted on /usr/local/bin/perl\, which happens to be version 5.7.0 (yes\, I know)\, and which gets confused. (I don't know what's happened with globbing since then\, but the poor thing thinks it wants a module which hasn't been copied into ../../lib at this stage of the build.)
This has been happening for a few snapshots now: I've yet to work back to find out when things went wrong. Does this mean anything to anybody? If not\, I'll plod on with the diagnosis.
At 08:29 PM 12/19/2000 +0100\, Dominic Dunlop wrote:
things come grinding to a halt while making Encode:
If you end up tweaking Encode's Makefile.PL\, please consider also tweaking the postamble section for portability. I've been meaning to work up a patch but got waylaid by other problems.
1.) The name of the dependency file is implementation-defined\, so we need to s/Makefile/$(MAKEFILE)/. I think that macro is defined by the MM_xxx modules on all platforms.
2.) Lists of filenames with Unix-style delimiters may get interpreted correctly by Perl\, but not necessarily by non-Unix make utilities. The names of the form 'Encode/foo.bar' are nonsense on non-Unix systems; the only portable way I know to do that is something like the rather unattractive
File::Spec->catfile(File::Spec->curdir()\, 'Encode'\, 'foo.bar')
Thanks\, and if it's not in the scope of what you're doing I'll get to it one of these days.
Dominic Dunlop \domo@​computer\.org writes:
This is a build failure report for perl from domo@computer.org\, generated with the help of perlbug 1.33 running under perl v5.7.0.
----------------------------------------------------------------- [Please enter your report here]
A default build goes fine\, but building with -Duseperlio\, things come grinding to a halt while making Encode:
/usr/local/bin/perl -I../../lib -I../../lib ../../lib/ExtUtils/xsubpp -typemap ../../lib/ExtUtils/typemap Encode.xs > Encode.xsc && mv Encode.xsc Encode.c /usr/local/bin/perl compile iso8859.c Encode/ascii.enc Encode/iso8859*.enc Encode/cp1250.enc Can't locate File/Glob.pm in @INC (@INC contains: ../../lib) at compile line 41.
Please feel free to try and figure out why MakeMaker used /usr/local/bin/perl
The tiresome part of the bug is that UNIX does not _need_ glob anyway. But
@ARGV = map(glob($_)\,@ARGV) if $^O eq 'MSWin32';
Triggers it to go look.
Try the attached patch (untested)
BEGIN failed--compilation aborted at compile line 41. make[1]: *** [iso8859.c] Error 2 make[1]: Leaving directory `/usr/local/src/perl@8150-perlio/ext/Encode' make: *** [lib/auto/Encode/Encode.a] Error 2
This is really weird: MakeMaker (well\, MM_Unix) should have picked up ../../miniperl as the value for PERL in the Makefile\, but instead it's lighted on /usr/local/bin/perl\, which happens to be version 5.7.0 (yes\, I know)\, and which gets confused. (I don't know what's happened with globbing since then\, but the poor thing thinks it wants a module which hasn't been copied into ../../lib at this stage of the build.)
This has been happening for a few snapshots now: I've yet to work back to find out when things went wrong. Does this mean anything to anybody? If not\, I'll plod on with the diagnosis.
-- Nick Ing-Simmons
==== //depot/perl/ext/Encode/compile#2 - /home/p4work/perl/devperl/ext/Encode/compile ====
Craig A . Berry \craigberry@​mac\.com writes:
At 08:29 PM 12/19/2000 +0100\, Dominic Dunlop wrote:
things come grinding to a halt while making Encode:
If you end up tweaking Encode's Makefile.PL\, please consider also tweaking the postamble section for portability. I've been meaning to work up a patch but got waylaid by other problems.
1.) The name of the dependency file is implementation-defined\, so we need to s/Makefile/$(MAKEFILE)/. I think that macro is defined by the MM_xxx modules on all platforms.
Adding Makefile to the depenancies was a late night hack - it does not really depend on the Makefile - it is the old problem of "compile" producing multiple files (xxxxx.def\, xxxxx.c and xxxxx.h) and Make getting over excited or confused as a consequence.
2.) Lists of filenames with Unix-style delimiters may get interpreted correctly by Perl\, but not necessarily by non-Unix make utilities. The names of the form 'Encode/foo.bar' are nonsense on non-Unix systems; the only portable way I know to do that is something like the rather unattractive
File​::Spec\->catfile\(File​::Spec\->curdir\(\)\, 'Encode'\, 'foo\.bar'\)
MakeMaker has its own legacy idiom for that - which I think now uses File::Spec.
I should know better on both counts.
Thanks\, and if it's not in the scope of what you're doing I'll get to it one of these days.
At 21:10 +0000 2000-12-19\, Nick Ing-Simmons wrote:
Please feel free to try and figure out why MakeMaker used /usr/local/bin/perl ... Try the attached patch (untested)
I will keep looking for the root cause\, even though your patch (for which\, thanks) does indeed mask the symptom in this case.
Migrated from rt.perl.org#4978 (status was 'resolved')
Searchable as RT4978$