ps2, minor fixes
authorkub <derkub@gmail.com>
Tue, 20 Feb 2024 21:04:13 +0000 (22:04 +0100)
committerkub <derkub@gmail.com>
Tue, 20 Feb 2024 23:29:17 +0000 (00:29 +0100)
platform/ps2/Makefile
platform/ps2/emu.c

index 42ba39d..a0e2009 100644 (file)
@@ -6,22 +6,26 @@ $(error need VER)
 endif\r
 endif\r
 \r
+include ../../config.mak\r
+\r
 ../../tools/textfilter: ../../tools/textfilter.c\r
        make -C ../../tools/ textfilter\r
 \r
 readme.txt: ../../tools/textfilter ../base_readme.txt ../../ChangeLog\r
        ../../tools/textfilter ../base_readme.txt $@ PS2\r
 \r
-# ?\r
-rel: ../../PicoDrive readme.txt ../game_def.cfg\r
-       mkdir -p PicoDrive/skin/\r
-       cp $^ PicoDrive/\r
-       cp ../../skin/* PicoDrive/skin/\r
-       zip -9 -r ../../PicoDrive_ps2_$(VER).zip PicoDrive\r
-       rm -rf PicoDrive\r
-       mkdir bin_to_cso_mp3\r
-       cp ../../tools/bin_to_cso_mp3/* bin_to_cso_mp3/\r
-       zip -9 -r ../../PicoDrive_ps2_$(VER).zip bin_to_cso_mp3\r
-       rm -rf bin_to_cso_mp3\r
+PicoDrive: ../../PicoDrive\r
+       $(STRIP) $^ -o $@\r
+\r
+PicoDrive.elf: PicoDrive\r
+       ps2-packer $^ $@\r
 \r
+rel: PicoDrive.elf readme.txt ../game_def.cfg\r
+       mkdir -p out/PicoDrive/skin/ out/bin_to_cso_mp3\r
+       cp $^ out/PicoDrive/\r
+       cp ../../skin/* out/PicoDrive/skin/\r
+       #mkdir -p out/bin_to_cso_mp3\r
+       #cp ../../tools/bin_to_cso_mp3/* out/bin_to_cso_mp3/\r
+       cd out && zip -9 -r ../../../PicoDrive_ps2_$(VER).zip *\r
+       rm -rf out\r
 \r
index d538593..e738fba 100644 (file)
@@ -114,7 +114,7 @@ static void writeSound(int len)
 {
        int ret, l;
 
-       if (samples_made - samples_done < samples_block * (SOUND_BLOCK_COUNT-3)) {
+       if (samples_made - samples_done <= samples_block * (SOUND_BLOCK_COUNT-3)) {
                samples_made += len / 2;
                PicoIn.sndOut += len / 2;
        } else