From d13275cec3baacd68bc60f3710812625a6a0ee8e Mon Sep 17 00:00:00 2001 From: Julian Noble Date: Mon, 7 Aug 2023 01:01:56 +1000 Subject: [PATCH] make.tcl only search for sdx after determining if there are runtimes to install --- src/make.tcl | 13 ++++++++----- 1 file changed, 8 insertions(+), 5 deletions(-) diff --git a/src/make.tcl b/src/make.tcl index c469fc4f..c63af6d2 100644 --- a/src/make.tcl +++ b/src/make.tcl @@ -42,11 +42,6 @@ if {![llength $vfs_folders]} { } file mkdir $sourcefolder/_build -if {[catch {exec sdx help} errM]} { - puts stderr "FAILED to find usable sdx command - check that sdx executable is on path" - puts stderr "err: $errM" - exit 1 -} #find runtime - only supports one for now.. REVIEW set rtfolder $sourcefolder/runtime set runtimes [glob -nocomplain -dir $rtfolder -types {f x} -tail *] @@ -54,6 +49,14 @@ if {![llength $runtimes]} { puts stderr "No executable runtimes found in $rtfolder - unable to build any .vfs folders into executables." exit 2 } + +if {[catch {exec sdx help} errM]} { + puts stderr "FAILED to find usable sdx command - check that sdx executable is on path" + puts stderr "err: $errM" + exit 1 +} + + if {[llength $runtimes] > 1} { puts stderr "Found multiple runtimes in $rtfolder ($runtimes) - unable to proceed - currently limited to one." exit 3