summaryrefslogtreecommitdiff
path: root/src/bindings/mono/eo_mono/FunctionWrapper_Unix.cs
diff options
context:
space:
mode:
Diffstat (limited to 'src/bindings/mono/eo_mono/FunctionWrapper_Unix.cs')
-rw-r--r--src/bindings/mono/eo_mono/FunctionWrapper_Unix.cs21
1 files changed, 21 insertions, 0 deletions
diff --git a/src/bindings/mono/eo_mono/FunctionWrapper_Unix.cs b/src/bindings/mono/eo_mono/FunctionWrapper_Unix.cs
new file mode 100644
index 0000000..b140c0f
--- /dev/null
+++ b/src/bindings/mono/eo_mono/FunctionWrapper_Unix.cs
@@ -0,0 +1,21 @@
1using System;
2using System.Runtime.InteropServices;
3
4namespace Efl { namespace Eo {
5
6public partial class FunctionInterop
7{
8 [DllImport(efl.Libs.Libdl)]
9 public static extern IntPtr dlsym(IntPtr handle, string symbol);
10
11 public static IntPtr LoadFunctionPointer(IntPtr nativeLibraryHandle, string functionName)
12 {
13 Console.WriteLine("searching {0} in library {1}", nativeLibraryHandle, functionName);
14 var s = FunctionInterop.dlsym(nativeLibraryHandle, functionName);
15 Console.WriteLine("searching {0} in library {1}, result {2}", nativeLibraryHandle, functionName, s);
16 return s;
17 }
18}
19
20
21} }