Split openMSX layout from artifacts and added video recorder.
All checks were successful
Run test asserts / Test-Asserts (push) Successful in -5s

This commit is contained in:
Willem Cazander 2024-06-27 20:14:23 +02:00
parent dd634833ef
commit b4d4fad185
8 changed files with 39 additions and 25 deletions

View file

@ -1,7 +1,7 @@
MB_AUTOEXEC_BYSELF ?= true
MB_AUTOEXEC_BYSELF ?= on
MB_AUTOEXEC_BYSELF_MSG ?= Run msxbuild:
MB_AUTOEXEC_VERSION ?= true
MB_AUTOEXEC_VERSION ?= on
MB_AUTOEXEC_STARTUP_TIMEOUT ?= 60
MB_AUTOEXEC_STARTUP_EXITCODE ?= 124
MB_AUTOEXEC_TEST_TIMEOUT ?= 120
@ -49,8 +49,8 @@ define mb_autoexec_write_default
$(call mb_autoexec_append_cmd,$(1),omsxctl fail_after $(MB_AUTOEXEC_STARTUP_TIMEOUT) seconds failed_exec $(MB_AUTOEXEC_STARTUP_EXITCODE))
$(call mb_autoexec_append_cmd,$(1),omsxctl setcolor 4 000)
$(call mb_autoexec_append_cmd,$(1),omsxctl setcolor 15 777)
$(if $(filter true,$(MB_AUTOEXEC_VERSION)),$(call mb_autoexec_append_cmd,$(1),ver))
$(if $(filter true,$(MB_AUTOEXEC_BYSELF)),$(call mb_autoexec_append_echo,$(1),$(MB_AUTOEXEC_BYSELF_MSG) $(notdir $(1))))
$(if $(filter on,$(MB_AUTOEXEC_VERSION)),$(call mb_autoexec_append_cmd,$(1),ver))
$(if $(filter on,$(MB_AUTOEXEC_BYSELF)),$(call mb_autoexec_append_echo,$(1),$(MB_AUTOEXEC_BYSELF_MSG) $(notdir $(1))))
endef
define _mb_autoexec_open_gui

View file

@ -17,39 +17,40 @@ endef
define mb_msxrom_setup
$(if $(wildcard $(1)-omsx),,$(call mb_mkdir,$(1)-omsx))
$(if $(wildcard $(1)-omsx/systemroms),,$(call mb_mkdir,$(1)-omsx/systemroms))
$(if $(wildcard $(1)-omsx/systemroms/machines),,$(call mb_mkdir,$(1)-omsx/systemroms/machines))
$(if $(wildcard $(1)-omsx/systemroms/extensions),,$(call mb_mkdir,$(1)-omsx/systemroms/extensions))
$(if $(wildcard $(1)-omsx/share),,$(call mb_mkdir,$(1)-omsx/share))
$(if $(wildcard $(1)-omsx/share/systemroms),,$(call mb_mkdir,$(1)-omsx/share/systemroms))
$(if $(wildcard $(1)-omsx/share/systemroms/machines),,$(call mb_mkdir,$(1)-omsx/share/systemroms/machines))
$(if $(wildcard $(1)-omsx/share/systemroms/extensions),,$(call mb_mkdir,$(1)-omsx/share/systemroms/extensions))
endef
define mb_msxrom_extension_ide_nextor
$(call mb_msxrom_file,$(1)-omsx/systemroms/extensions,extensions/Nextor-2.1.1.SunriseIDE.ROM)
$(call mb_msxrom_file,$(1)-omsx/share/systemroms/extensions,extensions/Nextor-2.1.1.SunriseIDE.ROM)
endef
define mb_msxrom_extension_rs232
$(call mb_msxrom_file,$(1)-omsx/systemroms/extensions,extensions/rs232.rom)
$(call mb_msxrom_file,$(1)-omsx/share/systemroms/extensions,extensions/rs232.rom)
endef
define mb_msxrom_extension_fmpac
$(call mb_msxrom_file,$(1)-omsx/systemroms/extensions,extensions/fmpac.rom)
$(call mb_msxrom_file,$(1)-omsx/share/systemroms/extensions,extensions/fmpac.rom)
endef
define mb_msxrom_extension_moonsound
$(call mb_msxrom_file,$(1)-omsx/systemroms/extensions,extensions/yrw801.rom)
$(call mb_msxrom_file,$(1)-omsx/share/systemroms/extensions,extensions/yrw801.rom)
endef
define mb_msxrom_extension_basickun
$(call mb_msxrom_file,$(1)-omsx/systemroms/extensions,machines/sanyo/phc-70fd2_basickun.rom)
$(call mb_msxrom_file,$(1)-omsx/share/systemroms/extensions,machines/sanyo/phc-70fd2_basickun.rom)
endef
define mb_msxrom_machine_Canon_V-20
$(call mb_msxrom_file,$(1)-omsx/systemroms/machines,machines/canon/v-20_basic-bios1.rom)
$(call mb_msxrom_file,$(1)-omsx/share/systemroms/machines,machines/canon/v-20_basic-bios1.rom)
endef
define mb_msxrom_machine_Philips_NMS_8250
$(call mb_msxrom_file,$(1)-omsx/systemroms/machines,machines/philips/nms8250_basic-bios2.rom)
$(call mb_msxrom_file,$(1)-omsx/systemroms/machines,machines/philips/nms8250_msx2sub.rom)
$(call mb_msxrom_file,$(1)-omsx/systemroms/machines,machines/philips/nms8250_disk.rom)
$(call mb_msxrom_file,$(1)-omsx/share/systemroms/machines,machines/philips/nms8250_basic-bios2.rom)
$(call mb_msxrom_file,$(1)-omsx/share/systemroms/machines,machines/philips/nms8250_msx2sub.rom)
$(call mb_msxrom_file,$(1)-omsx/share/systemroms/machines,machines/philips/nms8250_disk.rom)
endef
define mb_msxrom_machine_Boosted_MSX2_EN

View file

@ -13,6 +13,7 @@ MB_OPENMSX_JOYPORTB ?=
MB_OPENMSX_SCALE_FACTOR ?= 3
MB_OPENMSX_THROTTLE ?= off
MB_OPENMSX_RENDERER ?=
MB_OPENMSX_RECORDER ?= off
MB_OPENMSX_CTLCACHE ?= $(MB_CACHE)/msxbuild/omsxctl
define mb_openmsx_setup
@ -21,14 +22,15 @@ define mb_openmsx_setup
$(call mb_msxhub_file,$(MB_OPENMSX_CTLCACHE),OMSXCTL/1.0-1/get/OMSXCTL/omsxctl.com)
$(if $(wildcard $(1)-omsx),,$(call mb_mkdir,$(1)-omsx))
$(if $(wildcard $(1)-omsx/stdio.xml),,$(call mb_copy,$(PATH_MSXBUILD_REAL)/lib/openmsx/stdio.xml,$(1)-omsx))
$(if $(wildcard $(1)-omsx/settings.xml),,$(call mb_copy,$(PATH_MSXBUILD_REAL)/lib/openmsx/settings.xml,$(1)-omsx))
$(if $(wildcard $(1)-omsx/scripts),,$(call mb_mkdir,$(1)-omsx/scripts))
$(if $(wildcard $(1)-omsx/scripts/boot_env.tcl),,$(call mb_copy,$(PATH_MSXBUILD_REAL)/lib/openmsx/scripts/boot_env.tcl,$(1)-omsx/scripts))
$(if $(wildcard $(1)-omsx/scripts/boot_hdd.tcl),,$(call mb_copy,$(PATH_MSXBUILD_REAL)/lib/openmsx/scripts/boot_hdd.tcl,$(1)-omsx/scripts))
$(if $(wildcard $(1)-omsx/scripts/fail_after.tcl),,$(call mb_copy,$(PATH_MSXBUILD_REAL)/lib/openmsx/scripts/fail_after.tcl,$(1)-omsx/scripts))
$(if $(wildcard $(1)-omsx/scripts/omsxctl.tcl),,$(call mb_copy,$(MB_OPENMSX_CTLCACHE)/omsxctl.tcl,$(1)-omsx/scripts))
$(if $(wildcard $(1)-omsx/extensions),,$(call mb_mkdir,$(1)-omsx/extensions))
$(if $(wildcard $(1)-omsx/extensions/ide-nextor.xml),,$(call mb_copy,$(PATH_MSXBUILD_REAL)/lib/openmsx/extensions/ide-nextor.xml,$(1)-omsx/extensions))
$(if $(wildcard $(1)-omsx/share),,$(call mb_mkdir,$(1)-omsx/share))
$(if $(wildcard $(1)-omsx/share/settings.xml),,$(call mb_copy,$(PATH_MSXBUILD_REAL)/lib/openmsx/share/settings.xml,$(1)-omsx/share))
$(if $(wildcard $(1)-omsx/share/scripts),,$(call mb_mkdir,$(1)-omsx/share/scripts))
$(if $(wildcard $(1)-omsx/share/scripts/boot_env.tcl),,$(call mb_copy,$(PATH_MSXBUILD_REAL)/lib/openmsx/share/scripts/boot_env.tcl,$(1)-omsx/share/scripts))
$(if $(wildcard $(1)-omsx/share/scripts/boot_hdd.tcl),,$(call mb_copy,$(PATH_MSXBUILD_REAL)/lib/openmsx/share/scripts/boot_hdd.tcl,$(1)-omsx/share/scripts))
$(if $(wildcard $(1)-omsx/share/scripts/fail_after.tcl),,$(call mb_copy,$(PATH_MSXBUILD_REAL)/lib/openmsx/share/scripts/fail_after.tcl,$(1)-omsx/share/scripts))
$(if $(wildcard $(1)-omsx/share/scripts/omsxctl.tcl),,$(call mb_copy,$(MB_OPENMSX_CTLCACHE)/omsxctl.tcl,$(1)-omsx/share/scripts))
$(if $(wildcard $(1)-omsx/share/extensions),,$(call mb_mkdir,$(1)-omsx/share/extensions))
$(if $(wildcard $(1)-omsx/share/extensions/ide-nextor.xml),,$(call mb_copy,$(PATH_MSXBUILD_REAL)/lib/openmsx/share/extensions/ide-nextor.xml,$(1)-omsx/share/extensions))
$(call mb_msxrom_setup,$(1))
$(call mb_msxrom_extension_ide_nextor,$(1))
$(call mb_msxrom_machine_$(2),$(1))
@ -47,7 +49,8 @@ define _mb_openmsx_run
SPEED=$(MB_OPENMSX_SPEED) \
RENDERER=$(MB_OPENMSX_RENDERER) \
THROTTLE=$(MB_OPENMSX_THROTTLE) \
OPENMSX_USER_DATA="$(1)-omsx" \
RECORD_SESSION=$(if $(filter on,$(MB_OPENMSX_RECORDER)),"$(1)-omsx/output.avi") \
OPENMSX_USER_DATA="$(1)-omsx/share" \
$(PATH_OPENMSX)/openmsx \
-machine $(2) \
$(MB_OPENMSX_EXTRA_SLOT) \

View file

@ -21,6 +21,9 @@
# JOYPORTB=mouse
# Inserts mouse in joyportb.
#
# RECORD_SESSION=bin/output.avi
# Enables the session video recorder.
#
if {[info exists ::env(RENDERER)] && ([string trim $::env(RENDERER)] != "")} {
if {[catch {set renderer [string trim $::env(RENDERER)]} err_msg]} {
@ -63,3 +66,10 @@ if {[info exists ::env(JOYPORTB)] && ([string trim $::env(JOYPORTB)] != "")} {
exit 1
}
}
if {[info exists ::env(RECORD_SESSION)] && ([string trim $::env(RECORD_SESSION)] != "")} {
if {[catch {after time 1 "record start [string trim $::env(RECORD_SESSION)]"} err_msg]} {
puts stderr "error: env.RECORD_SESSION value $err_msg"
exit 1
}
}