Exclude `SDL_main()` from DllImport as it isn't exported by SDL3.dll

This commit is contained in:
Susko3 2024-04-06 01:59:38 +02:00
parent 5cf5bb69d7
commit 2788460013
3 changed files with 7 additions and 6 deletions

View File

@ -41,8 +41,5 @@ namespace SDL
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
[SupportedOSPlatform("Windows")]
public static extern void SDL_GDKSuspendComplete();
[NativeTypeName("#define main SDL_main")]
public static readonly delegate*<int, sbyte**, int> main = &SDL_main;
}
}

View File

@ -29,9 +29,6 @@ namespace SDL
{
public static unsafe partial class SDL3
{
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
public static extern int SDL_main(int argc, [NativeTypeName("char *[]")] sbyte** argv);
[DllImport("SDL3", CallingConvention = CallingConvention.Cdecl, ExactSpelling = true)]
public static extern void SDL_SetMainReady();

View File

@ -0,0 +1,7 @@
# Copyright (c) ppy Pty Ltd <contact@ppy.sh>. Licensed under the MIT Licence.
# See the LICENCE file in the repository root for full licence text.
# Exclude definition that are only useful when building C applications.
--exclude
SDL_main
main