From 4385efb0f7f8577a4f8ad03ea25e1adef0901a13 Mon Sep 17 00:00:00 2001 From: Wayne Warthen Date: Fri, 8 Jul 2022 10:35:17 -0700 Subject: [PATCH] Unix Build Tweaks Small stuff. Mostly just gets the make diff mechanism working again. Not sure if anyone actually uses it though. --- Build.cmd | 2 +- Source/CPM3/Makefile | 1 + Source/HBIOS/Build.sh | 20 ++++++++++---------- Source/HBIOS/Makefile | 13 +++++++------ Source/TastyBasic/src/Build.cmd | 3 ++- Tools/Makefile.inc | 3 ++- 6 files changed, 23 insertions(+), 19 deletions(-) diff --git a/Build.cmd b/Build.cmd index 2b4a31d1..99a09b02 100644 --- a/Build.cmd +++ b/Build.cmd @@ -3,4 +3,4 @@ setlocal pushd Source && call Build %* || exit /b & popd -pause +if "%*" == "" pause diff --git a/Source/CPM3/Makefile b/Source/CPM3/Makefile index f0c54f75..684aac83 100644 --- a/Source/CPM3/Makefile +++ b/Source/CPM3/Makefile @@ -13,6 +13,7 @@ OTHERS = cpmldr.rel biosldr.rel cpm3res.sys cpm3bnk.sys loader.bin cpmldr.bin OTHERS += biosldrc.rel biosldrd.rel NODELETE = ccp.com gencpm.com genres.dat genbnk.dat bdos3.spr bnkbdos3.spr resbdos3.spr NODELETE += readme.1st cpm3fix.pat +NODIFF = zpmbios3 DEST = ../../Binary/CPM3 TOOLS = ../../Tools diff --git a/Source/HBIOS/Build.sh b/Source/HBIOS/Build.sh index 202fbae2..ad8cd3d0 100755 --- a/Source/HBIOS/Build.sh +++ b/Source/HBIOS/Build.sh @@ -41,16 +41,6 @@ if [ "${ROM_PLATFORM}" == "dist" ] ; then exit fi -###if [ $1 == '-d' ] ; then -### shift -### diffdir=$1 -### shift -### if [ -f $diffdir/build.inc ] ; then -### timestamp=$(grep TIMESTAMP $diffdir/build.inc | awk '{print $3}' | tr -d '\015"') -### echo diff build using $timestamp -### fi -###fi - # prompt if no match platforms=($(find Config -name \*.asm -print | \ sed -e 's,Config/,,' -e 's/_.*$//' | sort -u)) @@ -84,6 +74,16 @@ fi TIMESTAMP=$(date +%Y-%m-%d) +if [ "$1" = "-d" ] ; then + shift + diffdir=$1 + shift + if [ -f $diffdir/build.inc ] ; then + timestamp=$(grep TIMESTAMP $diffdir/build.inc | awk '{print $3}' | tr -d '\015"') + echo diff build using $timestamp + fi +fi + CONFIGFILE=Config/${ROM_PLATFORM}_${ROM_CONFIG}.asm echo Building $ROMNAME for $ROM_PLATFORM $ROM_CONFIG $ROMSIZE diff --git a/Source/HBIOS/Makefile b/Source/HBIOS/Makefile index 2fff3b8f..eaad9983 100644 --- a/Source/HBIOS/Makefile +++ b/Source/HBIOS/Makefile @@ -1,8 +1,7 @@ -MOREDIFF = camel80.bin game.bin hbios_rom.bin nascom.bin prefix.bin usrrom.bin \ +MOREDIFF = game.bin hbios_rom.bin nascom.bin usrrom.bin \ dbgmon.bin hbios_app.bin imgpad2.bin osimg1.bin osimg2.bin romldr.bin \ - eastaegg.bin hbios_img.bin osimg.bin tastybasic.bin \ - game.bin updater.bin usrrom.bin + eastaegg.bin hbios_img.bin osimg.bin game.bin updater.bin usrrom.bin SUBDIRS = DEST = ../../Binary @@ -20,11 +19,13 @@ ifneq ($(findstring $(ROM_PLATFORM), RCZ280),) TASM=$(BINDIR)/uz80as -t z280 endif +# DIFFMAKE = 1 + ifeq ($(DIFFMAKE),1) DIFFBUILD := -d $(DIFFTO)/Source/HBIOS endif -DIFFPATH = $(DIFFTO)/Binary +# DIFFPATH = $(DIFFTO)/Binary DEPS=prereq dbgmon.bin romldr.bin nascom.bin tastybasic.bin game.bin eastaegg.bin updater.bin usrrom.bin imgpad2.bin @@ -47,10 +48,10 @@ ROMNAME=${ROM_PLATFORM}_${ROM_CONFIG} all:: if [ -z "$(OBJECTS)" ] ; then \ chmod +x Build.sh ; \ - bash Build.sh ; \ + bash Build.sh $(DIFFBUILD) ; \ fi -$(ROMNAME).rom $(ROMNAME).com $(ROMNAME).img &: $(ROMDEPS) +$(ROMNAME).rom $(ROMNAME).com $(ROMNAME).img : $(ROMDEPS) cat romldr.bin dbgmon.bin ../ZSDOS/zsys_$(BIOS).bin ../CPM22/cpm_$(BIOS).bin >osimg.bin cat romldr.bin dbgmon.bin ../ZSDOS/zsys_$(BIOS).bin >osimg_small.bin if [ $(ROM_PLATFORM) != UNA ] ; then \ diff --git a/Source/TastyBasic/src/Build.cmd b/Source/TastyBasic/src/Build.cmd index 11a556be..3045a99a 100644 --- a/Source/TastyBasic/src/Build.cmd +++ b/Source/TastyBasic/src/Build.cmd @@ -13,4 +13,5 @@ set VER=v0.3.0 tasm -80 -g3 -fFF -dROMWBW -d"VERSION \"%VER%\"" tastybasic.asm tastybasic.bin tastybasic.bin.lst tasm -80 -g3 -fFF -dCPM -d"VERSION \"%VER%\"" tastybasic.asm tastybasic.com tastybasic.com.lst -copy /b /v tastybasic.com ..\..\..\Binary\Apps\tbasic.com +copy /b /v tastybasic.com tbasic.com +copy /b /v tbasic.com ..\..\..\Binary\Apps\tbasic.com diff --git a/Tools/Makefile.inc b/Tools/Makefile.inc index d52be301..c6813efa 100644 --- a/Tools/Makefile.inc +++ b/Tools/Makefile.inc @@ -166,7 +166,7 @@ ifneq ($(DIFFTO),) @for dir in $(SUBDIRS) ; do \ ( echo "diff in $(HERE)/$$dir" ; cd "$$dir" ; make diff ) ; \ done - @for i in $(OBJECTS) $(MOREDIFF) ; do \ + @for i in $(filter-out $(NODIFF),$(OBJECTS) $(MOREDIFF)) ; do \ sf=$$($(CASEFN) $$i) ; \ df=$$($(CASEFN) $(DIFFPATH)/$$i) ; \ if [ -f "$$df" -a -f "$$sf" ] ; then \ @@ -187,5 +187,6 @@ ifneq ($(DIFFTO),) done endif + vdiff: make VERBOSEDIFF=2 diff