Skip to content
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

Entry Point Not Found: AcquireSRWLockExclusive (KERNEL32.DLL) #32

Closed
Fierelier opened this issue Apr 7, 2022 · 7 comments
Closed

Entry Point Not Found: AcquireSRWLockExclusive (KERNEL32.DLL) #32

Fierelier opened this issue Apr 7, 2022 · 7 comments
Labels

Comments

@Fierelier
Copy link

I did this

I downloaded the newest build from https://curl.se/windows/, and ran the exe. I received the following error: The procedure entry point AcquireSRWLockExclusive could not be located in the dynamic link library KERNEL32.dll. I suspect the latest version caused this.

curl/libcurl version

curl-7.81.0-win32-mingw

operating system

Windows XP Professional Service Pack 3 (5.1.2600)

@jay
Copy link
Member

jay commented Apr 7, 2022

Windows XP Professional Service Pack 3 (5.1.2600)

curl for windows official build is built using MSYS2 which requires the minimum OS to be Vista I think.

/cc @vszakats

@jay jay added build labels Apr 7, 2022
@vszakats
Copy link
Member

vszakats commented Apr 8, 2022

The missing reference comes from OpenSSL 3.x, so the live build environment [Linux mingw-w64/clang cross-toolchain] isn't relevant here: https://github.com/openssl/openssl/blob/b3242ca622ef3da34ebb7b78b1f82cd5f0b516e7/crypto/threads_win.c#L76
It's referenced if _WIN32_WINNT >= 0x600 (= Vista or above).

curl-for-win does not override _WIN32_WINNT, and the toolchain / respective package defaults are used. Apparently these are not Windows XP compatible anymore.

One possible solution is to override the default with -D_WIN32_WINNT=0x0501 for x86 builds, another one is to build curl-for-win with Schannel support only. It may also be fixed/mitigated in OpenSSL.

@vszakats
Copy link
Member

vszakats commented Apr 8, 2022

Can someone confirm if this test build works on various x86 Windows systems (XP included)?:
https://ci.appveyor.com/project/curlorg/curl-for-win/builds/43171473/artifacts

It includes this patch:
3188563

@Fierelier
Copy link
Author

I did curl https://curl.se, with success, on the following systems:

  • Windows XP Professional Service Pack 3 (5.1.2600) - 32-bit
  • Windows 7 Ultimate Service Pack 1 (6.1.7601) - 64-bit
    I can test on Windows 10 in a couple of hours, if no one else has done it till then.

@vszakats vszakats transferred this issue from curl/curl Apr 8, 2022
@Fierelier
Copy link
Author

I did the same test on Windows 10 Home 21H2 (19044.1288) 64-bit with success. I'll do the same with W11 as well.

@Fierelier
Copy link
Author

Actually, I'm burnt-out as-is with installing W10, I reckon it oughta run on W11.

@vszakats
Copy link
Member

vszakats commented Apr 8, 2022

Thank you @Fierelier, I think this is fine for now. I'm more worried of future fallouts due to stepping off the default build path; so pushing this patch on an experimental note.

@vszakats vszakats added bug and removed build labels Feb 16, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Development

No branches or pull requests

3 participants