On Mon, Mar 7, 2011 at 6:57 AM, nerice <neil.r...@plymouth.ac.uk> wrote: > CHECK FOR CONFLICTS IN YOUR PATH !!! > > I had a related problem when trying to use library "RGtk2" for the first > time. My problem was that when loading the library R was looking for the > file "zlib1.dll" but couldn't find the procedure to launch RGtk2. I was > getting an "Entry Point not found" error from Rgui.exe. > > The reason was because I had another package in my PATH environment variable > (C:\program files\Intel\WiFi\bin) which had a CONFLICTING version of the > "zlib1.dll" - and it was looking in this file and not the "zlib1.dll" which > came with GTK+. > > Removed this conflict from the PATH and all was ok. > >
I also had a related problem trying to use libary RGtk2 under Windows XP. I kept getting the message "unable to load shared object C:\R\site-library\RGtk2\libs\i386\RGtk2.dll" Uninstalling and reinstalling various versions of GTK2, both through R and outside R, many times, did not help. With the help of Neil Rice's comment, I found that there was another version of zlib1.dll in a directory on my PATH. Removing that directory from the path (inside R) fixed the problem and RGtk2 runs fine now. Here's an R expression to look for other copies on zlib1.dll on the path: > with(list(x=file.path(strsplit(Sys.getenv("PATH"), ";")$PATH, "zlib1.dll")), > x[file.exists(x)]) [1] "C:\\R\\GTK2-Runtime\\bin/zlib1.dll" > There are many ways to modify the PATH. To set PATH inside R: > Sys.setenv(PATH=paste(grep("UNWANTED\\\\PATH", strsplit(Sys.getenv("PATH"), > ";")[[1]], value=T, invert=T), collapse=";")) (substitute some pattern that matches the unwanted directory for "UNWANTED\\\\PATH", remembering to use four backslashes to match one). -- Tony Plate ______________________________________________ R-help@r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide http://www.R-project.org/posting-guide.html and provide commented, minimal, self-contained, reproducible code.