openfl / lime

A foundational Haxe framework for cross-platform development
https://lime.openfl.org/
MIT License
753 stars 365 forks source link

Migrate to SDL3 #1679

Closed EliteMasterEric closed 1 year ago

EliteMasterEric commented 1 year ago

I wanted to implement some of the features introduced in SDL3

EliteMasterEric commented 1 year ago

I am currently experiencing a bug on this branch where applications throw the following build error:

Link: ApplicationMain-debug.exe
   Creating library ApplicationMain-debug.lib and object ApplicationMain-debug.exp
Called from lime/_internal/backend/native/NativeCFFI.hx line 686
Called from lime/system/CFFI.hx line 111
Called from C:\HaxeToolkit\haxe\std/neko/Lib.hx line 35
Uncaught exception - load.c(357) : Primitive not found : ./lime@lime_joystick_get_num_trackballs(1)
Called from ? line 1
Called from CommandLineTools.hx line 1904
Called from CommandLineTools.hx line 22
Called from a C function
Called from CommandLineTools.hx line 125
Called from CommandLineTools.hx line 640
Called from lime/tools/PlatformTarget.hx line 107
Called from WindowsPlatform.hx line 514
Called from lime/tools/IconHelper.hx line 189
Called from lime/tools/IconHelper.hx line 364
Called from lime/tools/ImageHelper.hx line 126

This is despite the fact that all references to trackballs have been removed from the project, and line 686 does not reference the trackballs function.

player-03 commented 1 year ago

Did you run lime rebuild cpp?

EliteMasterEric commented 1 year ago

I have run lime rebuild windows -clean (and just tested lime rebuild cpp).

I have also gone through and searched my system for every instance of lime.ndll and NativeCFFI.hx and removed them.

lime display windows points to the correct path as well.

player-03 commented 1 year ago

And lime rebuild tools?

EliteMasterEric commented 1 year ago

I am running lime rebuild tools as well.

I also tried modifying the CFFI to readd the function it's complaining about (and making it always return 0) but it still returns the same error.

player-03 commented 1 year ago

Normally those two are enough. And normally, the error would happen during the rebuild windows step, not when building the app itself.

Does it happen in sample projects? DisplayingABitmap for instance?