main: move target specification into a separate package

This commit is contained in:
Ayke van Laethem
2019-10-31 15:39:01 +01:00
committed by Ron Evans
parent dff6e6566d
commit e7cf75030c
7 changed files with 129 additions and 114 deletions
+2 -1
View File
@@ -14,6 +14,7 @@ import (
"sort"
"testing"
"github.com/tinygo-org/tinygo/compileopts"
"github.com/tinygo-org/tinygo/loader"
)
@@ -142,7 +143,7 @@ func runTest(path, tmpdir string, target string, t *testing.T) {
if target == "" {
cmd = exec.Command(binary)
} else {
spec, err := LoadTarget(target)
spec, err := compileopts.LoadTarget(target)
if err != nil {
t.Fatal("failed to load target spec:", err)
}