Skip to content

Commit

Permalink
abi: Don't export symbols in static Windows libraries
Browse files Browse the repository at this point in the history
libtool takes care of building both object versions, we just need to pick the
right one to export symbols.
  • Loading branch information
theuni committed May 4, 2022
1 parent 485f608 commit 6f6cab9
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion include/secp256k1.h
Expand Up @@ -141,9 +141,13 @@ typedef int (*secp256k1_nonce_function)(
# define SECP256K1_NO_BUILD
#endif

/** At secp256k1 build-time DLL_EXPORT is defined when building objects destined
* for a shared library, but not for those intended for static libraries.
*/

#ifndef SECP256K1_API
# if defined(_WIN32)
# ifdef SECP256K1_BUILD
# if defined(SECP256K1_BUILD) && defined(DLL_EXPORT)
# define SECP256K1_API __declspec(dllexport)
# else
# define SECP256K1_API
Expand Down

0 comments on commit 6f6cab9

Please sign in to comment.