webui icon indicating copy to clipboard operation
webui copied to clipboard

Can I compile a 32-bit dll?

Open dqi1999 opened this issue 2 years ago • 9 comments

Can I compile a 32-bit dll?

dqi1999 avatar Jan 02 '24 03:01 dqi1999

of course, I don't know how to that with gcc,but you can use this command zig build -Dtarget=x86-linux -Dis_static=false -Denable_tls=false to build dynamic library for x86(32bits) windows (if you want to enable tls support, use -Denable_tls=true)

jinzhongjia avatar Jan 02 '24 05:01 jinzhongjia

After running zig build -Dtarget=x86-linux -Dis_static=false -Denable_tls=false, you can find the dynamic library in the directory zig-out/lib

jinzhongjia avatar Jan 02 '24 05:01 jinzhongjia

thank you!But I do not use zig to compile, testing for half a day did not get the dynamic link library, you can also release a 32-bit dynamic link library when you publish?

dqi1999 avatar Jan 02 '24 07:01 dqi1999

Sorry, I am not responsible for the webui of the C library. Need to ask @hassandraga @ttytm about this.

jinzhongjia avatar Jan 02 '24 07:01 jinzhongjia

Thank you!

dqi1999 avatar Jan 02 '24 08:01 dqi1999

Which OS and compiler you are using? I guess you can simply run make using your 32bit compiler and will work fine!

AlbertShown avatar Jan 02 '24 15:01 AlbertShown

zig compiled successfully using the latest version of webui;use cmd: zig build -Dtarget=x86-linux -Dis_static=false -Denable_tls=false,But the output is a file libwebui.so;I want to get the .dll file, use cmd:zig build -Dtarget=x86-windows-gnu -Dis_static=false -Denable_tls=false; but there is a compilation error! image

dqi1999 avatar Jan 03 '24 03:01 dqi1999

Yes, it seems that there are some strange problems with dynamic link building windows, I fixed them normally

jinzhongjia avatar Jan 03 '24 04:01 jinzhongjia

this pr should fix this problem:https://github.com/webui-dev/webui/pull/289

jinzhongjia avatar Jan 03 '24 05:01 jinzhongjia