From 2d8ba537c41b99d1a96e28d6f939455fed40070d Mon Sep 17 00:00:00 2001 From: shiqinfeng1 <150627601@qq.com> Date: Thu, 15 Aug 2019 16:33:06 +0800 Subject: [PATCH] common/compiler: support relative import paths (#17374 #19967) --- common/compiler/solidity.go | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/common/compiler/solidity.go b/common/compiler/solidity.go index 16b91bf747f4c..f0363dc92b182 100644 --- a/common/compiler/solidity.go +++ b/common/compiler/solidity.go @@ -47,7 +47,8 @@ type solcOutput struct { func (s *Solidity) makeArgs() []string { p := []string{ "--combined-json", "bin,bin-runtime,srcmap,srcmap-runtime,abi,userdoc,devdoc", - "--optimize", // code optimizer switched on + "--optimize", // code optimizer switched on + "--allow-paths", "., ./, ../", // default to support relative paths } if s.Major > 0 || s.Minor > 4 || s.Patch > 6 { p[1] += ",metadata,hashes"