mono and unmanaged code in ubuntu

大憨熊 提交于 2019-12-04 13:11:07

It should be

[DllImport("libc.so.6")]

or just

[DllImport("libc")]

"libc" is a alias from /etc/mono/config, On GNU/Linux system: ... <dllmap dll="libc" target="libc.so.6" os="!windows"\> ...

to resolve this in x64 bit ubuntu 12

cd /lib/x86_64-linux-gnu
ln -s libc.so.6 libc.so

To resolve on Raspbian on a Raspberry Pi with mono 4.0.2 compiled from a tarball, I did this

sudo cp /lib/arm-linux-gnueabihf/libc.so.6 /lib/libc

/lib being one of the default search folders

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!