[Mono-dev] dlopen(libSystem.Data.dll, 9): image not found

Robert Jordan robertj at gmx.net
Wed Mar 1 18:56:15 UTC 2017


On 01.03.2017 15:54, Jonathan Mitchell wrote:
> While fixing a Dll import issue on MacOS I noticed the following:
>
> Mono: DllImport error loading library 'libSystem.Data.dll.so': 'dlopen(libSystem.Data.dll.so, 9): image not found'.
> Mono: DllImport error loading library 'libSystem.Data.dll.bundle': 'dlopen(libSystem.Data.dll.bundle, 9): image not found'.
> Mono: DllImport error loading library 'libSystem.Data.dll': 'dlopen(libSystem.Data.dll, 9): image not found'.
> Mono: DllImport unable to load library 'dlopen(libSystem.Data.dll, 9): image not found'.
> Mono: DllImport attempting to load: 'System.Data.dll’.
>
> By the time my app launches  dlopen() has attempted to load libSystem.Data.dll.whatever 1600 times.
> My MacOS app launches and exceutes okay.
>
> Is this normal behaviour on 4.8.0?

It happens on 4.6.x as well, and it seems to be caused by actual
DllImports of 'System.Data.dll':



$ monodis System.Data.dll | grep pinvoke | grep System

.method assembly static hidebysig pinvokeimpl ("System.Data.dll" as 
"DllBidTraceCW" unicode cdecl )
     .method assembly static hidebysig pinvokeimpl ("System.Data.dll" as 
"DllBidTraceCW" unicode cdecl )
...


These look to me like some MS Reference Source artifacts. Maybe
there is a native System.Data.dll under MS.NET which is providing
these exports :) No idea what it is.

See also

https://referencesource.microsoft.com/#System.Data/System/Data/Common/System.Data_BID.cs


Robert




More information about the Mono-devel-list mailing list