Browse Source

Fix build.tcl for case when sdx uses punk runtime instead of external tclsh

master
Julian Noble 1 year ago
parent
commit
b9380691d2
  1. 11
      src/make.tcl

11
src/make.tcl

@ -60,6 +60,11 @@ if {[llength $runtimes] > 1} {
} }
set runtimefile [lindex $runtimes 0] set runtimefile [lindex $runtimes 0]
#sdx *may* be pointed to use the runtime we use to build the kit, or the user may manually use this runtime if they don't have tclsh
#sdx will complain if the same runtime is used for the shell as is used in the -runtime argument - so we make a copy (REVIEW)
if {![file exists $sourcefolder/_build/buildruntime.exe]} {
file copy $rtfolder/$runtimefile $sourcefolder/_build/buildruntime.exe
}
puts stdout "Found [llength $vfs_folders] .vfs folders - building executable for each..." puts stdout "Found [llength $vfs_folders] .vfs folders - building executable for each..."
foreach vfs $vfs_folders { foreach vfs $vfs_folders {
@ -72,12 +77,12 @@ foreach vfs $vfs_folders {
file delete $sourcefolder/_build/$vfsname file delete $sourcefolder/_build/$vfsname
} }
puts stdout "building $vfsname with sdx.." puts stdout "building $vfsname with sdx.. vfsdir:$vfs cwd: [pwd]"
if {[catch { if {[catch {
exec sdx wrap _build/$vfsname -runtime runtime/$runtimefile -verbose exec sdx wrap [pwd]/_build/$vfsname -vfs [pwd]/$vfs -runtime $sourcefolder/_build/buildruntime.exe -verbose
} result]} { } result]} {
puts stderr "sdx wrap _build/$vfsname -runtime runtime/$runtimefile -verbose failed with msg: $result" puts stderr "sdx wrap _build/$vfsname -vfs [pwd]/$vfs -runtime $sourcefolder/_build/buildruntime.exe -verbose failed with msg: $result"
} else { } else {
puts stdout "ok - finished sdx" puts stdout "ok - finished sdx"
set separator [string repeat = 40] set separator [string repeat = 40]

Loading…
Cancel
Save