need tkInt.h
Daniel G. Downey
danmotif at mrco2.carleton.ca
Tue Jun 22 11:02:04 EDT 1999
I had a similar problem. Here is a response I got. I didn't try it.
I solved my problem by using tcl/tk 8.0.5 instead of 8.1.1
Sorry if you get this twice.
Dan Downey
> From owner-vtkusers at gsao.med.ge.com Tue Jun 22 10:54 EDT 1999
> X-Authentication-Warning: gsao.med.ge.com: mjordomo set sender to owner-vtkusers at gsao.med.ge.com using -f
> Date: Tue, 22 Jun 1999 10:42:58 -0400 (EDT)
> From: Dongbai Guo <dbg at cs.brown.edu>
> X-Sender: dbg at transit
> To: vtkusers at gsao.med.ge.com
> Subject: need tkInt.h
> MIME-Version: 1.0
>
> I got the following compile error in vtk23, I guess somehow this
> 'tkInt.h' file is an outdate tk definition file, if somebody can
> find it in your directory hierarchy, please attach a copy of it and
> send it to me. ( I am using SGI)
>
>
> /usr/freeware/bin/g++ -O -DHAVE_SETMON -DVTK_WORDS_BIGENDIAN
> -DVTK_USE_SPROC -D_HP_NO_FAST_MACROS -DHAVE_LIMITS_H -DHAVE_UNISTD_H -I.
> -I. -I./../graphics -DVTK_USE_GRAPHICS -I./../imaging -DVTK_USE_IMAGING
> -I./../patented -DVTK_USE_PATENTED -I./../contrib -DVTK_USE_CONTRIB
> -DVTK_USE_OGLR -I./../common -I/u/s_dongbai/pub/tk8.1/include
> -I/u/s_dongbai/pub/tcl8.1/include
> -I/home/schroede/montnaro/Python-1.4/Include -c vtkTkRenderWidget.cxx -o
> vtkTkRenderWidget.o
> In file included from vtkTkRenderWidget.cxx:44:
> vtkTkRenderWidget.h:82: tkInt.h: No such file or directory
>
>
> thanks in advance.
> Dongbai
>
> --------------------------------------------------------------
> Tel: 401-863-7693 (graphics lab)
> http://www.cs.brown.edu/people/dbg
> ---------------------------------------------------------------
>
>
>
>
> -----------------------------------------------------------------------------
> This is the private VTK discussion list. Please keep messages on-topic.
> Check the FAQ at: <http://www.automatrix.com/cgi-bin/vtkfaq>
> To UNSUBSCRIBE, send message body containing "unsubscribe vtkusers" to
> <majordomo at gsao.med.ge.com>. For help, send message body containing
> "info vtkusers" to the same address. Live long and prosper.
> -----------------------------------------------------------------------------
>
>
----- Begin Included Message -----
>From Stef.Desmet at esat.kuleuven.ac.be Fri Jun 18 03:25 EDT 1999
From: Stef Desmet <Stef.Desmet at esat.kuleuven.ac.be>
Mime-Version: 1.0
Content-Transfer-Encoding: 7bit
Date: Fri, 18 Jun 1999 09:27:14 +0200 (MET DST)
To: danmotif at mrco2.carleton.ca (Daniel G. Downey)
Cc: vtkusers at gsao.med.ge.com
Subject: Re: tkMainWindowList hiding
Sorry for the late response... but it is possible to use vtk2.3 and Tcl/Tk8.1
I'll include a mail from robbel at wins.uva.nl (Robert Belleman) dating from may 30
explaining the problem. I applied the included patch and everything runs fine now
begin include
--------------
What follows is a quick fix; it is not backwards compatible with Tcl/Tk
8.0 but it should be easy to make it that way. I just though I'd keep to
the essence. Apart from that I haven't done extensive tests so I can't
guarantee this works for everyone. It does for me.
Regards,
-- Rob
[] Robert Belleman X Section for Computational Science []
[] robbel at wins.uva.nl |X| University of Amsterdam, the Netherlands []
[] tel: (+31) 20 525 7539 X http://www.wins.uva.nl/~robbel/ []
Problem description:
--------------------
Linking Vtk nightly May 28th with Tk 8.1 results in:
/usr/local/src/vtk/graphics/libVTKGraphicsTcl.so: undefined
reference to `tkMainWindowList'
This is because graphics/vtkXRenderWindowTclInteractor.cxx
references (extern TkMainInfo *) tkMainWindowList
which is used in line 185:
// use the same display as tcl/tk
ren->SetDisplayId(Tk_Display(tkMainWindowList->winPtr));
"tkMainWindowList" used to be defined in ./generic/tkWindow.c in Tk
8.0 but vanished from Tk 8.1 because of thread-safeness issues (note
that an extern definition still exists in ./generic/tkInt.h and in a
macintosh specific file but this has probably been overseen by the Tk
team).
Fix:
----
The required reference needed by Vtk has moved into a thread specific
data structure "ThreadSpecificData" which amongst others contains
TkMainInfo *mainWindowList;
/* First in list of all main windows managed
* by this thread. */
a reference to which can be obtained via the function
TkGetMainInfoList().
I have made these changes and it seems to work properly. Note that I
have not done extensive tests.
A context diff follows:
*** vtkXRenderWindowTclInteractor.cxx Sun May 30 01:02:10 1999
--- vtkXRenderWindowTclInteractor.cxx.org Sun May 30 00:29:08 1999
***************
*** 60,66 ****
struct TkWindow *winPtr;
};
! extern "C" { TkMainInfo *TkGetMainInfoList(); }
// returns 1 if done
static int vtkTclEventProc(XtPointer clientData,XEvent *event)
--- 60,66 ----
struct TkWindow *winPtr;
};
! extern TkMainInfo *tkMainWindowList;
// returns 1 if done
static int vtkTclEventProc(XtPointer clientData,XEvent *event)
***************
*** 182,188 ****
ren = (vtkXRenderWindow *)(this->RenderWindow);
// use the same display as tcl/tk
! ren->SetDisplayId(Tk_Display(TkGetMainInfoList()->winPtr));
this->DisplayId = ren->GetDisplayId();
// get the info we need from the RenderingWindow
--- 182,188 ----
ren = (vtkXRenderWindow *)(this->RenderWindow);
// use the same display as tcl/tk
! ren->SetDisplayId(Tk_Display(tkMainWindowList->winPtr));
this->DisplayId = ren->GetDisplayId();
// get the info we need from the RenderingWindow
--
Stef Desmet
Katholieke Universiteit Leuven Tel. +32-16-321041
Departement Elektrotechniek - ESAT Fax. +32-16-321986
Centrum voor Beeld- en Spraakverwerking - PSI Telex 25914 ELEKUL
Kardinaal Mercierlaan 94 eMail stef.desmet at esat.kuleuven.ac.be
B-3001 Heverlee Leuven URL <http://www.esat.kuleuven.ac.be/~desmet>
B E L G I U M
----------------------------------------------------------------------
----- End Included Message -----
-----------------------------------------------------------------------------
This is the private VTK discussion list. Please keep messages on-topic.
Check the FAQ at: <http://www.automatrix.com/cgi-bin/vtkfaq>
To UNSUBSCRIBE, send message body containing "unsubscribe vtkusers" to
<majordomo at gsao.med.ge.com>. For help, send message body containing
"info vtkusers" to the same address. Live long and prosper.
-----------------------------------------------------------------------------
More information about the vtkusers
mailing list