This avoids building without it and makes it safer to use a custom building environment. Test harnesses need to #include secp256k1.c first now.
Fixes #927
SECP256K1_NO_BUILD
(if SECP256K1_BUILD
wasn’t defined already). .c can then error out if SECP256K1_NO_BUILD
was defined.
126@@ -127,6 +127,10 @@ typedef int (*secp256k1_nonce_function)(
127 # define SECP256K1_INLINE inline
128 # endif
129
130+#ifndef SECP256K1_BUILD
131+# define SECP256K1_NO_BUILD
132+#endif
This avoids building without it and makes it safer to use a custom
building environment. Test harnesses need to #include secp256k1.c
first now.
3@@ -4,6 +4,8 @@
4 * file COPYING or https://www.opensource.org/licenses/mit-license.php.*
5 ***********************************************************************/
6
7+#define SECP256K1_BUILD
#ifndef SECP256k1_BUILD
?
-DSECP256K1_BUILD
to the compiler, as we don’t really use “headers” in rust)