aboutsummaryrefslogtreecommitdiffstats
path: root/cmd/utils
diff options
context:
space:
mode:
authorPéter Szilágyi <peterke@gmail.com>2017-08-03 12:32:47 +0800
committerPéter Szilágyi <peterke@gmail.com>2017-08-04 00:39:34 +0800
commit4a260dc1f28719be860937a2b0c9574d59e51ab9 (patch)
tree9a7c8f141ff326b2d9d895c5848acc1ce8251bc6 /cmd/utils
parentbc0e6a5e68904b2a1251240b85dd97dc8fa07e11 (diff)
downloadgo-tangerine-4a260dc1f28719be860937a2b0c9574d59e51ab9.tar.gz
go-tangerine-4a260dc1f28719be860937a2b0c9574d59e51ab9.tar.zst
go-tangerine-4a260dc1f28719be860937a2b0c9574d59e51ab9.zip
cmd: add makecache cmd, use caches during import cmd
Diffstat (limited to 'cmd/utils')
-rw-r--r--cmd/utils/flags.go5
1 files changed, 4 insertions, 1 deletions
diff --git a/cmd/utils/flags.go b/cmd/utils/flags.go
index 9f7b76c12..04728b5c6 100644
--- a/cmd/utils/flags.go
+++ b/cmd/utils/flags.go
@@ -1093,7 +1093,10 @@ func MakeChain(ctx *cli.Context, stack *node.Node) (chain *core.BlockChain, chai
engine := ethash.NewFaker()
if !ctx.GlobalBool(FakePoWFlag.Name) {
- engine = ethash.New("", 1, 0, "", 1, 0)
+ engine = ethash.New(
+ stack.ResolvePath(eth.DefaultConfig.EthashCacheDir), eth.DefaultConfig.EthashCachesInMem, eth.DefaultConfig.EthashCachesOnDisk,
+ stack.ResolvePath(eth.DefaultConfig.EthashDatasetDir), eth.DefaultConfig.EthashDatasetsInMem, eth.DefaultConfig.EthashDatasetsOnDisk,
+ )
}
config, _, err := core.SetupGenesisBlock(chainDb, MakeGenesis(ctx))
if err != nil {