[Rd] Problem R-1.8.0 library tcltk on Tcl-8.0.5 (PR#4699)

Kurt Hornik Kurt.Hornik at wu-wien.ac.at
Tue Oct 21 17:02:56 MEST 2003


>>>>> Peter Dalgaard writes:

> nakama at ki.rim.or.jp writes:
>> Full_Name: Eiji Nakama
>> Version: R-1.8.0
>> OS: linux(VineLinux)
>> Submission from: (NULL) (219.117.236.13)
>> 
>> 
>> I build by Tcl8.0.5 and R-1.8.0.
>> 
>> > library(tcltk)
>> Error in dyn.load(x, as.logical(local), as.logical(now)) : 
>> unable to load shared library "/usr/lib/R/library/tcltk/libs/tcltk.so":
>> /usr/lib/R/library/tcltk/libs/tcltk.so: undefined symbol:
>> RTcl_ActivateConsoleError in runHook(".onLoad", env, package.lib, package) : 
>> .onLoad failed
>> Error in library(tcltk) : package/namespace load failed
>> 
>> R-1.8.0/src/library/tcltk/src/init.c
>> 32 #ifndef TCL80
>> 33     {"RTcl_ActivateConsole", (DL_FUNC) &RTcl_ActivateConsole, 0},
>> 34 #endif
>> 
>> TCL80 is not defined anywhere.
>> It is defined only as tcltk.c.

> Yes. The workaround should be obvious. Or upgrade tcl/tk -- 8.0.x is
> pretty ancient by now.

> The proper fix is probably to move

> #include <tcl.h>
> #include <tk.h>

> #if (TCL_MAJOR_VERSION==8 && TCL_MINOR_VERSION==0)
> #define TCL80
> #endif

> from tcltk.c into tcltk.h.

> (Argh. The test builds of 1.8.0 were actually against tcl8.0, but
> apparently our testing procedures skip any attempt to load the dynlib.
> Automated tests of tcl/tk are difficult because Tk will protest if
> there is no X display.)

On systems which have Xvfb, this is not a problem.

The daily package checker uses this, for example.

-k



More information about the R-devel mailing list