-
Notifications
You must be signed in to change notification settings - Fork 2.2k
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
cmake fails to build with -DZSTD_PROGRAMS_LINK_SHARED=ON on windows #3554
Comments
Thank you for reporting @anarazel .
|
@yoniko Thanks for the quick reply.
I haven't seen it on other platforms, but I haven't tried hard. I normally am not a windows person, I am just working on CI stuff, forcing me to touch windows things (I want to use the zstd binary in tests, hence modifying the vcpkg port to allow that, hitting this issue).
It reproduces on both dev and 1.5.4. It does not reproduce on v1.5.2. I think a similar approach to #3496 could be implemented for the cmake build. |
That indeed works. Oddly enough, zstd-dll also has a custom xxhash.c reference, which doesn't seem to be required with msvc. Ah, and I see why this doesn't fail on !windows: While lib/Makefile adds If you add
Which is nice, because it allows fixing this outside of windows :) |
I'd open a PR with the, pretty obvious, fix - but it looks like I'd need to get legal involved due to the CLA. |
Sounds good, a PR would be very much appreciated. |
I'll check what legal says about the CLA. |
(still waiting, sorry for that) |
Any news @anarazel? We are also hitting this in conda-forge and would love a patch 😬 |
Hi,
building with -DZSTD_PROGRAMS_LINK_SHARED=ON results in:
The reason is fairly simple: The API in pool.h isn't made visible, therefore the references from programs/fileio.c can't see them.
Before 1598e6c a build like this worked. CC: @yoniko
It looks like it'd be easy enough to fix for POOL_create, POOL_free, there are public wrappers. But for the rest there isn't an obvious answer.
Regards,
Andres
The text was updated successfully, but these errors were encountered: