Skip to content
Prev 27212 / 63424 Next

Finding windows DLLs

On Mon, 7 Jan 2008, Oleg Sklyar wrote:

            
The Windows code for package XML says
function (libname, pkgname)
{
     if (.Platform$OS.type == "windows") {
         temp <- Sys.getenv("PATH")
         Sys.setenv(PATH = paste(utils::normalizePath(file.path(libname,
             pkgname, "libs")), temp, sep = ";"))
         on.exit(Sys.setenv(PATH = temp))
     }
     library.dynam("XML", pkgname, libname)
     if (exists("setMethod")) {
     }
     .C("RSXML_setErrorHandlers")
}
<environment: namespace:XML>

so it does already do that.

The order depends on the version of Windows *and* its settings: see

http://msdn2.microsoft.com/en-us/library/ms682586(VS.85).aspx

There is a way to change this:

http://msdn2.microsoft.com/en-us/library/ms686203(VS.85).aspx

but it would preclude Windows 2000.

Perhaps Martin can explain how libxml2.dll got into c:/WINDOWS/system32/?
My suggestion is that we rename the DLL when copied into library/XML/libs 
to something like libRxml2.dll.