-
-
Notifications
You must be signed in to change notification settings - Fork 6.6k
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
Disabled forced Windows import library suffix, if static library is not built #16324
Conversation
Can you show an example CMake configuration where you experienced this and the expected vs actual result? (and also your C compiler vendor/version) edit: without those, my initial thought was that you wanted to set In the latter case, both shared and static libcurl are built, thus the suffix is required (for MSVC), and this setting tells to build To disable building the shared lib, I suggest trying the first option: |
Thank you for the reply. In my case, I'm on Windows, and using On MSVC, it will output two files:
That's good and all, but I want to get rid of the "_imp" suffix on the .lib. My pull request aims to fix that; since the only ".lib" file I'm building is the import library, there shouldn't be any confusion. I hope you understand my issue better... |
Thanks for explaining! You're right. I confused behaviour with libssh2, which does what I described. The reason it works that way in curl is compatibility with how it worked It'd be arguably better to only add a suffix if both shared and static are built, Then a search https://github.com/search?q=libcurl_imp&type=code convinced Question how to fix this while keeping everyone happy? Using Accepting an override via |
Analysis of PR #16324 at 53394db7: Test 2070 failed, which has NOT been flaky recently, so there could be a real issue in this PR. Test 1631 failed, which has NOT been flaky recently, so there could be a real issue in this PR. Test 363 failed, which has NOT been flaky recently, so there could be a real issue in this PR. Generated by Testclutch |
Proposal to allow overriding suffixes at will, with detection |
Thanks for your report/PR, merged #16332 to fix this. |
Hello everyone.
A short problem I have at my job, we wish to build a shared version of the curl library from source, but on Windows, the "_imp" mandatory library suffix was a problem.
As this suffix is not needed when only the shared version is built and not the static version, this simple change should have no other impact.