yglukhov / nimx

GUI library

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Problems regarding SDL2

tillfalko opened this issue · comments

(This is on a fresh nim install on Windows 11. This issue occurs whether the newest nim version is installed manually, or with choosenim. I tried both.)

Trying to run the README example script with nim c -r --threads:on main.nim results in

could not load: SDL2.dll
Error: execution of an external program failed: 'C:\Users\T\windev\n\main.exe '

nimble install sdl2 did not help. Eventually I was able to fix this by manually downloading the SDL2.dll file and putting it in the same directory as main.nim. I doubt that this is intended. Perhaps there is some obvious thing I am missing but as I am new to nim, this was very confusing.

I could also not get the nimx samples to work at all. No matter where I pasted SDL2.dll file, executing nake would always result in

c:/users/t/.choosenim/toolchains/mingw64/bin/../lib/gcc/x86_64-w64-mingw32/11.1.0/../../../../x86_64-w64-mingw32/bin/ld.exe: cannot find -lSDL2
collect2.exe: error: ld returned 1 exit status
Error: execution of an external program failed: 'gcc.exe  @main_linkerArgs.txt'

At this point I have populated at least 10 folders relating to mingw, nim, choosenim, and nimx with the LSDL2.dll file but alas, nothing changes.

This is looks similar to #504 did you seen this?

This is how I solved the issue. Is this expected, or did I mess up during the installation?