webui-dev / nim-webui

Use any web browser as GUI, with Nim in the backend and HTML5 in the frontend.
https://webui.me
MIT License
130 stars 9 forks source link

make it compatible with TCC #4

Closed CardealRusso closed 1 year ago

CardealRusso commented 1 year ago

tcc: error: library 'ws2_32' not found

CardealRusso commented 1 year ago

i dont get it. i can compile the c example with tcc but on nim i get ws2 not found

neroist commented 1 year ago

Do you have libws2_32.a on your system? That seems to be the issue.

AlbertShown commented 1 year ago

The TCC Make file in WebUI use -lws2_32 to link the Windows Socket library. And it seems bindings.nim also use -lws2_32.

You should download the latest mob development branch of TCC, as the official one was abandoned a while ago. And build it using build-tcc.bat.

On the other hand, if you can build WebUI using TCC, there is probably something wrong with bindings.nim.

CardealRusso commented 1 year ago

The TCC Make file in WebUI use -lws2_32 to link the Windows Socket library. And it seems bindings.nim also use -lws2_32.

You should download the latest mob development branch of TCC, as the official one was abandoned a while ago. And build it using build-tcc.bat.

On the other hand, if you can build WebUI using TCC, there is probably something wrong with bindings.nim.

yes indeed i can compile the c99 example with tcc without any problem im already using the mob version of tcc

AlbertShown commented 1 year ago

Thank you