mirror of
https://github.com/tribufu/tribufu-rust
synced 2026-05-06 14:57:27 +00:00
Add Premake and FFI Bindings
This commit is contained in:
parent
36df99c7e0
commit
74532a9ace
14 changed files with 399 additions and 0 deletions
24
Examples/CSharp/Hello.cs
Normal file
24
Examples/CSharp/Hello.cs
Normal file
|
|
@ -0,0 +1,24 @@
|
|||
// Copyright (c) TribuFu. All Rights Reserved
|
||||
|
||||
using System;
|
||||
using System.Runtime.InteropServices;
|
||||
|
||||
namespace CSharp
|
||||
{
|
||||
class Program
|
||||
{
|
||||
#if WINDOWS_PLATFORM
|
||||
const string TribuFu = "TribuFu";
|
||||
#else
|
||||
const string TribuFu = "libTribuFu";
|
||||
#endif
|
||||
|
||||
[DllImport(TribuFu)]
|
||||
public static extern int Hello();
|
||||
|
||||
public static void Main(string[] args)
|
||||
{
|
||||
Console.WriteLine("TribuFu SDK = " + Hello());
|
||||
}
|
||||
}
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue