Hi,

If anyone has an insight, experience or even hint on this one, this would be 
greatly appreciated.

I have a C# application that loads the a native shared library (the R shared 
library). I use DllImport as follows:

      [DllImport("libdl")]
      private static extern IntPtr dlopen([MarshalAs(UnmanagedType.LPStr)] 
string filename, int flag);

      [DllImport("libdl")]
      [return: MarshalAs(UnmanagedType.LPStr)]
      private static extern string dlerror();

full code at 
https://rdotnet.codeplex.com/SourceControl/latest#RDotNet.NativeLibrary/UnixLibraryLoader.cs,
 and the test application is at 
https://rdotnet.codeplex.com/SourceControl/latest#TestApps/SimpleTest/Program.cs.

I can run this application on a Debian Linux x64 box. However on a CentOS, and 
try as I might to have similar setups, I get a failure with the cryptic dlerror 
message  'dlopen: invalid caller'. I was surprised to see only sparse info on 
the net on this message. I can load the shared library successfully with a 
simple C program code.

Mono JIT compiler version 3.2.3 (tarball Sun Nov 24 17:03:07 EST 2013)
R3.0.2 compiled from tarball

Regards


_______________________________________________
Mono-list maillist  -  [email protected]
http://lists.ximian.com/mailman/listinfo/mono-list

Reply via email to