Show
Ignore:
Timestamp:
10/18/06 01:01:45 (2 years ago)
Author:
lanny
Message:

[docs/Perl6/Makefile.PL]
* Back out previous attempt fix.
* Put in a real fix (tested) for nmake-1.5 issues on Win32.
* nmake version 1.5 should be able to run the Makefile produced now

Files:
1 modified

Legend:

Unmodified
Added
Removed
  • docs/Perl6/Makefile.PL

    r14404 r14408  
    1515system "$^X Spec/update"; 
    1616 
     17# On Win32 using nmake-1.5 the Makefile produced will die. 
     18# This is a result of a hueristic in ExtUtils::MM_Any::split_command(). 
     19# There is a bug open on this 
     20# 
     21#   http://rt.cpan.org/Public/Bug/Display.html?id=20145 
     22# 
     23# Install a cheat until a real fix comes along. 
     24my $holdme = \&ExtUtils::MM_Win32::max_exec_len; 
     25 
     26*ExtUtils::MM_Win32::max_exec_len = sub { 
     27    my $self = shift; 
     28    $self->{_MAX_EXEC_LEN} ||= 1.67 * 1024; 
     29}; 
     30 
     31# Do the needful for writing the Makefile. 
    1732WritePugs  (5); 
    1833 
    19 # Work around a bug in ExtUtils::MM_Any::manifypods_target(). 
    20 sub MY::manifypods_target { 
    21     my($self) = shift; 
    22  
    23     my $man1pods      = ''; 
    24     my $man3pods      = ''; 
    25     my $dependencies  = ''; 
    26  
    27     # populate manXpods & dependencies: 
    28     foreach my $name (keys %{$self->{MAN1PODS}}) { 
    29         $dependencies .= " \\\n\t$name"; 
    30     } 
    31  
    32     foreach my $name (keys %{$self->{MAN3PODS}}) { 
    33         $dependencies .= " \\\n\t$name" 
    34     } 
    35  
    36     my $manify = <<END; 
    37 manifypods : pure_all $dependencies 
    38 END 
    39  
    40     my @man_cmds; 
    41     foreach my $section (qw(1 3)) { 
    42         my $pods = $self->{"MAN${section}PODS"}; 
    43         push @man_cmds, $self->split_command(<<CMD, %$pods); 
    44         \$(NOECHO) \$(POD2MAN) --section=$section --perm_rw=\$(PERM_RW) 
    45 CMD 
    46     } 
    47  
    48     $manify .= "\t\$(NOECHO) \$(NOOP)\n" unless @man_cmds; 
    49     $manify .= join '', map { "$_\n" } @man_cmds; 
    50  
    51     return $manify; 
    52 } 
     34# Remove our cheat so other modules get expected behavior. 
     35*ExtUtils::MM_Win32::max_exec_len = $holdme;