Henrik Bengtsson
2002-Mar-06 16:46 UTC
[R] Loading tcltk package fails on WinMe/Cygwin but works with Rgui
I am investigating how well R/tcltk is supported on different system and I ran into the same problem as Christian Schulz reported on February 7, 2002. I am using [R] v1.4.1 on WinMe and ActiveTcl 8.3.2. Loading tcltk within Rgui works just fine and both demo(tkdensity) and demo(tkttest) works as expected. However, when I start R from my Cygwin terminal dyn.load() fails to load the library: % R --vanilla> library(tcltk)Error in dyn.load(x, as.logical(local), as.logical(now)) : unable to load shared library "C:/PROGRA~1/R/RW1041/library/tcltk/libs/tcltk.dll": LoadLibrary failure: One of the library files needed to run this application cannot be found. Error in library(tcltk) : .First.lib failed Trying to troubleshoot;> file <- "C:/PROGRA~1/R/RW1041/library/tcltk/libs/tcltk.dll" > file.exists(file)[1] TRUE> dyn.load(file)gives the same error as above. Suspecting Cygwin paths where interacting with the Windows paths, I also tried set the working directory to the directory where the dll is and to load from there> setwd("C:/PROGRA~1/R/RW1041/library/tcltk/libs/") > file <- "tcltk.dll" > file.exists(file)[1] TRUE> dyn.load(file)but the same error. As I said, this works fine with Rgui. Any ideas? Thanks Henrik Bengtsson Dept. of Mathematical Statistics @ Centre for Mathematical Sciences Lund Institute of Technology/Lund University, Sweden (+2h UTC) Office: P316, +46 46 222 9611 (phone), +46 46 222 4623 (fax) h b @ m a t h s . l t h . s e, http://www.maths.lth.se/bioinformatics/ -.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.- r-help mailing list -- Read http://www.ci.tuwien.ac.at/~hornik/R/R-FAQ.html Send "info", "help", or "[un]subscribe" (in the "body", not the subject !) To: r-help-request at stat.math.ethz.ch _._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._
Prof Brian Ripley
2002-Mar-06 17:04 UTC
[R] Loading tcltk package fails on WinMe/Cygwin but works with Rgui
On Wed, 6 Mar 2002, Henrik Bengtsson wrote:> I am investigating how well R/tcltk is supported on different system and I > ran into the same problem as Christian Schulz reported on February 7, 2002. > > I am using [R] v1.4.1 on WinMe and ActiveTcl 8.3.2. Loading tcltk within > Rgui works just fine and both demo(tkdensity) and demo(tkttest) works as > expected. However, when I start R from my Cygwin terminal dyn.load() fails > to load the library: > > % R --vanillaWhat `R' is this? The Windows port only has Rgui and Rterm. My bet is that you don't have the *Windows* Tcl bin directory in your *Cygwin* path. See the rw-FAQ Q3.6. If by `my Cygwin terminal' you mean the Cygwin bash shell (Cygwin provides no terminal per se), then with the correct path it does work. (I have Tcl installed in c:\R\Tcl and had /R/Tcl/Bin in my bash path. You can find out by looking at the environment variable PATH from a running R process.) -- Brian D. Ripley, ripley at stats.ox.ac.uk Professor of Applied Statistics, http://www.stats.ox.ac.uk/~ripley/ University of Oxford, Tel: +44 1865 272861 (self) 1 South Parks Road, +44 1865 272860 (secr) Oxford OX1 3TG, UK Fax: +44 1865 272595 -.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.- r-help mailing list -- Read http://www.ci.tuwien.ac.at/~hornik/R/R-FAQ.html Send "info", "help", or "[un]subscribe" (in the "body", not the subject !) To: r-help-request at stat.math.ethz.ch _._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._
Dear all,> % R --vanilla > > > library(tcltk) > Error in dyn.load(x, as.logical(local), as.logical(now)) : > unable to load shared library > "C:/PROGRA~1/R/RW1041/library/tcltk/libs/tcltk.dll": > LoadLibrary failure: One of the library files needed to run this > application cannot be found. > Error in library(tcltk) : .First.lib failedI'm getting exactly this on an ancient installation of Win95, but this time in both Rgui and Rterm. I did more or less the same things, but got the same result.> but the same error. As I said, this works fine with Rgui. Any ideas?more or less the same sentiment, except the Rgui bit. I have had it working on Win98 and Win2000 installations with no problems. Baffling. David. ********************************************************************** ** Dr. David Lucy ** ** Joseph Bell Centre for Forensic Statistics and Legal Reasoning ** ** Department of Mathematics and Statistics ** ** The University of Edinburgh ** ** James Clerk Maxwell Building ** ** King's Buildings ** ** Mayfield Road ** ** Edinburgh ** ** EH9 3JZ ** ** ** ** tel: 0131 650 5057 ** ** extension: 505057 ** ** e-mail: dlucy at maths.ed.ac.uk ** ** ** ** Truncated address: ** ** ** ** Dr. David Lucy ** ** Department of Mathematics ** ** JCMB ** ** King's Buildings ** ** Edinburgh University ** ** Edinburgh ** ** EH9 3JZ ** ********************************************************************** -.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.- r-help mailing list -- Read http://www.ci.tuwien.ac.at/~hornik/R/R-FAQ.html Send "info", "help", or "[un]subscribe" (in the "body", not the subject !) To: r-help-request at stat.math.ethz.ch _._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._
christian
2002-Mar-06 21:45 UTC
[R] Loading tcltk package fails on WinMe/Cygwin but works with Rgui
...i can only suggest that now tcl/tk & win2000 works fine with this row in file /etc/Rprofile Sys.putenv("TCL_LIBRARY"="c:/develope/Tcl/lib/tcl8.3") and it is possible to test the entry in R with: Sys.getenv() TCL_LIBRARY "c:/develope/Tcl/lib/tcl8.3" regards,christian>I am investigating how well R/tcltk is supported on different system and I >ran into the same problem as Christian Schulz reported on February 7, 2002. > >I am using [R] v1.4.1 on WinMe and ActiveTcl 8.3.2. Loading tcltk within >Rgui works just fine and both demo(tkdensity) and demo(tkttest) works as >expected. However, when I start R from my Cygwin terminal dyn.load() fails >to load the library: > >% R --vanilla > >> library(tcltk) >Error in dyn.load(x, as.logical(local), as.logical(now)) : > unable to load shared library > "C:/PROGRA~1/R/RW1041/library/tcltk/libs/tcltk.dll": > LoadLibrary failure: One of the library files needed to run this >application cannot be found. >Error in library(tcltk) : .First.lib failed > >Trying to troubleshoot; > >> file <- "C:/PROGRA~1/R/RW1041/library/tcltk/libs/tcltk.dll" >> file.exists(file) >[1] TRUE >> dyn.load(file) > >gives the same error as above. Suspecting Cygwin paths where interacting >with the Windows paths, I also tried set the working directory to the >directory where the dll is and to load from there > >> setwd("C:/PROGRA~1/R/RW1041/library/tcltk/libs/") >> file <- "tcltk.dll" >> file.exists(file) >[1] TRUE >> dyn.load(file) > >but the same error. As I said, this works fine with Rgui. Any ideas? > >Thanks > >Henrik Bengtsson > >Dept. of Mathematical Statistics @ Centre for Mathematical Sciences >Lund Institute of Technology/Lund University, Sweden (+2h UTC) >Office: P316, +46 46 222 9611 (phone), +46 46 222 4623 (fax) >h b @ m a t h s . l t h . s e, http://www.maths.lth.se/bioinformatics/ > > >-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.- >r-help mailing list -- Read http://www.ci.tuwien.ac.at/~hornik/R/R-FAQ.html >Send "info", "help", or "[un]subscribe" >(in the "body", not the subject !) To: r-help-request at stat.math.ethz.ch >_._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._ >-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.- r-help mailing list -- Read http://www.ci.tuwien.ac.at/~hornik/R/R-FAQ.html Send "info", "help", or "[un]subscribe" (in the "body", not the subject !) To: r-help-request at stat.math.ethz.ch _._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._