Skip to content

Windows cURL extension doesn't appear to support SSL #659

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

Closed
phenaproxima opened this issue Mar 19, 2025 · 9 comments · Fixed by #674
Closed

Windows cURL extension doesn't appear to support SSL #659

phenaproxima opened this issue Mar 19, 2025 · 9 comments · Fixed by #674
Assignees
Labels
bug Something isn't working kind/extension Issues related to extensions os/windows Things only for Windows

Comments

@phenaproxima
Copy link
Contributor

phenaproxima commented Mar 19, 2025

This was found in testing https://github.com/drupal/cms-launcher on Windows: drupal/cms-launcher#38

It was also seen in #597 (comment)

Any advice? Should I just try updating static-php-cli to 2.5.0 (we're on 2.4.5 right now) and rebuilding?

@phenaproxima phenaproxima added the bug Something isn't working label Mar 19, 2025
@phenaproxima
Copy link
Contributor Author

After updating to static-php-cli 2.5.0, I am also seeing the build fail on Windows: https://github.com/drupal/cms-launcher/actions/runs/13946411456/job/39034570532

The crux of the problem seems to be cURL, and the linker not being able to resolve it:

interface.obj : error LNK2001: unresolved external symbol __imp_curl_mime_init
interface.obj : error LNK2001: unresolved external symbol __imp_curl_mime_free
interface.obj : error LNK2001: unresolved external symbol __imp_curl_mime_addpart
interface.obj : error LNK2001: unresolved external symbol __imp_curl_mime_name
interface.obj : error LNK2001: unresolved external symbol __imp_curl_mime_filename
interface.obj : error LNK2001: unresolved external symbol __imp_curl_mime_type
interface.obj : error LNK2001: unresolved external symbol __imp_curl_mime_data
interface.obj : error LNK2001: unresolved external symbol __imp_curl_mime_data_cb
interface.obj : error LNK2001: unresolved external symbol __imp_curl_easy_escape
interface.obj : error LNK2001: unresolved external symbol __imp_curl_easy_unescape
interface.obj : error LNK2001: unresolved external symbol __imp_curl_free
interface.obj : error LNK2001: unresolved external symbol __imp_curl_global_init
interface.obj : error LNK2001: unresolved external symbol __imp_curl_global_cleanup
interface.obj : error LNK2001: unresolved external symbol __imp_curl_slist_append
interface.obj : error LNK2001: unresolved external symbol __imp_curl_slist_free_all
interface.obj : error LNK2001: unresolved external symbol __imp_curl_version_info
interface.obj : error LNK2001: unresolved external symbol __imp_curl_easy_strerror
interface.obj : error LNK2001: unresolved external symbol __imp_curl_easy_pause
interface.obj : error LNK2001: unresolved external symbol __imp_curl_easy_init
interface.obj : error LNK2001: unresolved external symbol __imp_curl_easy_setopt
interface.obj : error LNK2001: unresolved external symbol __imp_curl_easy_perform
interface.obj : error LNK2001: unresolved external symbol __imp_curl_easy_cleanup
interface.obj : error LNK2001: unresolved external symbol __imp_curl_easy_getinfo
interface.obj : error LNK2001: unresolved external symbol __imp_curl_easy_duphandle
interface.obj : error LNK2001: unresolved external symbol __imp_curl_easy_reset
interface.obj : error LNK2001: unresolved external symbol __imp_curl_easy_upkeep
multi.obj : error LNK2001: unresolved external symbol __imp_curl_multi_init
multi.obj : error LNK2001: unresolved external symbol __imp_curl_multi_add_handle
multi.obj : error LNK2001: unresolved external symbol __imp_curl_multi_remove_handle
multi.obj : error LNK2001: unresolved external symbol __imp_curl_multi_wait
multi.obj : error LNK2001: unresolved external symbol __imp_curl_multi_perform
multi.obj : error LNK2001: unresolved external symbol __imp_curl_multi_cleanup
multi.obj : error LNK2001: unresolved external symbol __imp_curl_multi_info_read
multi.obj : error LNK2001: unresolved external symbol __imp_curl_multi_strerror
multi.obj : error LNK2001: unresolved external symbol __imp_curl_multi_setopt
multi.obj : error LNK2001: unresolved external symbol __imp_curl_pushheader_bynum
share.obj : error LNK2001: unresolved external symbol __imp_curl_share_init
share.obj : error LNK2001: unresolved external symbol __imp_curl_share_setopt

@PeteBishwhip
Copy link

PeteBishwhip commented Mar 19, 2025

I can confirm we're also seeing this error. It's documented on this action with the --debug flag active if it helps: https://github.com/NativePHP/php-bin/actions/runs/13947104732/job/39036777351

It appears to affect PHP 8.3 and 8.4 on Windows. 8.2 and below appear unaffected.

@crazywhalecc
Copy link
Owner

crazywhalecc commented Mar 19, 2025

I found that PHP >= 8.3 has some changes on windows build. I will fix it later, and test ssl support after everything else working well: #660 .

@crazywhalecc crazywhalecc added kind/extension Issues related to extensions os/windows Things only for Windows labels Mar 19, 2025
@phenaproxima
Copy link
Contributor Author

Thanks @crazywhalecc! Can confirm that even reverting to 2.4.5 doesn't solve the problem -- it's failing in the same way: https://github.com/drupal/cms-launcher/actions/runs/13948634297/job/39041966023?pr=40

@PeteBishwhip
Copy link

Thanks @crazywhalecc! Can confirm that even reverting to 2.4.5 doesn't solve the problem -- it's failing in the same way: https://github.com/drupal/cms-launcher/actions/runs/13948634297/job/39041966023?pr=40

I worked around this for now by downgrading to 2.4.4 and adding WINBUILD_ACKNOWLEDGE_DEPRECATED: yes to our env.

@crazywhalecc
Copy link
Owner

crazywhalecc commented Mar 20, 2025

I've updated the main branch but I only fixed the build bug of 8.3 and 8.4. You can try it again to test whether it supports ssl. If everything works well, we'll publish a patch version.

@yoramdelangen
Copy link
Contributor

yoramdelangen commented Mar 20, 2025

I ran into this issue as well, and was able to solve it by duplicate the libcurl.lib with libcurl_a.lib in the buildroot/lib folder.

EDIT: latest changes from main resolved it for me

@phenaproxima
Copy link
Contributor Author

@crazywhalecc I can confirm that the build issue is fixed, but unfortunately Windows still reports that SSL is not supported.

@crazywhalecc
Copy link
Owner

Okay, I will check it locally at weekend.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working kind/extension Issues related to extensions os/windows Things only for Windows
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants