MantisBT - VTK
View Issue Details
0003967VTK(No Category)public2006-10-23 15:202013-04-05 19:59
Steve Robbins 
David Partyka 
lowminoralways
closedno change required 
 
 
0003967: Build failure: _XDisplay internals not visible
I'm building head of CVS as of this morning, on cygwin under Windows XP. I have xorg X11 packages installed:

cygcheck -c xorg-x11-devel
Cygwin Package Information
Package Version Status
xorg-x11-devel 6.8.99.901-1 OK

I configured with Tcl wrapping ON, and the build fails as follows:

[ 71%] Building CXX object Rendering/CMakeFiles/vtkRenderingTCL.dir/vtkTkRenderWidget.o
/tmp/local-build/VTK-cvs/Rendering/vtkTkRenderWidget.cxx: In function `LRESULT vtkTkRenderWidgetProc(HWND__*, UINT, WPARAM, LPARAM)':
/tmp/local-build/VTK-cvs/Rendering/vtkTkRenderWidget.cxx:836: error: invalid use of undefined type `struct _XDisplay'
/usr/include/X11/Xlib.h:289: error: forward declaration of `struct _XDisplay'
make[2]: *** [Rendering/CMakeFiles/vtkRenderingTCL.dir/vtkTkRenderWidget.o] Error 1
make[1]: *** [Rendering/CMakeFiles/vtkRenderingTCL.dir/all] Error 2
make: *** [all] Error 2


In the xorg header file X11/Xlib.h, we find:

/*
 * Display datatype maintaining display specific data.
 * The contents of this structure are implementation dependent.
 * A Display should be treated as opaque by application code.
 */
#ifndef XLIB_ILLEGAL_ACCESS
typedef struct _XDisplay Display;
#endif

[...]

typedef struct
#ifdef XLIB_ILLEGAL_ACCESS
_XDisplay
#endif
{
[...]


So: you can only access internals of _XDisplay if XLIB_ILLEGAL_ACCESS is defined.

I defined that symbol and the build is proceeding. Perhaps the better solution is to see about getting the information required without poking around into X11 internals. I didn't attempt to do that.
No tags attached.
Issue History
2008-02-06 10:41Jeff BaumesNote Added: 0010390
2008-02-06 10:41Jeff BaumesAssigned ToWill Schroeder =>
2008-02-06 10:41Jeff BaumesSeveritymajor => minor
2010-11-30 23:02David PartykaNote Added: 0023628
2010-11-30 23:02David PartykaStatustabled => @80@
2010-11-30 23:02David PartykaResolutionopen => no change required
2010-11-30 23:02David PartykaAssigned To => David Partyka
2011-06-16 13:11Zack GalbreathCategory => (No Category)
2013-04-05 19:59Berk GeveciStatuscustomer review => closed

Notes
(0010390)
Jeff Baumes   
2008-02-06 10:41   
Does this still exist with latest cygwin/VTK?
(0023628)
David Partyka   
2010-11-30 23:02   
I don't believe this is any longer an issue. If it is please reopen.