Skip to content

Commit 4e745eb

Browse files
committed
Better lowmemory feature with precomputed ECMULT
1 parent 12e3c66 commit 4e745eb

File tree

2 files changed

+1166
-1
lines changed

2 files changed

+1166
-1
lines changed

secp256k1-sys/build.rs

+3-1
Original file line numberDiff line numberDiff line change
@@ -43,7 +43,9 @@ fn main() {
4343
.define("USE_SCALAR_INV_BUILTIN", Some("1"));
4444

4545
if cfg!(feature = "lowmemory") {
46-
base_config.define("ECMULT_WINDOW_SIZE", Some("4")); // A low-enough value to consume neglible memory
46+
base_config.define("ECMULT_WINDOW_SIZE", Some("4")) // A low-enough value to consume neglible memory
47+
.include("depend/config")
48+
.define("USE_ECMULT_STATIC_PRECOMPUTATION", Some("1"));
4749
} else {
4850
base_config.define("ECMULT_WINDOW_SIZE", Some("15")); // This is the default in the configure file (`auto`)
4951
}

0 commit comments

Comments
 (0)