From 9094a4e8ed4808e43506f9d7d78b4187fb8a88d6 Mon Sep 17 00:00:00 2001 From: Jess Robinson Date: Fri, 18 Jan 2013 15:46:10 +0000 Subject: [PATCH] Use the system perl for RUN_PERL, if we are cross compiling, and we found one. Note we can only substitute the system perl for scripts that do not require Config as it complains about non-matching Perl versions. --- Makefile.SH | 49 +++++++++++++++++++++++++++++++++---------------- 1 file changed, 33 insertions(+), 16 deletions(-) diff --git a/Makefile.SH b/Makefile.SH index 9228377..be893ec 100755 --- a/Makefile.SH +++ b/Makefile.SH @@ -307,6 +307,7 @@ RUN = # When cross-compiling we want to use a (mini)perl built for the host, not the target HOST_PERL = $hostperl HOST_GENERATE = $hostgenerate +SYSTEM_PERL = $perl # These variables may need to be manually set for non-Unix systems. AR = $full_ar @@ -321,10 +322,26 @@ PATH_SEP = $p_ MINIPERL_EXE = miniperl\$(EXE_EXT) MINIPERL = \$(LDLIBPTH) ./miniperl\$(EXE_EXT) -Ilib +!GROK!THIS! + +case "$usecrosscompile$perl" in +define?*) + $spitshell >>$Makefile <>$Makefile <>$Makefile <>$Makefile <<'!NO!SUBS!' .PHONY: printconfig printconfig: - @eval `$(RUN_PERL) -Ilib -V:$(CONFIGVAR)`; echo $$$(CONFIGVAR) + @eval `$(RUN_PERL) -V:$(CONFIGVAR)`; echo $$$(CONFIGVAR) .PHONY: clean _tidy _mopup _cleaner1 _cleaner2 \ realclean _realcleaner clobber _clobber \ @@ -1443,28 +1460,28 @@ test_porting test-porting: test_prep .PHONY: ok okfile oknack okfilenack nok nokfile noknack nokfilenack ok: utilities - $(RUN_PERL) -Ilib utils/perlbug -ok -s '(UNINSTALLED)' + $(RUN_PERL) utils/perlbug -ok -s '(UNINSTALLED)' okfile: utilities - $(RUN_PERL) -Ilib utils/perlbug -ok -s '(UNINSTALLED)' -F perl.ok + $(RUN_PERL) utils/perlbug -ok -s '(UNINSTALLED)' -F perl.ok oknack: utilities - $(RUN_PERL) -Ilib utils/perlbug -ok -s '(UNINSTALLED)' -A + $(RUN_PERL) utils/perlbug -ok -s '(UNINSTALLED)' -A okfilenack: utilities - $(RUN_PERL) -Ilib utils/perlbug -ok -s '(UNINSTALLED)' -F perl.ok -A + $(RUN_PERL) utils/perlbug -ok -s '(UNINSTALLED)' -F perl.ok -A nok: utilities - $(RUN_PERL) -Ilib utils/perlbug -nok -s '(UNINSTALLED)' + $(RUN_PERL) utils/perlbug -nok -s '(UNINSTALLED)' nokfile: utilities - $(RUN_PERL) -Ilib utils/perlbug -nok -s '(UNINSTALLED)' -F perl.nok + $(RUN_PERL) utils/perlbug -nok -s '(UNINSTALLED)' -F perl.nok noknack: utilities - $(RUN_PERL) -Ilib utils/perlbug -nok -s '(UNINSTALLED)' -A + $(RUN_PERL) utils/perlbug -nok -s '(UNINSTALLED)' -A nokfilenack: utilities - $(RUN_PERL) -Ilib utils/perlbug -nok -s '(UNINSTALLED)' -F perl.nok -A + $(RUN_PERL) utils/perlbug -nok -s '(UNINSTALLED)' -F perl.nok -A .PHONY: clist hlist -- 2.7.4