Re: MakeMaker doesn't pasthru DEFINE command-line args to subdirs on Win32
Steve Hay [Tue, 5 Aug 2003 10:43:49 +0000 (11:43 +0100)]
Message-ID: <3F2F7C55.9020808@uk.radan.com>

(The MM_Unix.pm part was dealt with in #20501.)

p4raw-id: //depot/perl@20502

lib/ExtUtils/MM_Win32.pm
lib/ExtUtils/t/MM_Win32.t

index d05c870..004694c 100644 (file)
@@ -430,8 +430,10 @@ banner.
 
 sub pasthru {
     my($self) = shift;
-    return "PASTHRU = " . ($NMAKE ? "-nologo" : "");
-}
+    my $pasthru = $self->SUPER::pasthru();
+    $pasthru =~ s/PASTHRU\s*=\s*/PASTHRU = -nologo / if $NMAKE;
+    return $pasthru;                                                           
+ }
 
 
 =item oneliner (o)
index 315b915..69e4afb 100644 (file)
@@ -254,8 +254,8 @@ unlink "${script_name}$script_ext" if -f "${script_name}$script_ext";
 
 # pasthru()
 {
-    my $pastru = "PASTHRU = " . ($Config{make} =~ /^nmake/i ? "-nologo" : "");
-    is( $MM->pasthru(), $pastru, 'pasthru()' );
+    my $pasthru = ($Config{make} =~ /^nmake/i ? "/-nologo/" : "");
+    like( $MM->pasthru(), $pasthru, 'pasthru()' );
 }
 
 package FakeOut;