This is a live mirror of the Perl 5 development currently hosted at https://github.com/perl/perl5
bisect-runner.pl should fix Makefile.SH to remove remove GNU make-isms.
authorNicholas Clark <nick@ccl4.org>
Thu, 12 Apr 2012 19:50:11 +0000 (21:50 +0200)
committerNicholas Clark <nick@ccl4.org>
Tue, 28 May 2013 07:19:28 +0000 (09:19 +0200)
Commit c7b956bbbaff0c46 inadvertently added a GNU (and BSD) make specific
construction to the *nix Makefile, which other platforms' makes choke on.
It was corrected with commit cfe76a0a8e5b6f21 (and 0961731461727bea), but
those changes are not the simplest way to get things passing again, so use
a simpler custom patch here.

Porting/bisect-runner.pl

index 246d62a..95da68e 100755 (executable)
@@ -2046,6 +2046,29 @@ index f61d0db..6097954 100644
 EOPATCH
         }
 
+        if ($major == 15 && $^O !~ /^(linux|darwin|.*bsd)$/
+            && extract_from_file('Makefile.SH', qr/^V.* \?= /)) {
+            # Remove the GNU-make-ism (which the BSD makes also support, but
+            # most other makes choke on)
+            apply_patch(<<'EOPATCH');
+diff --git a/Makefile.SH b/Makefile.SH
+index 94952bd..13e9001 100755
+--- a/Makefile.SH
++++ b/Makefile.SH
+@@ -338,8 +338,8 @@ linux*|darwin)
+ $spitshell >>$Makefile <<!GROK!THIS!
+ # If you're going to use valgrind and it can't be invoked as plain valgrind
+ # then you'll need to change this, or override it on the make command line.
+-VALGRIND ?= valgrind
+-VG_TEST  ?= ./perl -e 1 2>/dev/null
++VALGRIND = valgrind
++VG_TEST  = ./perl -e 1 2>/dev/null
+ !GROK!THIS!
+       ;;
+EOPATCH
+        }
+
         if ($major == 11) {
             if (extract_from_file('patchlevel.h',
                                   qr/^#include "unpushed\.h"/)) {