From edd at debian.org  Mon May  5 20:50:07 2008
From: edd at debian.org (Dirk Eddelbuettel)
Date: Mon, 5 May 2008 13:50:07 -0500
Subject: [Rd] [R-SIG-Mac] Starting tcltk without Tk
In-Reply-To: <49DE98AC-4211-4BC8-8F7F-FA44DBAEA7F8@r-project.org>
References: <481D979B.9030107@sciviews.org>
	<56155F30-1E17-4440-B380-73EAD0596A3E@r-project.org>
	<49DE98AC-4211-4BC8-8F7F-FA44DBAEA7F8@r-project.org>
Message-ID: <20080505185007.GA5563@eddelbuettel.com>

On Mon, May 05, 2008 at 02:22:03PM -0400, Simon Urbanek wrote:
> It turns out that the behavior of starting just Tcl was actually a bug. 
> Apparently the intention was to attempt to start Tk regardless of the 
> DISPLAY variable, because some TclTk implementation such as Aqua Tcl/Tk 
> don't require DISPLAY and thus would not be loaded. Due to a bug 
> (HAVE_AQUA was not included in Rconfig.h before R 2.7.0), though, this 
> was not the case. I'll leave it to tcltk users/maintainers to decide the 
> right way forward. Essentially I see two options:
>
> 1) status quo: tcltk always attempts to load Tk and fails on an error
> 2) allow some (possibly cross-platform) way of specifying that it is ok 
> to not load Tk - essentially make failure to load Tk non-fatal.
>
> Right now there is no (semantically correct) way to inhibit the loading 
> of Tk (DISPLAY is a sort of abuse and not a solution).

FWIW this requirement was also biting Debian's automated builders in
the tail.  A hack remedy was to just remove tcltk from lazy-load.  

A slightly better fix is to run 'R CMD INSTALL ...' with a prefix of
'xvfb-run' which uses the virtual framebuffer x11 driver to make
tcl/tk (or any other user of x11; I think gtk2 may fall in the same
camp) happy whether or not the box is actually headless.

Dirk

-- 
Three out of two people have difficulties with fractions.



[Rd] [R-SIG-Mac] Starting tcltk without Tk
Dirk Eddelbuettel