# HG changeset patch # User John W. Eaton # Date 1296323789 18000 # Node ID db14b8095eddcb081154d7ff1c24130f78b09d8a # Parent b3ac1d094a3f86132d2dc637a3fc35bfa885379d #undef Complex after including FLTK headers diff -r b3ac1d094a3f -r db14b8095edd src/ChangeLog --- a/src/ChangeLog Sat Jan 29 12:27:16 2011 -0500 +++ b/src/ChangeLog Sat Jan 29 12:56:29 2011 -0500 @@ -1,3 +1,9 @@ +2011-01-29 John W. Eaton + + * DLD-FUNCTIONS/__init_fltk__.cc: Undefine Complex after + including FLTK headers. + * DLD-FUNCTIONS/__fltk_uigetfile__.cc: Likewise. + 2011-01-29 John W. Eaton * Makefile.am (__fltk_uigetfile__): Use the same compiler flags diff -r b3ac1d094a3f -r db14b8095edd src/DLD-FUNCTIONS/__fltk_uigetfile__.cc --- a/src/DLD-FUNCTIONS/__fltk_uigetfile__.cc Sat Jan 29 12:27:16 2011 -0500 +++ b/src/DLD-FUNCTIONS/__fltk_uigetfile__.cc Sat Jan 29 12:56:29 2011 -0500 @@ -28,6 +28,13 @@ #include #include + +// FLTK headers may include X11/X.h which defines Complex, and that +// conflicts with Octave's Complex typedef. We don't need the X11 +// Complex definition in this file, so remove it before including Octave +// headers which may require Octave's Complex typedef. +#undef Complex + #include "defun-dld.h" #include "file-ops.h" diff -r b3ac1d094a3f -r db14b8095edd src/DLD-FUNCTIONS/__init_fltk__.cc --- a/src/DLD-FUNCTIONS/__init_fltk__.cc Sat Jan 29 12:27:16 2011 -0500 +++ b/src/DLD-FUNCTIONS/__init_fltk__.cc Sat Jan 29 12:56:29 2011 -0500 @@ -54,6 +54,12 @@ #include #include +// FLTK headers may include X11/X.h which defines Complex, and that +// conflicts with Octave's Complex typedef. We don't need the X11 +// Complex definition in this file, so remove it before including Octave +// headers which may require Octave's Complex typedef. +#undef Complex + #include "cmd-edit.h" #include "lo-ieee.h"