diff --git a/src/blsct/arith/mcl/mcl_init.h b/src/blsct/arith/mcl/mcl_init.h index 76132cba7b50b6..f1f27b98a8c1a2 100644 --- a/src/blsct/arith/mcl/mcl_init.h +++ b/src/blsct/arith/mcl/mcl_init.h @@ -35,7 +35,13 @@ class MclInit static bool is_initialized = false; if (is_initialized) return; - if (blsInit(MCL_BLS12_381, MCLBN_COMPILED_TIME_VAR) != 0) { +#ifndef MCLBN_COMPILED_TIME_VAR + int compiledTimeVar = 0; +#else + int compiledTimeVar = MCLBN_COMPILED_TIME_VAR; +#endif + + if (blsInit(MCL_BLS12_381, compiledTimeVar) != 0) { throw std::runtime_error("blsInit failed"); } mclBn_setETHserialization(1);