# HG changeset patch # User John W. Eaton # Date 1463146574 14400 # Node ID 263d18409fdfae0832057ecf9c5ca922db3d16b7 # Parent b6a686543080163dcc5b62c7b897aa05049b044e Eliminate unused variable warnings for conditionally compiled code. We had more or less decided not to bother trying to eliminate all these warnings for cases in which external dependencies are missing. But then we get people trying to fix these in various ways, so we might as well do it for all cases and use a consistent method. * oct-conf-post.in.h (octave_unused_parameter): New function for C++ code and new macro for C code. * mk-octave-config-h.sh: Emit octave_unused_parameter function and macro for octave-config.h. * CSparse.cc, __delaunayn__.cc, __eigs__.cc, __fltk_uigetfile__.cc, __glpk__.cc, __magick_read__.cc, __osmesa_print__.cc, __voronoi__.cc, amd.cc, audiodevinfo.cc, audioread.cc, ccolamd.cc, cdisplay.c, colamd.cc, convhulln.cc, dSparse.cc, dmperm.cc, fftw.cc, gl-render.cc, lo-error.c, load-save.cc, ls-hdf5.cc, ls-mat5.cc, oct-hdf5-types.cc, ov-base-int.cc, ov-bool-mat.cc, ov-bool-sparse.cc, ov-bool.cc, ov-cell.cc, ov-class.cc, ov-complex.cc, ov-cx-mat.cc, ov-cx-sparse.cc, ov-fcn-handle.cc, ov-fcn-inline.cc, ov-float.cc, ov-flt-complex.cc, ov-flt-cx-mat.cc, ov-flt-re-mat.cc, ov-java.cc, ov-range.cc, ov-re-mat.cc, ov-re-sparse.cc, ov-scalar.cc, ov-str-mat.cc, ov-struct.cc, sparse-chol.cc, sparse-dmsolve.cc, sparse-lu.cc, sparse-qr.cc, sparse-util.cc, symbfact.cc: Use octave_unused_parameter to eliminate warnings for conditionally compiled code. diff -r b6a686543080 -r 263d18409fdf build-aux/mk-octave-config-h.sh --- a/build-aux/mk-octave-config-h.sh Fri May 13 09:27:38 2016 -0400 +++ b/build-aux/mk-octave-config-h.sh Fri May 13 09:36:14 2016 -0400 @@ -116,6 +116,15 @@ /* # undef HAVE_OCTAVE_UNUSED_ATTR */ #endif +#if defined (__cplusplus) +template +static inline void +octave_unused_parameter (const T&) +{ } +#else +# define octave_unused_parameter(param) (void) param; +#endif + #if defined (_MSC_VER) # define OCTAVE_EXPORT __declspec(dllexport) # define OCTAVE_IMPORT __declspec(dllimport) diff -r b6a686543080 -r 263d18409fdf libinterp/corefcn/__magick_read__.cc --- a/libinterp/corefcn/__magick_read__.cc Fri May 13 09:27:38 2016 -0400 +++ b/libinterp/corefcn/__magick_read__.cc Fri May 13 09:36:14 2016 -0400 @@ -740,6 +740,7 @@ initialized = true; } } + #endif DEFUN (__magick_read__, args, nargout, @@ -754,6 +755,7 @@ @end deftypefn") { #ifdef HAVE_MAGICK + if (args.length () != 2 || ! args(0).is_string ()) print_usage (); @@ -849,7 +851,12 @@ return output; #else + + octave_unused_parameter (args); + octave_unused_parameter (nargout); + err_disabled_feature ("imread", "Image IO"); + #endif } @@ -1391,6 +1398,7 @@ @end deftypefn") { #ifdef HAVE_MAGICK + if (args.length () != 5 || ! args(0).is_string () || ! args(1).is_string ()) print_usage (); @@ -1540,7 +1548,11 @@ return ovl (); #else + + octave_unused_parameter (args); + err_disabled_feature ("imwrite", "Image IO"); + #endif } @@ -1564,6 +1576,7 @@ @end deftypefn") { #ifdef HAVE_MAGICK + if (args.length () < 1 || ! args(0).is_string ()) print_usage (); @@ -1602,11 +1615,16 @@ return ovl (ping); #else + + octave_unused_parameter (args); + err_disabled_feature ("imfinfo", "Image IO"); + #endif } #ifdef HAVE_MAGICK + static octave_value magick_to_octave_value (const Magick::CompressionType& magick) { @@ -1784,6 +1802,7 @@ @end deftypefn") { #ifdef HAVE_MAGICK + if (args.length () < 1 || ! args(0).is_string ()) print_usage (); @@ -2209,7 +2228,11 @@ return ovl (info); #else + + octave_unused_parameter (args); + err_disabled_feature ("imfinfo", "Image IO"); + #endif } @@ -2232,6 +2255,7 @@ octave_map formats = args(0).map_value (); #ifdef HAVE_MAGICK + maybe_initialize_magick (); for (octave_idx_type idx = 0; idx < formats.numel (); idx++) @@ -2261,7 +2285,9 @@ } #else + formats = octave_map (dim_vector (1, 0), formats.fieldnames ()); + #endif return ovl (formats); diff -r b6a686543080 -r 263d18409fdf libinterp/corefcn/cdisplay.c --- a/libinterp/corefcn/cdisplay.c Fri May 13 09:27:38 2016 -0400 +++ b/libinterp/corefcn/cdisplay.c Fri May 13 09:36:14 2016 -0400 @@ -21,7 +21,7 @@ */ #ifdef HAVE_CONFIG_H -#include "config.h" +# include "config.h" #endif #include @@ -167,6 +167,12 @@ #else + octave_unused_parameter (ht); + octave_unused_parameter (wd); + octave_unused_parameter (dp); + octave_unused_parameter (rx); + octave_unused_parameter (ry); + msg = "no graphical display found"; #endif diff -r b6a686543080 -r 263d18409fdf libinterp/corefcn/gl-render.cc --- a/libinterp/corefcn/gl-render.cc Fri May 13 09:27:38 2016 -0400 +++ b/libinterp/corefcn/gl-render.cc Fri May 13 09:36:14 2016 -0400 @@ -647,6 +647,7 @@ } #if defined (HAVE_OPENGL) + static std::string gl_get_string (GLenum id) { @@ -658,6 +659,7 @@ buf << glGetString (id); return std::string (buf.str ()); } + #endif void @@ -668,10 +670,12 @@ init_gl_context (props.is___enhanced__ (), props.get_color_rgb ()); #if defined (HAVE_OPENGL) + props.set___gl_extensions__ (gl_get_string (GL_EXTENSIONS)); props.set___gl_renderer__ (gl_get_string (GL_RENDERER)); props.set___gl_vendor__ (gl_get_string (GL_VENDOR)); props.set___gl_version__ (gl_get_string (GL_VERSION)); + #endif // Draw children @@ -740,10 +744,15 @@ } #else + + octave_unused_parameter (enhanced); + octave_unused_parameter (c); + // This shouldn't happen because construction of opengl_renderer // objects is supposed to be impossible if OpenGL is not available. panic_impossible (); + #endif } @@ -795,10 +804,23 @@ set_linestyle ("-", true); #else + + octave_unused_parameter (gridstyle); + octave_unused_parameter (ticks); + octave_unused_parameter (lim1); + octave_unused_parameter (lim2); + octave_unused_parameter (p1); + octave_unused_parameter (p1N); + octave_unused_parameter (p2); + octave_unused_parameter (p2N); + octave_unused_parameter (xyz); + octave_unused_parameter (is_3D); + // This shouldn't happen because construction of opengl_renderer // objects is supposed to be impossible if OpenGL is not available. panic_impossible (); + #endif } @@ -856,10 +878,25 @@ glEnd (); #else + + octave_unused_parameter (ticks); + octave_unused_parameter (lim1); + octave_unused_parameter (lim2); + octave_unused_parameter (p1); + octave_unused_parameter (p1N); + octave_unused_parameter (p2); + octave_unused_parameter (p2N); + octave_unused_parameter (dx); + octave_unused_parameter (dy); + octave_unused_parameter (dz); + octave_unused_parameter (xyz); + octave_unused_parameter (mirror); + // This shouldn't happen because construction of opengl_renderer // objects is supposed to be impossible if OpenGL is not available. panic_impossible (); + #endif } @@ -912,10 +949,24 @@ } #else + + octave_unused_parameter (ticks); + octave_unused_parameter (ticklabels); + octave_unused_parameter (lim1); + octave_unused_parameter (lim2); + octave_unused_parameter (p1); + octave_unused_parameter (p2); + octave_unused_parameter (xyz); + octave_unused_parameter (ha); + octave_unused_parameter (va); + octave_unused_parameter (wmax); + octave_unused_parameter (hmax); + // This shouldn't happen because construction of opengl_renderer // objects is supposed to be impossible if OpenGL is not available. panic_impossible (); + #endif } @@ -927,10 +978,12 @@ glFinish (); #else + // This shouldn't happen because construction of opengl_renderer // objects is supposed to be impossible if OpenGL is not available. panic_impossible (); + #endif } @@ -974,10 +1027,14 @@ xform = props.get_transform (); #else + + octave_unused_parameter (props); + // This shouldn't happen because construction of opengl_renderer // objects is supposed to be impossible if OpenGL is not available. panic_impossible (); + #endif } @@ -1030,10 +1087,14 @@ set_polygon_offset (false); #else + + octave_unused_parameter (props); + // This shouldn't happen because construction of opengl_renderer // objects is supposed to be impossible if OpenGL is not available. panic_impossible (); + #endif } @@ -1150,10 +1211,14 @@ glEnd (); #else + + octave_unused_parameter (props); + // This shouldn't happen because construction of opengl_renderer // objects is supposed to be impossible if OpenGL is not available. panic_impossible (); + #endif } @@ -1590,10 +1655,14 @@ // FIXME: draw zoom box, if needed #else + + octave_unused_parameter (props); + // This shouldn't happen because construction of opengl_renderer // objects is supposed to be impossible if OpenGL is not available. panic_impossible (); + #endif } @@ -1649,10 +1718,14 @@ draw_axes_children (props); #else + + octave_unused_parameter (props); + // This shouldn't happen because construction of opengl_renderer // objects is supposed to be impossible if OpenGL is not available. panic_impossible (); + #endif } @@ -1782,10 +1855,14 @@ set_clipping (props.is_clipping ()); #else + + octave_unused_parameter (props); + // This shouldn't happen because construction of opengl_renderer // objects is supposed to be impossible if OpenGL is not available. panic_impossible (); + #endif } @@ -2388,10 +2465,14 @@ } #else + + octave_unused_parameter (props); + // This shouldn't happen because construction of opengl_renderer // objects is supposed to be impossible if OpenGL is not available. panic_impossible (); + #endif } @@ -2831,10 +2912,14 @@ } #else + + octave_unused_parameter (props); + // This shouldn't happen because construction of opengl_renderer // objects is supposed to be impossible if OpenGL is not available. panic_impossible (); + #endif } @@ -2871,10 +2956,14 @@ glDisable (GL_BLEND); #else + + octave_unused_parameter (props); + // This shouldn't happen because construction of opengl_renderer // objects is supposed to be impossible if OpenGL is not available. panic_impossible (); + #endif } @@ -3067,10 +3156,14 @@ glPixelZoom (1, 1); #else + + octave_unused_parameter (props); + // This shouldn't happen because construction of opengl_renderer // objects is supposed to be impossible if OpenGL is not available. panic_impossible (); + #endif } @@ -3082,10 +3175,15 @@ glViewport (0, 0, w, h); #else + + octave_unused_parameter (w); + octave_unused_parameter (h); + // This shouldn't happen because construction of opengl_renderer // objects is supposed to be impossible if OpenGL is not available. panic_impossible (); + #endif } @@ -3097,10 +3195,16 @@ glDrawPixels (width, height, GL_RGB, GL_FLOAT, data); #else + + octave_unused_parameter (width); + octave_unused_parameter (height); + octave_unused_parameter (data); + // This shouldn't happen because construction of opengl_renderer // objects is supposed to be impossible if OpenGL is not available. panic_impossible (); + #endif } @@ -3112,10 +3216,16 @@ glDrawPixels (width, height, GL_RGB, GL_UNSIGNED_BYTE, data); #else + + octave_unused_parameter (width); + octave_unused_parameter (height); + octave_unused_parameter (data); + // This shouldn't happen because construction of opengl_renderer // objects is supposed to be impossible if OpenGL is not available. panic_impossible (); + #endif } @@ -3127,10 +3237,16 @@ glDrawPixels (width, height, GL_RGB, GL_UNSIGNED_SHORT, data); #else + + octave_unused_parameter (width); + octave_unused_parameter (height); + octave_unused_parameter (data); + // This shouldn't happen because construction of opengl_renderer // objects is supposed to be impossible if OpenGL is not available. panic_impossible (); + #endif } @@ -3144,10 +3260,14 @@ txt_renderer.set_color (c); #else + + octave_unused_parameter (c); + // This shouldn't happen because construction of opengl_renderer // objects is supposed to be impossible if OpenGL is not available. panic_impossible (); + #endif } @@ -3178,10 +3298,15 @@ } #else + + octave_unused_parameter (on); + octave_unused_parameter (offset); + // This shouldn't happen because construction of opengl_renderer // objects is supposed to be impossible if OpenGL is not available. panic_impossible (); + #endif } @@ -3193,10 +3318,14 @@ glLineWidth (w); #else + + octave_unused_parameter (w); + // This shouldn't happen because construction of opengl_renderer // objects is supposed to be impossible if OpenGL is not available. panic_impossible (); + #endif } @@ -3227,10 +3356,15 @@ glEnable (GL_LINE_STIPPLE); #else + + octave_unused_parameter (s); + octave_unused_parameter (use_stipple); + // This shouldn't happen because construction of opengl_renderer // objects is supposed to be impossible if OpenGL is not available. panic_impossible (); + #endif } @@ -3268,10 +3402,19 @@ zmin = z1; zmax = z2; #else + + octave_unused_parameter (x1); + octave_unused_parameter (x2); + octave_unused_parameter (y1); + octave_unused_parameter (y2); + octave_unused_parameter (z1); + octave_unused_parameter (z2); + // This shouldn't happen because construction of opengl_renderer // objects is supposed to be impossible if OpenGL is not available. panic_impossible (); + #endif } @@ -3293,10 +3436,14 @@ } #else + + octave_unused_parameter (enable); + // This shouldn't happen because construction of opengl_renderer // objects is supposed to be impossible if OpenGL is not available. panic_impossible (); + #endif } @@ -3305,11 +3452,11 @@ { #if defined (HAVE_OPENGL) -#if defined (HAVE_FRAMEWORK_OPENGL) +# if defined (HAVE_FRAMEWORK_OPENGL) GLint vw[4]; -#else +# else int vw[4]; -#endif +# endif glGetIntegerv (GL_VIEWPORT, vw); @@ -3327,10 +3474,16 @@ filled_marker_id = make_marker_list (m, size, true); #else + + octave_unused_parameter (m); + octave_unused_parameter (size); + octave_unused_parameter (width); + // This shouldn't happen because construction of opengl_renderer // objects is supposed to be impossible if OpenGL is not available. panic_impossible (); + #endif } @@ -3349,10 +3502,12 @@ set_linewidth (0.5f); #else + // This shouldn't happen because construction of opengl_renderer // objects is supposed to be impossible if OpenGL is not available. panic_impossible (); + #endif } @@ -3390,10 +3545,18 @@ } #else + + octave_unused_parameter (x); + octave_unused_parameter (y); + octave_unused_parameter (z); + octave_unused_parameter (lc); + octave_unused_parameter (fc); + // This shouldn't happen because construction of opengl_renderer // objects is supposed to be impossible if OpenGL is not available. panic_impossible (); + #endif } @@ -3553,10 +3716,16 @@ return ID; #else + + octave_unused_parameter (marker); + octave_unused_parameter (size); + octave_unused_parameter (filled); + // This shouldn't happen because construction of opengl_renderer // objects is supposed to be impossible if OpenGL is not available. panic_impossible (); + #endif } @@ -3614,9 +3783,19 @@ return bbox; #else + + octave_unused_parameter (txt); + octave_unused_parameter (x); + octave_unused_parameter (y); + octave_unused_parameter (z); + octave_unused_parameter (halign); + octave_unused_parameter (valign); + octave_unused_parameter (rotation); + // This shouldn't happen because construction of opengl_renderer // objects is supposed to be impossible if OpenGL is not available. panic_impossible (); + #endif } diff -r b6a686543080 -r 263d18409fdf libinterp/corefcn/load-save.cc --- a/libinterp/corefcn/load-save.cc Fri May 13 09:27:38 2016 -0400 +++ b/libinterp/corefcn/load-save.cc Fri May 13 09:36:14 2016 -0400 @@ -1023,6 +1023,10 @@ load_save_format &format, bool &append, bool &save_as_floats, bool &use_zlib) { +#if ! defined (HAVE_ZLIB) + octave_unused_parameter (use_zlib); +#endif + string_vector retval; int argc = argv.numel (); diff -r b6a686543080 -r 263d18409fdf libinterp/corefcn/ls-hdf5.cc --- a/libinterp/corefcn/ls-hdf5.cc Fri May 13 09:27:38 2016 -0400 +++ b/libinterp/corefcn/ls-hdf5.cc Fri May 13 09:36:14 2016 -0400 @@ -987,11 +987,19 @@ } # else - (void) st; //silence compiler warning + + octave_unused_parameter (st); + return -1; + # endif + #else + + octave_unused_parameter (st); + err_disabled_feature ("save_type_to_hdf5", "HDF5"); + #endif } diff -r b6a686543080 -r 263d18409fdf libinterp/corefcn/ls-mat5.cc --- a/libinterp/corefcn/ls-mat5.cc Fri May 13 09:27:38 2016 -0400 +++ b/libinterp/corefcn/ls-mat5.cc Fri May 13 09:36:14 2016 -0400 @@ -591,6 +591,7 @@ } return retval; + #else err_disabled_feature ("load", "compressed data elements (zlib)"); #endif @@ -2286,6 +2287,7 @@ } #ifdef HAVE_ZLIB + if (mat7_format && ! compressing) { bool ret = false; @@ -2320,6 +2322,11 @@ return ret; } + +#else + + octave_unused_parameter (compressing); + #endif write_mat5_tag (os, miMATRIX, save_mat5_element_length diff -r b6a686543080 -r 263d18409fdf libinterp/corefcn/oct-hdf5-types.cc --- a/libinterp/corefcn/oct-hdf5-types.cc Fri May 13 09:27:38 2016 -0400 +++ b/libinterp/corefcn/oct-hdf5-types.cc Fri May 13 09:36:14 2016 -0400 @@ -37,6 +37,7 @@ if (! checked) { #if defined (HAVE_HDF5) + ok = sizeof (octave_hdf5_id) >= sizeof (hid_t); if (warn && ! ok) @@ -51,7 +52,11 @@ ("Octave:internal", "the size of octave_hdf5_err is smaller than the size of HDF5 herr_t"); #else + + octave_unused_parameter (warn); + warn_disabled_feature ("check_hdf5_id_type", "HDF5"); + #endif checked = true; diff -r b6a686543080 -r 263d18409fdf libinterp/dldfcn/__delaunayn__.cc --- a/libinterp/dldfcn/__delaunayn__.cc Fri May 13 09:27:38 2016 -0400 +++ b/libinterp/dldfcn/__delaunayn__.cc Fri May 13 09:36:14 2016 -0400 @@ -55,11 +55,12 @@ #include "unwind-prot.h" #if defined (HAVE_QHULL) + # include "oct-qhull.h" + # if defined (NEED_QHULL_VERSION) char qh_version[] = "__delaunayn__.oct 2007-08-21"; # endif -#endif static void close_fcn (FILE *f) @@ -81,6 +82,8 @@ return true; } +#endif + DEFUN_DLD (__delaunayn__, args, , "-*- texinfo -*-\n\ @deftypefn {} {@var{T} =} __delaunayn__ (@var{pts})\n\ @@ -226,7 +229,11 @@ return retval; #else + + octave_unused_parameter (args); + err_disabled_feature ("__delaunayn__", "Qhull"); + #endif } diff -r b6a686543080 -r 263d18409fdf libinterp/dldfcn/__eigs__.cc --- a/libinterp/dldfcn/__eigs__.cc Fri May 13 09:27:38 2016 -0400 +++ b/libinterp/dldfcn/__eigs__.cc Fri May 13 09:36:14 2016 -0400 @@ -37,6 +37,8 @@ #include "unwind-prot.h" #include "variables.h" +#if defined (HAVE_ARPACK) + // Global pointer for user defined function. static octave_function *eigs_fcn = 0; @@ -120,6 +122,8 @@ return retval; } +#endif + DEFUN_DLD (__eigs__, args, nargout, "-*- texinfo -*-\n\ @deftypefn {} {@var{d} =} __eigs__ (@var{A})\n\ @@ -146,6 +150,7 @@ @end deftypefn") { #ifdef HAVE_ARPACK + int nargin = args.length (); if (nargin == 0) @@ -558,7 +563,12 @@ return retval; #else + + octave_unused_parameter (args); + octave_unused_parameter (nargout); + err_disabled_feature ("eigs", "ARPACK"); + #endif } diff -r b6a686543080 -r 263d18409fdf libinterp/dldfcn/__fltk_uigetfile__.cc --- a/libinterp/dldfcn/__fltk_uigetfile__.cc Fri May 13 09:27:38 2016 -0400 +++ b/libinterp/dldfcn/__fltk_uigetfile__.cc Fri May 13 09:36:14 2016 -0400 @@ -52,6 +52,7 @@ @end deftypefn") { #ifdef HAVE_FLTK + // Expected argument list: // // args(0) ... FileFilter in fltk format @@ -139,7 +140,11 @@ return retval; #else + + octave_unused_parameter (args); + err_disabled_feature ("__fltk_uigetfile__", "OpenGL and FLTK"); + #endif } diff -r b6a686543080 -r 263d18409fdf libinterp/dldfcn/__glpk__.cc --- a/libinterp/dldfcn/__glpk__.cc Fri May 13 09:27:38 2016 -0400 +++ b/libinterp/dldfcn/__glpk__.cc Fri May 13 09:36:14 2016 -0400 @@ -619,7 +619,11 @@ return ovl (xmin, fmin, errnum, extra); #else + + octave_unused_parameter (args); + err_disabled_feature ("glpk", "GNU Linear Programming Kit"); + #endif } diff -r b6a686543080 -r 263d18409fdf libinterp/dldfcn/__osmesa_print__.cc --- a/libinterp/dldfcn/__osmesa_print__.cc Fri May 13 09:27:38 2016 -0400 +++ b/libinterp/dldfcn/__osmesa_print__.cc Fri May 13 09:36:14 2016 -0400 @@ -197,6 +197,8 @@ #else + octave_unused_parameter (args); + err_disabled_feature ("__osmesa_print__", "offscreen rendering with OSMesa"); #endif diff -r b6a686543080 -r 263d18409fdf libinterp/dldfcn/__voronoi__.cc --- a/libinterp/dldfcn/__voronoi__.cc Fri May 13 09:27:38 2016 -0400 +++ b/libinterp/dldfcn/__voronoi__.cc Fri May 13 09:36:14 2016 -0400 @@ -49,11 +49,12 @@ #include "unwind-prot.h" #if defined (HAVE_QHULL) + # include "oct-qhull.h" + # if defined (NEED_QHULL_VERSION) char qh_version[] = "__voronoi__.oct 2007-07-24"; # endif -#endif static void close_fcn (FILE *f) @@ -75,6 +76,8 @@ return true; } +#endif + DEFUN_DLD (__voronoi__, args, , "-*- texinfo -*-\n\ @deftypefn {} {@var{C}, @var{F} =} __voronoi__ (@var{caller}, @var{pts})\n\ @@ -84,6 +87,7 @@ @end deftypefn") { #if defined (HAVE_QHULL) + int nargin = args.length (); if (nargin < 2 || nargin > 3) @@ -328,12 +332,16 @@ return retval; #else + + octave_unused_parameter (args); + std::string caller = (args.length () > 0 ? args(0).xstring_value ("__voronoi__: CALLER must be a string") : std::string ("__voronoi__")); err_disabled_feature (caller, "Qhull"); + #endif } diff -r b6a686543080 -r 263d18409fdf libinterp/dldfcn/amd.cc --- a/libinterp/dldfcn/amd.cc Fri May 13 09:27:38 2016 -0400 +++ b/libinterp/dldfcn/amd.cc Fri May 13 09:36:14 2016 -0400 @@ -86,6 +86,7 @@ @end deftypefn") { #ifdef HAVE_AMD + int nargin = args.length (); if (nargin < 1 || nargin > 2) @@ -178,7 +179,12 @@ return ovl (Pout); #else + + octave_unused_parameter (args); + octave_unused_parameter (nargout); + err_disabled_feature ("amd", "AMD"); + #endif } diff -r b6a686543080 -r 263d18409fdf libinterp/dldfcn/audiodevinfo.cc --- a/libinterp/dldfcn/audiodevinfo.cc Fri May 13 09:27:38 2016 -0400 +++ b/libinterp/dldfcn/audiodevinfo.cc Fri May 13 09:36:14 2016 -0400 @@ -406,6 +406,8 @@ return retval; #else + octave_unused_parameter (args); + err_disabled_feature ("audiodevinfo", "audio playback and recording through PortAudio"); #endif @@ -1811,6 +1813,8 @@ octave_value retval; #ifndef HAVE_PORTAUDIO + octave_unused_parameter (args); + err_disabled_feature ("__recorder_audiorecorder__", "audio playback and recording through PortAudio"); #else @@ -1874,6 +1878,8 @@ { octave_value retval; #ifndef HAVE_PORTAUDIO + octave_unused_parameter (args); + err_disabled_feature ("__recorder_getaudiodata__", "audio playback and recording through PortAudio"); #else @@ -1890,6 +1896,8 @@ { octave_value retval; #ifndef HAVE_PORTAUDIO + octave_unused_parameter (args); + err_disabled_feature ("__recorder_get_channels__", "audio playback and recording through PortAudio"); #else @@ -1906,6 +1914,8 @@ { octave_value retval; #ifndef HAVE_PORTAUDIO + octave_unused_parameter (args); + err_disabled_feature ("__recorder_get_fs__", "audio playback and recording through PortAudio"); #else @@ -1922,6 +1932,8 @@ { octave_value retval; #ifndef HAVE_PORTAUDIO + octave_unused_parameter (args); + err_disabled_feature ("__recorder_get_id__", "audio playback and recording through PortAudio"); #else @@ -1938,6 +1950,8 @@ { octave_value retval; #ifndef HAVE_PORTAUDIO + octave_unused_parameter (args); + err_disabled_feature ("__recorder_get_nbits__", "audio playback and recording through PortAudio"); #else @@ -1954,6 +1968,8 @@ { octave_value retval; #ifndef HAVE_PORTAUDIO + octave_unused_parameter (args); + err_disabled_feature ("__recorder_get_sample_number__", "audio playback and recording through PortAudio"); #else @@ -1970,6 +1986,8 @@ { octave_value retval; #ifndef HAVE_PORTAUDIO + octave_unused_parameter (args); + err_disabled_feature ("__recorder_get_tag__", "audio playback and recording through PortAudio"); #else @@ -1986,6 +2004,8 @@ { octave_value retval; #ifndef HAVE_PORTAUDIO + octave_unused_parameter (args); + err_disabled_feature ("__recorder_get_total_samples__", "audio playback and recording through PortAudio"); #else @@ -2002,6 +2022,8 @@ { octave_value retval; #ifndef HAVE_PORTAUDIO + octave_unused_parameter (args); + err_disabled_feature ("__recorder_get_userdata__", "audio playback and recording through PortAudio"); #else @@ -2018,6 +2040,8 @@ { octave_value retval; #ifndef HAVE_PORTAUDIO + octave_unused_parameter (args); + err_disabled_feature ("__recorder_isrecording__", "audio playback and recording through PortAudio"); #else @@ -2033,6 +2057,8 @@ @end deftypefn") { #ifndef HAVE_PORTAUDIO + octave_unused_parameter (args); + err_disabled_feature ("__recorder_pause__", "audio playback and recording through PortAudio"); #else @@ -2048,6 +2074,8 @@ @end deftypefn") { #ifndef HAVE_PORTAUDIO + octave_unused_parameter (args); + err_disabled_feature ("__recorder_recordblocking__", "audio playback and recording through PortAudio"); #else @@ -2065,6 +2093,8 @@ @end deftypefn") { #ifndef HAVE_PORTAUDIO + octave_unused_parameter (args); + err_disabled_feature ("__recorder_record__", "audio playback and recording through PortAudio"); #else @@ -2085,6 +2115,8 @@ @end deftypefn") { #ifndef HAVE_PORTAUDIO + octave_unused_parameter (args); + err_disabled_feature ("__recorder_resume__", "audio playback and recording through PortAudio"); #else @@ -2101,6 +2133,8 @@ @end deftypefn") { #ifndef HAVE_PORTAUDIO + octave_unused_parameter (args); + err_disabled_feature ("__recorder_set_fs__", "audio playback and recording through PortAudio"); #else @@ -2117,6 +2151,8 @@ @end deftypefn") { #ifndef HAVE_PORTAUDIO + octave_unused_parameter (args); + err_disabled_feature ("__recorder_set_tag__", "audio playback and recording through PortAudio"); #else @@ -2133,6 +2169,8 @@ @end deftypefn") { #ifndef HAVE_PORTAUDIO + octave_unused_parameter (args); + err_disabled_feature ("__recorder_set_userdata__", "audio playback and recording through PortAudio"); #else @@ -2149,6 +2187,8 @@ @end deftypefn") { #ifndef HAVE_PORTAUDIO + octave_unused_parameter (args); + err_disabled_feature ("__recorder_stop__", "audio playback and recording through PortAudio"); #else @@ -2168,6 +2208,8 @@ { octave_value retval; #ifndef HAVE_PORTAUDIO + octave_unused_parameter (args); + err_disabled_feature ("__player_audioplayer__", "audio playback and recording through PortAudio"); #else @@ -2236,6 +2278,8 @@ { octave_value retval; #ifndef HAVE_PORTAUDIO + octave_unused_parameter (args); + err_disabled_feature ("__player_get_channels__", "audio playback and recording through PortAudio"); #else @@ -2253,6 +2297,8 @@ { octave_value retval; #ifndef HAVE_PORTAUDIO + octave_unused_parameter (args); + err_disabled_feature ("__player_get_fs__", "audio playback and recording through PortAudio"); #else @@ -2270,6 +2316,8 @@ { octave_value retval; #ifndef HAVE_PORTAUDIO + octave_unused_parameter (args); + err_disabled_feature ("__player_get_id__", "audio playback and recording through PortAudio"); #else @@ -2287,6 +2335,8 @@ { octave_value retval; #ifndef HAVE_PORTAUDIO + octave_unused_parameter (args); + err_disabled_feature ("__player_get_nbits__", "audio playback and recording through PortAudio"); #else @@ -2304,6 +2354,8 @@ { octave_value retval; #ifndef HAVE_PORTAUDIO + octave_unused_parameter (args); + err_disabled_feature ("__player_get_sample_number__", "audio playback and recording through PortAudio"); #else @@ -2321,6 +2373,8 @@ { octave_value retval; #ifndef HAVE_PORTAUDIO + octave_unused_parameter (args); + err_disabled_feature ("__player_get_tag__", "audio playback and recording through PortAudio"); #else @@ -2338,6 +2392,8 @@ { octave_value retval; #ifndef HAVE_PORTAUDIO + octave_unused_parameter (args); + err_disabled_feature ("__player_get_total_samples__", "audio playback and recording through PortAudio"); #else @@ -2355,6 +2411,8 @@ { octave_value retval; #ifndef HAVE_PORTAUDIO + octave_unused_parameter (args); + err_disabled_feature ("__player_get_userdata__", "audio playback and recording through PortAudio"); #else @@ -2372,6 +2430,8 @@ { octave_value retval; #ifndef HAVE_PORTAUDIO + octave_unused_parameter (args); + err_disabled_feature ("__player_isplaying__", "audio playback and recording through PortAudio"); #else @@ -2388,6 +2448,8 @@ @end deftypefn") { #ifndef HAVE_PORTAUDIO + octave_unused_parameter (args); + err_disabled_feature ("__player_pause__", "audio playback and recording through PortAudio"); #else @@ -2406,6 +2468,8 @@ @end deftypefn") { #ifndef HAVE_PORTAUDIO + octave_unused_parameter (args); + err_disabled_feature ("__player_playblocking__", "audio playback and recording through PortAudio"); #else @@ -2458,6 +2522,8 @@ @end deftypefn") { #ifndef HAVE_PORTAUDIO + octave_unused_parameter (args); + err_disabled_feature ("__player_play__", "audio playback and recording through PortAudio"); #else @@ -2508,6 +2574,8 @@ @end deftypefn") { #ifndef HAVE_PORTAUDIO + octave_unused_parameter (args); + err_disabled_feature ("__player_resume__", "audio playback and recording through PortAudio"); #else @@ -2524,6 +2592,8 @@ @end deftypefn") { #ifndef HAVE_PORTAUDIO + octave_unused_parameter (args); + err_disabled_feature ("__player_set_fs__", "audio playback and recording through PortAudio"); #else @@ -2540,6 +2610,8 @@ @end deftypefn") { #ifndef HAVE_PORTAUDIO + octave_unused_parameter (args); + err_disabled_feature ("__player_set_tag__", "audio playback and recording through PortAudio"); #else @@ -2556,6 +2628,8 @@ @end deftypefn") { #ifndef HAVE_PORTAUDIO + octave_unused_parameter (args); + err_disabled_feature ("__player_set_userdata__", "audio playback and recording through PortAudio"); #else @@ -2572,6 +2646,8 @@ @end deftypefn") { #ifndef HAVE_PORTAUDIO + octave_unused_parameter (args); + err_disabled_feature ("__player_stop__", "audio playback and recording through PortAudio"); #else diff -r b6a686543080 -r 263d18409fdf libinterp/dldfcn/audioread.cc --- a/libinterp/dldfcn/audioread.cc Fri May 13 09:27:38 2016 -0400 +++ b/libinterp/dldfcn/audioread.cc Fri May 13 09:36:14 2016 -0400 @@ -42,11 +42,13 @@ #endif #ifdef HAVE_SNDFILE + static void safe_close (SNDFILE *file) { sf_close (file); } + #endif DEFUN_DLD (audioread, args, , @@ -172,8 +174,12 @@ return ovl (ret_audio, info.samplerate); #else + + octave_unused_parameter (args); + err_disabled_feature ("audioread", "reading and writing sound files through libsndfile"); + #endif } @@ -417,8 +423,12 @@ return ovl (); #else + + octave_unused_parameter (args); + err_disabled_feature ("audiowrite", "reading and writing sound files through libsndfile"); + #endif } @@ -429,6 +439,7 @@ @end deftypefn") { #ifdef HAVE_SNDFILE + if (args.length () != 1) print_usage (); @@ -489,7 +500,11 @@ return ovl (result); #else + + octave_unused_parameter (args); + err_disabled_feature ("audioinfo", "reading and writing sound files through libsndfile"); + #endif } diff -r b6a686543080 -r 263d18409fdf libinterp/dldfcn/ccolamd.cc --- a/libinterp/dldfcn/ccolamd.cc Fri May 13 09:27:38 2016 -0400 +++ b/libinterp/dldfcn/ccolamd.cc Fri May 13 09:36:14 2016 -0400 @@ -330,7 +330,12 @@ return retval; #else + + octave_unused_parameter (args); + octave_unused_parameter (nargout); + err_disabled_feature ("ccolamd", "CCOLAMD"); + #endif } @@ -561,6 +566,11 @@ return retval; #else + + octave_unused_parameter (args); + octave_unused_parameter (nargout); + err_disabled_feature ("csymamd", "CCOLAMD"); + #endif } diff -r b6a686543080 -r 263d18409fdf libinterp/dldfcn/colamd.cc --- a/libinterp/dldfcn/colamd.cc Fri May 13 09:27:38 2016 -0400 +++ b/libinterp/dldfcn/colamd.cc Fri May 13 09:36:14 2016 -0400 @@ -279,6 +279,7 @@ @end deftypefn") { #ifdef HAVE_COLAMD + int nargin = args.length (); if (nargin < 1 || nargin > 2) @@ -441,7 +442,12 @@ return retval; #else + + octave_unused_parameter (args); + octave_unused_parameter (nargout); + err_disabled_feature ("colamd", "COLAMD"); + #endif } @@ -629,7 +635,12 @@ return retval; #else + + octave_unused_parameter (args); + octave_unused_parameter (nargout); + err_disabled_feature ("symamd", "COLAMD"); + #endif } diff -r b6a686543080 -r 263d18409fdf libinterp/dldfcn/convhulln.cc --- a/libinterp/dldfcn/convhulln.cc Fri May 13 09:27:38 2016 -0400 +++ b/libinterp/dldfcn/convhulln.cc Fri May 13 09:36:14 2016 -0400 @@ -44,11 +44,12 @@ #include "unwind-prot.h" #if defined (HAVE_QHULL) + # include "oct-qhull.h" + # if defined (NEED_QHULL_VERSION) char qh_version[] = "convhulln.oct 2007-07-24"; # endif -#endif static void close_fcn (FILE *f) @@ -70,6 +71,8 @@ return true; } +#endif + DEFUN_DLD (convhulln, args, nargout, "-*- texinfo -*-\n\ @deftypefn {} {@var{h} =} convhulln (@var{pts})\n\ @@ -290,7 +293,12 @@ return retval; #else + + octave_unused_parameter (args); + octave_unused_parameter (nargout); + err_disabled_feature ("convhulln", "Qhull"); + #endif } diff -r b6a686543080 -r 263d18409fdf libinterp/dldfcn/dmperm.cc --- a/libinterp/dldfcn/dmperm.cc Fri May 13 09:27:38 2016 -0400 +++ b/libinterp/dldfcn/dmperm.cc Fri May 13 09:36:14 2016 -0400 @@ -42,6 +42,8 @@ # define CXSPARSE_NAME(name) cs_di ## name #endif +#if defined (HAVE_CXSPARSE) + static RowVector put_int (octave_idx_type *p, octave_idx_type n) { @@ -51,7 +53,6 @@ return ret; } -#if defined (HAVE_CXSPARSE) static octave_value_list dmperm_internal (bool rank, const octave_value arg, int nargout) { @@ -110,6 +111,7 @@ return retval; } + #endif DEFUN_DLD (dmperm, args, nargout, @@ -144,7 +146,12 @@ return ovl (dmperm_internal (false, args(0), nargout)); #else + + octave_unused_parameter (args); + octave_unused_parameter (nargout); + err_disabled_feature ("dmperm", "CXSparse"); + #endif } @@ -187,7 +194,12 @@ return ovl (dmperm_internal (true, args(0), nargout)); #else + + octave_unused_parameter (args); + octave_unused_parameter (nargout); + err_disabled_feature ("sprank", "CXSparse"); + #endif } diff -r b6a686543080 -r 263d18409fdf libinterp/dldfcn/fftw.cc --- a/libinterp/dldfcn/fftw.cc Fri May 13 09:27:38 2016 -0400 +++ b/libinterp/dldfcn/fftw.cc Fri May 13 09:36:14 2016 -0400 @@ -315,7 +315,11 @@ return retval; #else + + octave_unused_parameter (args); + err_disabled_feature ("fftw", "the FFTW3 planner"); + #endif } diff -r b6a686543080 -r 263d18409fdf libinterp/dldfcn/symbfact.cc --- a/libinterp/dldfcn/symbfact.cc Fri May 13 09:27:38 2016 -0400 +++ b/libinterp/dldfcn/symbfact.cc Fri May 13 09:36:14 2016 -0400 @@ -377,7 +377,12 @@ return retval; #else + + octave_unused_parameter (args); + octave_unused_parameter (nargout); + err_disabled_feature ("symbfact", "CHOLMOD"); + #endif } diff -r b6a686543080 -r 263d18409fdf libinterp/octave-value/ov-base-int.cc --- a/libinterp/octave-value/ov-base-int.cc Fri May 13 09:27:38 2016 -0400 +++ b/libinterp/octave-value/ov-base-int.cc Fri May 13 09:36:14 2016 -0400 @@ -369,6 +369,9 @@ H5Sclose (space_hid); #else + octave_unused_parameter (loc_id); + octave_unused_parameter (name); + this->warn_save ("hdf5"); #endif @@ -438,6 +441,9 @@ H5Dclose (data_hid); #else + octave_unused_parameter (loc_id); + octave_unused_parameter (name); + this->warn_load ("hdf5"); #endif @@ -576,6 +582,9 @@ H5Sclose (space_hid); #else + octave_unused_parameter (loc_id); + octave_unused_parameter (name); + this->warn_save ("hdf5"); #endif @@ -619,7 +628,11 @@ return true; #else + octave_unused_parameter (loc_id); + octave_unused_parameter (name); + this->warn_load ("hdf5"); + return false; #endif } diff -r b6a686543080 -r 263d18409fdf libinterp/octave-value/ov-bool-mat.cc --- a/libinterp/octave-value/ov-bool-mat.cc Fri May 13 09:27:38 2016 -0400 +++ b/libinterp/octave-value/ov-bool-mat.cc Fri May 13 09:36:14 2016 -0400 @@ -422,6 +422,9 @@ H5Sclose (space_hid); #else + octave_unused_parameter (loc_id); + octave_unused_parameter (name); + warn_save ("hdf5"); #endif @@ -493,6 +496,9 @@ H5Dclose (data_hid); #else + octave_unused_parameter (loc_id); + octave_unused_parameter (name); + warn_load ("hdf5"); #endif diff -r b6a686543080 -r 263d18409fdf libinterp/octave-value/ov-bool-sparse.cc --- a/libinterp/octave-value/ov-bool-sparse.cc Fri May 13 09:27:38 2016 -0400 +++ b/libinterp/octave-value/ov-bool-sparse.cc Fri May 13 09:36:14 2016 -0400 @@ -542,6 +542,9 @@ H5Gclose (group_hid); #else + octave_unused_parameter (loc_id); + octave_unused_parameter (name); + warn_save ("hdf5"); #endif @@ -781,6 +784,9 @@ H5Gclose (group_hid); #else + octave_unused_parameter (loc_id); + octave_unused_parameter (name); + warn_load ("hdf5"); #endif diff -r b6a686543080 -r 263d18409fdf libinterp/octave-value/ov-bool.cc --- a/libinterp/octave-value/ov-bool.cc Fri May 13 09:27:38 2016 -0400 +++ b/libinterp/octave-value/ov-bool.cc Fri May 13 09:36:14 2016 -0400 @@ -196,6 +196,9 @@ H5Sclose (space_hid); #else + octave_unused_parameter (loc_id); + octave_unused_parameter (name); + warn_save ("hdf5"); #endif @@ -235,6 +238,9 @@ H5Dclose (data_hid); #else + octave_unused_parameter (loc_id); + octave_unused_parameter (name); + warn_load ("hdf5"); #endif diff -r b6a686543080 -r 263d18409fdf libinterp/octave-value/ov-cell.cc --- a/libinterp/octave-value/ov-cell.cc Fri May 13 09:27:38 2016 -0400 +++ b/libinterp/octave-value/ov-cell.cc Fri May 13 09:36:14 2016 -0400 @@ -1055,7 +1055,12 @@ return true; #else + octave_unused_parameter (loc_id); + octave_unused_parameter (name); + octave_unused_parameter (save_as_floats); + warn_save ("hdf5"); + return false; #endif } @@ -1165,6 +1170,9 @@ } #else + octave_unused_parameter (loc_id); + octave_unused_parameter (name); + warn_load ("hdf5"); #endif diff -r b6a686543080 -r 263d18409fdf libinterp/octave-value/ov-class.cc --- a/libinterp/octave-value/ov-class.cc Fri May 13 09:27:38 2016 -0400 +++ b/libinterp/octave-value/ov-class.cc Fri May 13 09:36:14 2016 -0400 @@ -1468,7 +1468,12 @@ return true; #else + octave_unused_parameter (loc_id); + octave_unused_parameter (name); + octave_unused_parameter (save_as_floats); + warn_save ("hdf5"); + return false; #endif } @@ -1603,6 +1608,9 @@ H5Gclose (group_hid); #else + octave_unused_parameter (loc_id); + octave_unused_parameter (name); + warn_load ("hdf5"); #endif diff -r b6a686543080 -r 263d18409fdf libinterp/octave-value/ov-complex.cc --- a/libinterp/octave-value/ov-complex.cc Fri May 13 09:27:38 2016 -0400 +++ b/libinterp/octave-value/ov-complex.cc Fri May 13 09:36:14 2016 -0400 @@ -392,6 +392,9 @@ H5Sclose (space_hid); #else + octave_unused_parameter (loc_id); + octave_unused_parameter (name); + warn_save ("hdf5"); #endif @@ -446,6 +449,9 @@ H5Dclose (data_hid); #else + octave_unused_parameter (loc_id); + octave_unused_parameter (name); + warn_load ("hdf5"); #endif diff -r b6a686543080 -r 263d18409fdf libinterp/octave-value/ov-cx-mat.cc --- a/libinterp/octave-value/ov-cx-mat.cc Fri May 13 09:27:38 2016 -0400 +++ b/libinterp/octave-value/ov-cx-mat.cc Fri May 13 09:36:14 2016 -0400 @@ -616,7 +616,12 @@ return retval; #else + octave_unused_parameter (loc_id); + octave_unused_parameter (name); + octave_unused_parameter (save_as_floats); + warn_save ("hdf5"); + return false; #endif } @@ -696,6 +701,9 @@ H5Dclose (data_hid); #else + octave_unused_parameter (loc_id); + octave_unused_parameter (name); + warn_load ("hdf5"); #endif diff -r b6a686543080 -r 263d18409fdf libinterp/octave-value/ov-cx-sparse.cc --- a/libinterp/octave-value/ov-cx-sparse.cc Fri May 13 09:27:38 2016 -0400 +++ b/libinterp/octave-value/ov-cx-sparse.cc Fri May 13 09:36:14 2016 -0400 @@ -611,6 +611,10 @@ H5Gclose (group_hid); #else + octave_unused_parameter (loc_id); + octave_unused_parameter (name); + octave_unused_parameter (save_as_floats); + warn_save ("hdf5"); #endif @@ -859,6 +863,9 @@ H5Gclose (group_hid); #else + octave_unused_parameter (loc_id); + octave_unused_parameter (name); + warn_load ("hdf5"); #endif diff -r b6a686543080 -r 263d18409fdf libinterp/octave-value/ov-fcn-handle.cc --- a/libinterp/octave-value/ov-fcn-handle.cc Fri May 13 09:27:38 2016 -0400 +++ b/libinterp/octave-value/ov-fcn-handle.cc Fri May 13 09:36:14 2016 -0400 @@ -916,7 +916,12 @@ return retval; #else + octave_unused_parameter (loc_id); + octave_unused_parameter (name); + octave_unused_parameter (save_as_floats); + warn_save ("hdf5"); + return false; #endif } @@ -1273,7 +1278,11 @@ return success; #else + octave_unused_parameter (loc_id); + octave_unused_parameter (name); + warn_load ("hdf5"); + return false; #endif } diff -r b6a686543080 -r 263d18409fdf libinterp/octave-value/ov-fcn-inline.cc --- a/libinterp/octave-value/ov-fcn-inline.cc Fri May 13 09:27:38 2016 -0400 +++ b/libinterp/octave-value/ov-fcn-inline.cc Fri May 13 09:36:14 2016 -0400 @@ -413,6 +413,9 @@ H5Gclose (group_hid); #else + octave_unused_parameter (loc_id); + octave_unused_parameter (name); + warn_save ("hdf5"); #endif @@ -605,7 +608,11 @@ return true; #else + octave_unused_parameter (loc_id); + octave_unused_parameter (name); + warn_load ("hdf5"); + return false; #endif } diff -r b6a686543080 -r 263d18409fdf libinterp/octave-value/ov-float.cc --- a/libinterp/octave-value/ov-float.cc Fri May 13 09:27:38 2016 -0400 +++ b/libinterp/octave-value/ov-float.cc Fri May 13 09:36:14 2016 -0400 @@ -215,6 +215,9 @@ H5Sclose (space_hid); #else + octave_unused_parameter (loc_id); + octave_unused_parameter (name); + warn_save ("hdf5"); #endif @@ -256,7 +259,11 @@ return true; #else + octave_unused_parameter (loc_id); + octave_unused_parameter (name); + warn_load ("hdf5"); + return false; #endif } diff -r b6a686543080 -r 263d18409fdf libinterp/octave-value/ov-flt-complex.cc --- a/libinterp/octave-value/ov-flt-complex.cc Fri May 13 09:27:38 2016 -0400 +++ b/libinterp/octave-value/ov-flt-complex.cc Fri May 13 09:36:14 2016 -0400 @@ -342,6 +342,9 @@ H5Sclose (space_hid); #else + octave_unused_parameter (loc_id); + octave_unused_parameter (name); + warn_save ("hdf5"); #endif @@ -396,6 +399,9 @@ H5Dclose (data_hid); #else + octave_unused_parameter (loc_id); + octave_unused_parameter (name); + warn_load ("hdf5"); #endif diff -r b6a686543080 -r 263d18409fdf libinterp/octave-value/ov-flt-cx-mat.cc --- a/libinterp/octave-value/ov-flt-cx-mat.cc Fri May 13 09:27:38 2016 -0400 +++ b/libinterp/octave-value/ov-flt-cx-mat.cc Fri May 13 09:36:14 2016 -0400 @@ -567,6 +567,9 @@ H5Sclose (space_hid); #else + octave_unused_parameter (loc_id); + octave_unused_parameter (name); + warn_save ("hdf5"); #endif @@ -648,6 +651,9 @@ H5Dclose (data_hid); #else + octave_unused_parameter (loc_id); + octave_unused_parameter (name); + warn_load ("hdf5"); #endif diff -r b6a686543080 -r 263d18409fdf libinterp/octave-value/ov-flt-re-mat.cc --- a/libinterp/octave-value/ov-flt-re-mat.cc Fri May 13 09:27:38 2016 -0400 +++ b/libinterp/octave-value/ov-flt-re-mat.cc Fri May 13 09:36:14 2016 -0400 @@ -569,6 +569,9 @@ H5Sclose (space_hid); #else + octave_unused_parameter (loc_id); + octave_unused_parameter (name); + warn_save ("hdf5"); #endif @@ -637,6 +640,9 @@ H5Dclose (data_hid); #else + octave_unused_parameter (loc_id); + octave_unused_parameter (name); + warn_load ("hdf5"); #endif diff -r b6a686543080 -r 263d18409fdf libinterp/octave-value/ov-java.cc --- a/libinterp/octave-value/ov-java.cc Fri May 13 09:27:38 2016 -0400 +++ b/libinterp/octave-value/ov-java.cc Fri May 13 09:36:14 2016 -0400 @@ -793,10 +793,12 @@ return false; #else + // This shouldn't happen because construction of octave_java // objects is supposed to be impossible if Java is not available. panic_impossible (); + #endif } @@ -821,10 +823,14 @@ return false; #else + + octave_unused_parameter (cls_name); + // This shouldn't happen because construction of octave_java // objects is supposed to be impossible if Java is not available. panic_impossible (); + #endif } @@ -1818,6 +1824,9 @@ #else + octave_unused_parameter (jobj); + octave_unused_parameter (jcls); + err_disabled_feature ("Java Objects", "Java"); #endif @@ -1851,10 +1860,12 @@ return dim_vector (1, 1); #else + // This shouldn't happen because construction of octave_java // objects is supposed to be impossible if Java is not available. panic_impossible (); + #endif } @@ -1909,10 +1920,16 @@ return retval; #else + + octave_unused_parameter (type); + octave_unused_parameter (idx); + octave_unused_parameter (nargout); + // This shouldn't happen because construction of octave_java // objects is supposed to be impossible if Java is not available. panic_impossible (); + #endif } @@ -1992,10 +2009,16 @@ return retval; #else + + octave_unused_parameter (type); + octave_unused_parameter (idx); + octave_unused_parameter (rhs); + // This shouldn't happen because construction of octave_java // objects is supposed to be impossible if Java is not available. panic_impossible (); + #endif } @@ -2012,10 +2035,12 @@ return string_vector (); #else + // This shouldn't happen because construction of octave_java // objects is supposed to be impossible if Java is not available. panic_impossible (); + #endif } @@ -2032,10 +2057,15 @@ return octave_value (""); #else + + octave_unused_parameter (force); + octave_unused_parameter (type); + // This shouldn't happen because construction of octave_java // objects is supposed to be impossible if Java is not available. panic_impossible (); + #endif } @@ -2135,10 +2165,16 @@ return retval; #else + + octave_unused_parameter (jni_env_arg); + octave_unused_parameter (name); + octave_unused_parameter (args); + // This shouldn't happen because construction of octave_java // objects is supposed to be impossible if Java is not available. panic_impossible (); + #endif } @@ -2150,10 +2186,15 @@ return do_javaMethod (thread_jni_env (), name, args); #else + + octave_unused_parameter (name); + octave_unused_parameter (args); + // This shouldn't happen because construction of octave_java // objects is supposed to be impossible if Java is not available. panic_impossible (); + #endif } @@ -2193,15 +2234,23 @@ return retval; #else + + octave_unused_parameter (jni_env_arg); + octave_unused_parameter (class_name); + octave_unused_parameter (name); + octave_unused_parameter (args); + // This shouldn't happen because construction of octave_java // objects is supposed to be impossible if Java is not available. panic_impossible (); + #endif } octave_value -octave_java::do_javaMethod (const std::string& class_name, const std::string& name, +octave_java::do_javaMethod (const std::string& class_name, + const std::string& name, const octave_value_list& args) { #if defined (HAVE_JAVA) @@ -2209,10 +2258,16 @@ return do_javaMethod (thread_jni_env (), class_name, name, args); #else + + octave_unused_parameter (class_name); + octave_unused_parameter (name); + octave_unused_parameter (args); + // This shouldn't happen because construction of octave_java // objects is supposed to be impossible if Java is not available. panic_impossible (); + #endif } @@ -2251,10 +2306,16 @@ return retval; #else + + octave_unused_parameter (jni_env_arg); + octave_unused_parameter (name); + octave_unused_parameter (args); + // This shouldn't happen because construction of octave_java // objects is supposed to be impossible if Java is not available. panic_impossible (); + #endif } @@ -2266,10 +2327,15 @@ return do_javaObject (thread_jni_env (), name, args); #else + + octave_unused_parameter (name); + octave_unused_parameter (args); + // This shouldn't happen because construction of octave_java // objects is supposed to be impossible if Java is not available. panic_impossible (); + #endif } @@ -2302,10 +2368,15 @@ return retval; #else + + octave_unused_parameter (jni_env_arg); + octave_unused_parameter (name); + // This shouldn't happen because construction of octave_java // objects is supposed to be impossible if Java is not available. panic_impossible (); + #endif } @@ -2317,10 +2388,14 @@ return do_java_get (thread_jni_env (), name); #else + + octave_unused_parameter (name); + // This shouldn't happen because construction of octave_java // objects is supposed to be impossible if Java is not available. panic_impossible (); + #endif } @@ -2354,10 +2429,16 @@ return retval; #else + + octave_unused_parameter (jni_env_arg); + octave_unused_parameter (class_name); + octave_unused_parameter (name); + // This shouldn't happen because construction of octave_java // objects is supposed to be impossible if Java is not available. panic_impossible (); + #endif } @@ -2369,10 +2450,15 @@ return do_java_get (thread_jni_env (), class_name, name); #else + + octave_unused_parameter (class_name); + octave_unused_parameter (name); + // This shouldn't happen because construction of octave_java // objects is supposed to be impossible if Java is not available. panic_impossible (); + #endif } @@ -2407,10 +2493,16 @@ return retval; #else + + octave_unused_parameter (jni_env_arg); + octave_unused_parameter (name); + octave_unused_parameter (val); + // This shouldn't happen because construction of octave_java // objects is supposed to be impossible if Java is not available. panic_impossible (); + #endif } @@ -2422,10 +2514,15 @@ return do_java_set (thread_jni_env (), name, val); #else + + octave_unused_parameter (name); + octave_unused_parameter (val); + // This shouldn't happen because construction of octave_java // objects is supposed to be impossible if Java is not available. panic_impossible (); + #endif } @@ -2461,10 +2558,17 @@ return retval; #else + + octave_unused_parameter (jni_env_arg); + octave_unused_parameter (class_name); + octave_unused_parameter (name); + octave_unused_parameter (val); + // This shouldn't happen because construction of octave_java // objects is supposed to be impossible if Java is not available. panic_impossible (); + #endif } @@ -2477,10 +2581,16 @@ return do_java_set (thread_jni_env (), class_name, name, val); #else + + octave_unused_parameter (class_name); + octave_unused_parameter (name); + octave_unused_parameter (val); + // This shouldn't happen because construction of octave_java // objects is supposed to be impossible if Java is not available. panic_impossible (); + #endif } @@ -2517,10 +2627,15 @@ } #else + + octave_unused_parameter (jobj_arg); + octave_unused_parameter (jcls_arg); + // This shouldn't happen because construction of octave_java // objects is supposed to be impossible if Java is not available. panic_impossible (); + #endif } @@ -2544,10 +2659,12 @@ } #else + // This shouldn't happen because construction of octave_java // objects is supposed to be impossible if Java is not available. panic_impossible (); + #endif } @@ -2563,6 +2680,7 @@ @end deftypefn") { #if defined (HAVE_JAVA) + octave_value retval; retval = 0; @@ -2572,8 +2690,11 @@ retval = 1; return retval; + #else + err_disabled_feature ("__java_init__", "Java"); + #endif } @@ -2587,12 +2708,15 @@ @end deftypefn") { #if defined (HAVE_JAVA) + terminate_jvm (); return ovl (); #else - error ("__java_init__", "Java"); + + err_disabled_feature ("__java_exit__", "Java"); + #endif } @@ -2635,6 +2759,8 @@ #else + octave_unused_parameter (args); + err_disabled_feature ("javaObject", "Java"); #endif @@ -2709,6 +2835,8 @@ #else + octave_unused_parameter (args); + err_disabled_feature ("javaMethod", "Java"); #endif @@ -2773,6 +2901,8 @@ #else + octave_unused_parameter (args); + err_disabled_feature ("__java_get__", "Java"); #endif @@ -2831,6 +2961,8 @@ #else + octave_unused_parameter (args); + err_disabled_feature ("__java_set__", "Java"); #endif @@ -2865,6 +2997,8 @@ #else + octave_unused_parameter (args); + err_disabled_feature ("java2mat", "Java"); #endif @@ -2887,9 +3021,16 @@ @end deftypefn") { #if defined (HAVE_JAVA) + return SET_INTERNAL_VARIABLE (java_matrix_autoconversion); + #else + + octave_unused_parameter (args); + octave_unused_parameter (nargout); + err_disabled_feature ("java_matrix_autoconversion", "Java"); + #endif } @@ -2911,9 +3052,16 @@ @end deftypefn") { #if defined (HAVE_JAVA) + return SET_INTERNAL_VARIABLE (java_unsigned_autoconversion); + #else + + octave_unused_parameter (args); + octave_unused_parameter (nargout); + err_disabled_feature ("java_unsigned_autoconversion", "Java"); + #endif } @@ -2933,9 +3081,16 @@ @end deftypefn") { #if defined (HAVE_JAVA) + return SET_INTERNAL_VARIABLE (debug_java); + #else + + octave_unused_parameter (args); + octave_unused_parameter (nargout); + err_disabled_feature ("debug_java", "Java"); + #endif } diff -r b6a686543080 -r 263d18409fdf libinterp/octave-value/ov-range.cc --- a/libinterp/octave-value/ov-range.cc Fri May 13 09:27:38 2016 -0400 +++ b/libinterp/octave-value/ov-range.cc Fri May 13 09:36:14 2016 -0400 @@ -599,6 +599,9 @@ H5Sclose (space_hid); #else + octave_unused_parameter (loc_id); + octave_unused_parameter (name); + warn_save ("hdf5"); #endif @@ -663,6 +666,9 @@ H5Dclose (data_hid); #else + octave_unused_parameter (loc_id); + octave_unused_parameter (name); + warn_load ("hdf5"); #endif diff -r b6a686543080 -r 263d18409fdf libinterp/octave-value/ov-re-mat.cc --- a/libinterp/octave-value/ov-re-mat.cc Fri May 13 09:27:38 2016 -0400 +++ b/libinterp/octave-value/ov-re-mat.cc Fri May 13 09:36:14 2016 -0400 @@ -693,6 +693,10 @@ H5Sclose (space_hid); #else + octave_unused_parameter (loc_id); + octave_unused_parameter (name); + octave_unused_parameter (save_as_floats); + warn_save ("hdf5"); #endif @@ -761,6 +765,9 @@ H5Dclose (data_hid); #else + octave_unused_parameter (loc_id); + octave_unused_parameter (name); + warn_load ("hdf5"); #endif diff -r b6a686543080 -r 263d18409fdf libinterp/octave-value/ov-re-sparse.cc --- a/libinterp/octave-value/ov-re-sparse.cc Fri May 13 09:27:38 2016 -0400 +++ b/libinterp/octave-value/ov-re-sparse.cc Fri May 13 09:36:14 2016 -0400 @@ -615,6 +615,10 @@ H5Gclose (group_hid); #else + octave_unused_parameter (loc_id); + octave_unused_parameter (name); + octave_unused_parameter (save_as_floats); + warn_save ("hdf5"); #endif @@ -848,6 +852,9 @@ H5Gclose (group_hid); #else + octave_unused_parameter (loc_id); + octave_unused_parameter (name); + warn_load ("hdf5"); #endif diff -r b6a686543080 -r 263d18409fdf libinterp/octave-value/ov-scalar.cc --- a/libinterp/octave-value/ov-scalar.cc Fri May 13 09:27:38 2016 -0400 +++ b/libinterp/octave-value/ov-scalar.cc Fri May 13 09:36:14 2016 -0400 @@ -238,6 +238,9 @@ H5Sclose (space_hid); #else + octave_unused_parameter (loc_id); + octave_unused_parameter (name); + warn_save ("hdf5"); #endif @@ -279,7 +282,11 @@ return true; #else + octave_unused_parameter (loc_id); + octave_unused_parameter (name); + warn_load ("hdf5"); + return false; #endif } diff -r b6a686543080 -r 263d18409fdf libinterp/octave-value/ov-str-mat.cc --- a/libinterp/octave-value/ov-str-mat.cc Fri May 13 09:27:38 2016 -0400 +++ b/libinterp/octave-value/ov-str-mat.cc Fri May 13 09:36:14 2016 -0400 @@ -579,6 +579,9 @@ H5Sclose (space_hid); #else + octave_unused_parameter (loc_id); + octave_unused_parameter (name); + warn_save ("hdf5"); #endif @@ -754,6 +757,9 @@ } #else + octave_unused_parameter (loc_id); + octave_unused_parameter (name); + warn_load ("hdf5"); #endif diff -r b6a686543080 -r 263d18409fdf libinterp/octave-value/ov-struct.cc --- a/libinterp/octave-value/ov-struct.cc Fri May 13 09:27:38 2016 -0400 +++ b/libinterp/octave-value/ov-struct.cc Fri May 13 09:36:14 2016 -0400 @@ -911,7 +911,12 @@ return true; #else + octave_unused_parameter (loc_id); + octave_unused_parameter (name); + octave_unused_parameter (save_as_floats); + warn_save ("hdf5"); + return false; #endif } @@ -959,6 +964,9 @@ } #else + octave_unused_parameter (loc_id); + octave_unused_parameter (name); + warn_load ("hdf5"); #endif @@ -1508,7 +1516,12 @@ return true; #else + octave_unused_parameter (loc_id); + octave_unused_parameter (name); + octave_unused_parameter (save_as_floats); + warn_save ("hdf5"); + return false; #endif } @@ -1554,6 +1567,9 @@ } #else + octave_unused_parameter (loc_id); + octave_unused_parameter (name); + warn_load ("hdf5"); #endif diff -r b6a686543080 -r 263d18409fdf liboctave/array/CSparse.cc --- a/liboctave/array/CSparse.cc Fri May 13 09:27:38 2016 -0400 +++ b/liboctave/array/CSparse.cc Fri May 13 09:36:14 2016 -0400 @@ -1141,6 +1141,7 @@ int) const { ComplexDET retval; + #ifdef HAVE_UMFPACK octave_idx_type nr = rows (); @@ -1252,12 +1253,18 @@ } } } - return retval; #else + + octave_unused_parameter (err); + octave_unused_parameter (rcond); + (*current_liboctave_error_handler) ("support for UMFPACK was unavailable or disabled when liboctave was built"); + #endif + + return retval; } ComplexMatrix @@ -5431,6 +5438,7 @@ err = 0; #ifdef HAVE_UMFPACK + // Setup the control parameters Control = Matrix (UMFPACK_CONTROL, 1); double *control = Control.fortran_vec (); @@ -5529,12 +5537,20 @@ if (err != 0) UMFPACK_ZNAME (free_numeric) (&Numeric); - return Numeric; - #else + + octave_unused_parameter (rcond); + octave_unused_parameter (Control); + octave_unused_parameter (Info); + octave_unused_parameter (sing_handler); + octave_unused_parameter (calc_cond); + (*current_liboctave_error_handler) ("support for UMFPACK was unavailable or disabled when liboctave was built"); + #endif + + return Numeric; } ComplexMatrix @@ -5771,6 +5787,10 @@ mattype.mark_as_rectangular (); #else + octave_unused_parameter (rcond); + octave_unused_parameter (sing_handler); + octave_unused_parameter (calc_cond); + (*current_liboctave_error_handler) ("support for UMFPACK was unavailable or disabled " "when liboctave was built"); @@ -6065,6 +6085,10 @@ mattype.mark_as_rectangular (); #else + octave_unused_parameter (rcond); + octave_unused_parameter (sing_handler); + octave_unused_parameter (calc_cond); + (*current_liboctave_error_handler) ("support for UMFPACK was unavailable or disabled " "when liboctave was built"); @@ -6290,6 +6314,10 @@ mattype.mark_as_rectangular (); #else + octave_unused_parameter (rcond); + octave_unused_parameter (sing_handler); + octave_unused_parameter (calc_cond); + (*current_liboctave_error_handler) ("support for UMFPACK was unavailable or disabled " "when liboctave was built"); @@ -6576,6 +6604,10 @@ mattype.mark_as_rectangular (); #else + octave_unused_parameter (rcond); + octave_unused_parameter (sing_handler); + octave_unused_parameter (calc_cond); + (*current_liboctave_error_handler) ("support for UMFPACK was unavailable or disabled " "when liboctave was built"); diff -r b6a686543080 -r 263d18409fdf liboctave/array/dSparse.cc --- a/liboctave/array/dSparse.cc Fri May 13 09:27:38 2016 -0400 +++ b/liboctave/array/dSparse.cc Fri May 13 09:36:14 2016 -0400 @@ -1229,6 +1229,7 @@ DET retval; #ifdef HAVE_UMFPACK + octave_idx_type nr = rows (); octave_idx_type nc = cols (); @@ -1333,13 +1334,18 @@ } } - return retval; - #else + + octave_unused_parameter (err); + octave_unused_parameter (rcond); + (*current_liboctave_error_handler) ("support for UMFPACK was unavailable or disabled " "when liboctave was built"); + #endif + + return retval; } Matrix @@ -5627,6 +5633,7 @@ err = 0; #ifdef HAVE_UMFPACK + // Setup the control parameters Control = Matrix (UMFPACK_CONTROL, 1); double *control = Control.fortran_vec (); @@ -5721,13 +5728,21 @@ if (err != 0) UMFPACK_DNAME (free_numeric) (&Numeric); - return Numeric; - #else + + octave_unused_parameter (rcond); + octave_unused_parameter (Control); + octave_unused_parameter (Info); + octave_unused_parameter (sing_handler); + octave_unused_parameter (calc_cond); + (*current_liboctave_error_handler) ("support for UMFPACK was unavailable or disabled " "when liboctave was built"); + #endif + + return Numeric; } Matrix @@ -5938,6 +5953,10 @@ mattype.mark_as_rectangular (); #else + octave_unused_parameter (rcond); + octave_unused_parameter (sing_handler); + octave_unused_parameter (calc_cond); + (*current_liboctave_error_handler) ("support for UMFPACK was unavailable or disabled " "when liboctave was built"); @@ -6203,6 +6222,10 @@ mattype.mark_as_rectangular (); #else + octave_unused_parameter (rcond); + octave_unused_parameter (sing_handler); + octave_unused_parameter (calc_cond); + (*current_liboctave_error_handler) ("support for UMFPACK was unavailable or disabled " "when liboctave was built"); @@ -6440,6 +6463,10 @@ mattype.mark_as_rectangular (); #else + octave_unused_parameter (rcond); + octave_unused_parameter (sing_handler); + octave_unused_parameter (calc_cond); + (*current_liboctave_error_handler) ("support for UMFPACK was unavailable or disabled " "when liboctave was built"); @@ -6715,6 +6742,10 @@ else mattype.mark_as_rectangular (); #else + octave_unused_parameter (rcond); + octave_unused_parameter (sing_handler); + octave_unused_parameter (calc_cond); + (*current_liboctave_error_handler) ("support for UMFPACK was unavailable or disabled " "when liboctave was built"); diff -r b6a686543080 -r 263d18409fdf liboctave/cruft/misc/lo-error.c --- a/liboctave/cruft/misc/lo-error.c Fri May 13 09:27:38 2016 -0400 +++ b/liboctave/cruft/misc/lo-error.c Fri May 13 09:36:14 2016 -0400 @@ -110,8 +110,9 @@ void liboctave_fatal_with_id (const char *id, const char *fmt, ...) { + octave_unused_parameter (id); + va_list args; - (void) id; /*unused*/ va_start (args, fmt); verror ("fatal", fmt, args); va_end (args); @@ -131,8 +132,9 @@ void liboctave_warning_with_id (const char *id, const char *fmt, ...) { + octave_unused_parameter (id); + va_list args; - (void) id; /*unused*/ va_start (args, fmt); verror ("warning", fmt, args); va_end (args); diff -r b6a686543080 -r 263d18409fdf liboctave/numeric/sparse-chol.cc --- a/liboctave/numeric/sparse-chol.cc Fri May 13 09:27:38 2016 -0400 +++ b/liboctave/numeric/sparse-chol.cc Fri May 13 09:36:14 2016 -0400 @@ -333,8 +333,16 @@ return info; #else + + octave_unused_parameter (a); + octave_unused_parameter (natural); + octave_unused_parameter (force); + (*current_liboctave_error_handler) ("support for CHOLMOD was unavailable or disabled when liboctave was built"); + + return info; + #endif } diff -r b6a686543080 -r 263d18409fdf liboctave/numeric/sparse-dmsolve.cc --- a/liboctave/numeric/sparse-dmsolve.cc Fri May 13 09:27:38 2016 -0400 +++ b/liboctave/numeric/sparse-dmsolve.cc Fri May 13 09:36:14 2016 -0400 @@ -344,6 +344,8 @@ } } +#ifdef HAVE_CXSPARSE + static void solve_singularity_warning (double) { @@ -351,10 +353,14 @@ // an error for numerically rank defficient matrices } +#endif + template RT dmsolve (const ST &a, const T &b, octave_idx_type &info) { + RT retval; + #ifdef HAVE_CXSPARSE octave_idx_type nr = a.rows (); @@ -363,8 +369,6 @@ octave_idx_type b_nr = b.rows (); octave_idx_type b_nc = b.cols (); - RT retval; - if (nr < 0 || nc < 0 || nr != b_nr) (*current_liboctave_error_handler) ("matrix dimension mismatch in solution of minimum norm problem"); @@ -466,14 +470,18 @@ CXSPARSE_DNAME (_dfree) (dm); } - return retval; +#else -#else + octave_unused_parameter (a); + octave_unused_parameter (b); + octave_unused_parameter (info); (*current_liboctave_error_handler) ("support for CXSparse was unavailable or disabled when liboctave was built"); #endif + + return retval; } // Instantiations we need. diff -r b6a686543080 -r 263d18409fdf liboctave/numeric/sparse-lu.cc --- a/liboctave/numeric/sparse-lu.cc Fri May 13 09:27:38 2016 -0400 +++ b/liboctave/numeric/sparse-lu.cc Fri May 13 09:36:14 2016 -0400 @@ -553,6 +553,10 @@ #else + octave_unused_parameter (a); + octave_unused_parameter (piv_thres); + octave_unused_parameter (scale); + (*current_liboctave_error_handler) ("support for UMFPACK was unavailable or disabled when liboctave was built"); @@ -770,6 +774,15 @@ #else + octave_unused_parameter (a); + octave_unused_parameter (Qinit); + octave_unused_parameter (piv_thres); + octave_unused_parameter (scale); + octave_unused_parameter (FixedQ); + octave_unused_parameter (droptol); + octave_unused_parameter (milu); + octave_unused_parameter (udiag); + (*current_liboctave_error_handler) ("support for UMFPACK was unavailable or disabled when liboctave was built"); diff -r b6a686543080 -r 263d18409fdf liboctave/numeric/sparse-qr.cc --- a/liboctave/numeric/sparse-qr.cc Fri May 13 09:27:38 2016 -0400 +++ b/liboctave/numeric/sparse-qr.cc Fri May 13 09:36:14 2016 -0400 @@ -200,6 +200,8 @@ #else + octave_unused_parameter (order); + (*current_liboctave_error_handler) ("sparse_qr: support for CXSparse was unavailable or disabled when liboctave was built"); @@ -289,6 +291,8 @@ #else + octave_unused_parameter (econ); + return SparseMatrix (); #endif @@ -351,6 +355,8 @@ #else + octave_unused_parameter (b); + return Matrix (); #endif @@ -475,6 +481,8 @@ #else + octave_unused_parameter (b); + return Matrix (); #endif @@ -541,6 +549,8 @@ #else + octave_unused_parameter (b); + return Matrix (); #endif @@ -628,6 +638,8 @@ #else + octave_unused_parameter (b); + return SparseMatrix (); #endif @@ -721,6 +733,8 @@ #else + octave_unused_parameter (b); + return SparseMatrix (); #endif @@ -810,6 +824,8 @@ #else + octave_unused_parameter (b); + return ComplexMatrix (); #endif @@ -906,6 +922,8 @@ #else + octave_unused_parameter (b); + return ComplexMatrix (); #endif @@ -948,6 +966,8 @@ #else + octave_unused_parameter (order); + (*current_liboctave_error_handler) ("sparse_qr: support for CXSparse was unavailable or disabled when liboctave was built"); @@ -1036,6 +1056,8 @@ #else + octave_unused_parameter (econ); + return SparseComplexMatrix (); #endif @@ -1092,6 +1114,8 @@ #else + octave_unused_parameter (b); + return ComplexMatrix (); #endif @@ -1266,6 +1290,8 @@ #else + octave_unused_parameter (b); + return SparseComplexMatrix (); #endif @@ -1385,6 +1411,8 @@ #else + octave_unused_parameter (b); + return SparseComplexMatrix (); #endif @@ -1447,6 +1475,8 @@ #else + octave_unused_parameter (b); + return ComplexMatrix (); #endif @@ -1518,6 +1548,8 @@ #else + octave_unused_parameter (b); + return ComplexMatrix (); #endif @@ -1607,6 +1639,8 @@ #else + octave_unused_parameter (b); + return SparseComplexMatrix (); #endif @@ -1704,6 +1738,8 @@ #else + octave_unused_parameter (b); + return SparseComplexMatrix (); #endif @@ -1766,6 +1802,8 @@ #else + octave_unused_parameter (b); + return ComplexMatrix (); #endif @@ -1836,6 +1874,8 @@ #else + octave_unused_parameter (b); + return ComplexMatrix (); #endif @@ -1925,6 +1965,8 @@ #else + octave_unused_parameter (b); + return SparseComplexMatrix (); #endif @@ -2022,6 +2064,8 @@ #else + octave_unused_parameter (b); + return SparseComplexMatrix (); #endif diff -r b6a686543080 -r 263d18409fdf liboctave/util/sparse-util.cc --- a/liboctave/util/sparse-util.cc Fri May 13 09:27:38 2016 -0400 +++ b/liboctave/util/sparse-util.cc Fri May 13 09:36:14 2016 -0400 @@ -36,12 +36,21 @@ int line, const char *message) { #ifdef HAVE_CHOLMOD + // Ignore CHOLMOD_NOT_POSDEF, since we handle that in Fchol as an // error or exit status. if (status != CHOLMOD_NOT_POSDEF) (*current_liboctave_warning_with_id_handler) ("Octave:cholmod-message", "warning %i, at line %i in file %s: %s", status, line, file, message); + +#else + + octave_unused_parameter (status); + octave_unused_parameter (file); + octave_unused_parameter (line); + octave_unused_parameter (message); + #endif } diff -r b6a686543080 -r 263d18409fdf oct-conf-post.in.h --- a/oct-conf-post.in.h Fri May 13 09:27:38 2016 -0400 +++ b/oct-conf-post.in.h Fri May 13 09:36:14 2016 -0400 @@ -54,6 +54,15 @@ # define OCTAVE_UNUSED #endif +#if defined (__cplusplus) +template +static inline void +octave_unused_parameter (const T&) +{ } +#else +# define octave_unused_parameter(param) (void) param; +#endif + #if ! defined (HAVE_DEV_T) typedef short dev_t; #endif