diff m4/acinclude.m4 @ 26071:658153e1976d stable

Fix failing BIST tests and oddities when gnuplot is not present (bug #55023). * acinclude.m4 (OCTAVE_PROG_GNUPLOT): When gnuplot is not found, set GNUPLOT to the default value of "gnuplot" rather than an empty string. Also set variable GNUPLOT_BINARY which is only used for reporting what was found by configure. * configure.ac: Change report of configuration variables at the end of file to use GNUPLOT_BINARY which may be "" if gnuplot was not found, even while GNUPLOT itself has a value. * __init_gnuplot__.cc (have_gnuplot_binary): For good measure, check that value returned from calling gnuplot_binary is not empty before proceeding. * gnuplot_binary.in.m: Wrap BIST tests in a try/catch block which restores the original value of gnuplot_binary if a test fails.
author Rik <rik@octave.org>
date Wed, 14 Nov 2018 10:53:30 -0800
parents 144820478378
children 8b6f1731474b
line wrap: on
line diff
--- a/m4/acinclude.m4	Mon Nov 12 11:21:02 2018 -0500
+++ b/m4/acinclude.m4	Wed Nov 14 10:53:30 2018 -0800
@@ -3253,11 +3253,14 @@
   ac_octave_gp_default="gnuplot"
   if test "$cross_compiling" = yes; then
     GNUPLOT="$ac_octave_gp_default"
+    GNUPLOT_BINARY=$GNUPLOT
     AC_MSG_RESULT([assuming $GNUPLOT exists on $canonical_host_type host])
   else
     AC_CHECK_PROGS(GNUPLOT, [$ac_octave_gp_names])
+    GNUPLOT_BINARY=$GNUPLOT
     if test -z "$GNUPLOT"; then
-      GNUPLOT="$gp_default"
+      GNUPLOT="$ac_octave_gp_default"
+      GNUPLOT_BINARY=""
       warn_gnuplot="
 
 gnuplot not found.  It isn't necessary to have gnuplot installed, but