-
Notifications
You must be signed in to change notification settings - Fork 19
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[Bug]: Enabling TLS on windows will cause non-found ssl #74
Comments
I'm not sure how to use TLS with Zig build ! .enable_tls = false,
.tls_include = "PATH_TO_TLS_INCLUDE",
.tls_lib = "PATH_TO_TLS_LIB", However, a workaround for now, is to you can manually build a dynamic version of webui + TLS using any C compiler:
Note:
|
Another thing, make sure you have OpenSSL v3.3.1+ |
The pre-built files have the file webui-2.dll, while the program says it requires webui.dll, any idea why? |
It also complains if I just rename the file. |
Which program we are talking about here? |
The program that utilizes zig-webui, which is currently just
|
In case it matters, the build.zig is
|
Yes, the problem does exist on Windows, but the root cause of the problem is in the upstream webui. |
I'll take a look, thanks for the ping. |
Past CI tests did not have tls testing. At least in the 0.11 period, tls was running normally. |
After about two weeks, I have a lot of free time to deal with the deposition problem of this library. |
OK,I'm back. |
Well, I tried for a few hours and still didn't find the perfect solution. The zig compiler never found the ssl library correctly, even if the path was specified. |
I guess the solution may look something like this: .enable_tls = true,
.tls_include = "PATH_TO_TLS_INCLUDE", // Example: C:\Program Files\OpenSSL-xxx\include
.tls_lib = "PATH_TO_TLS_LIB", // Example: C:\Program Files\OpenSSL-xxx\lib Compiling webui with TLS on Windows: ...... WEBUI_USE_TLS=1 WEBUI_TLS_INCLUDE="v{}" WEBUI_TLS_LIB="v{}", .{ tls_include, tls_lib } |
WEBUI_TLS_INCLUDE="v{}" WEBUI_TLS_LIB="v{}" Of course those are just an example, need to be changed to |
tls_include = "PATH_TO_TLS_INCLUDE", // Example: C:\Program Files\OpenSSL-xxx\include
.tls_lib = "PATH_TO_TLS_LIB", // Example: C:\Program Files\OpenSSL-xxx\lib Those options need to be added, I guess. |
Good idea, I will initiate a PR to the upstream and let webui's build.zig expose the option to set the location of the library |
A very strange problem, the Zig's construction system cannot find a package in the LIB and INCLUDE directory I specified, but GCC can |
@jinzhongjia feel free to change anything in upstream Zig build file if this may help you fixing the SSL issue for Zig. |
My previous attempt is to change directly in the upstream, but I still can't find the library. |
I will investigate in this, if I found a solution I will suggest it to you. |
On my windows machine, whenever i try to compile with TLS enabled, zig says that it cannot find SSL or crypto, and that it has searched no paths. I have OpenSSL installed, an it is in path, and i have even tried directly linking libssl.
The text was updated successfully, but these errors were encountered: