You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
build: Add SECP256K1_NO_EXPORTS option to avoid default visibility for static libs
autotools defines DLL_EXPORT for dll builds. CMake mimics this behavior and
defines SECP256K1_DLL_EXPORT.
This means that currently Windows builds only export their symbols for shared
libraries, and all other platforms export for shared AND static.
Unfortunately, there's no way to make autotools define a special variable when
building for other platforms.
CMake could define a variable for shared lib builds on all platforms, which the
header could then use to decide whether or not to export symbols, but that
would introduce a behavioral difference between the build-systems.
Instead, provide an escape hatch via SECP256K1_NO_EXPORTS which can be used
when building secp for non-Windows targets when exports are not desired (when
building a static lib).
0 commit comments