[Scummvm-git-logs] scummvm master -> ac316baf809f64d2111a0ff3d3616cded9311b6a

sev- noreply at scummvm.org
Tue Oct 27 10:48:31 UTC 2026


This automated email contains information about 1 new commit which have been
pushed to the 'scummvm' repo located at https://api.github.com/repos/scummvm/scummvm .

Summary:
ac316baf80 ALL: Turn sjis into a proper component


Commit: ac316baf809f64d2111a0ff3d3616cded9311b6a
    https://github.com/scummvm/scummvm/commit/ac316baf809f64d2111a0ff3d3616cded9311b6a
Author: Eugene Sandulenko (sev at scummvm.org)
Date: 2026-10-27T11:48:17+01:00

Commit Message:
ALL: Turn sjis into a proper component

Changed paths:
    configure
    engines/agos/configure.engine
    engines/harold/configure.engine
    engines/kyra/configure.engine
    engines/saga/configure.engine
    engines/sci/configure.engine
    engines/scumm/configure.engine
    graphics/module.mk
    graphics/sjis.cpp
    graphics/sjis.h


diff --git a/configure b/configure
index 43897a7d2d1..92b1fd8790f 100755
--- a/configure
+++ b/configure
@@ -173,6 +173,7 @@ _osxdockplugin=auto
 _jpeg=auto
 _png=auto
 _gif=auto
+_sjis=auto
 _theoradec=auto
 _vpx=auto
 _faad=auto
@@ -364,6 +365,7 @@ add_component mpeg2 "mpeg2" "_mpeg2" "USE_MPEG2"
 add_component msmpeg4 "Microsoft MPEG-4 v3" "_msmpeg4" "USE_MSMPEG4"
 add_component qdm2 "QDM2" "_qdm2" "USE_QDM2"
 add_component sid_audio "SID audio" "_sid_audio" "USE_SID_AUDIO"
+add_component sjis "SJIS" "_sjis" "USE_SJIS"
 add_component svq1 "Sorenson Video 1" "_svq1" "USE_SVQ1"
 add_component tinygl "TinyGL" "_tinygl" "USE_TINYGL"
 add_component truemotion1 "TrueMotion 1" "_truemotion1" "USE_TRUEMOTION1"
@@ -1351,8 +1353,8 @@ for ac_option in $@; do
 	--disable-mikmod)             _libmikmod=no          ;;
 	--enable-openmpt)             _libopenmpt=yes        ;;
 	--disable-openmpt)            _libopenmpt=no         ;;
-	--enable-mpcdec)              _libmpcdec=yes        ;;
-	--disable-mpcdec)             _libmpcdec=no         ;;
+	--enable-mpcdec)              _libmpcdec=yes         ;;
+	--disable-mpcdec)             _libmpcdec=no          ;;
 	--enable-a52)                 _a52=yes               ;;
 	--disable-a52)                _a52=no                ;;
 	--disable-jpeg)               _jpeg=no               ;;
@@ -1361,6 +1363,8 @@ for ac_option in $@; do
 	--enable-png)                 _png=yes               ;;
 	--disable-gif)                _gif=no                ;;
 	--enable-gif)                 _gif=yes               ;;
+	--disable-sjis)               _sjis=no               ;;
+	--enable-sjis)                _sjis=yes              ;;
 	--disable-theoradec)          _theoradec=no          ;;
 	--enable-theoradec)           _theoradec=yes         ;;
 	--disable-vpx)                _vpx=no                ;;
diff --git a/engines/agos/configure.engine b/engines/agos/configure.engine
index ee712257d83..e596aca3af8 100644
--- a/engines/agos/configure.engine
+++ b/engines/agos/configure.engine
@@ -1,4 +1,4 @@
 # This file is included from the main "configure" script
 # add_engine [name] [desc] [build-by-default] [subengines] [base games] [deps] [components]
-add_engine agos "AGOS" yes "agos2" "AGOS 1 games" "" "midi fmtowns_pc98_audio"
+add_engine agos "AGOS" yes "agos2" "AGOS 1 games" "" "midi fmtowns_pc98_audio sjis"
 add_engine agos2 "AGOS 2 games" yes "" "" "highres"
diff --git a/engines/harold/configure.engine b/engines/harold/configure.engine
index 365da369e28..3418e2e2b2f 100644
--- a/engines/harold/configure.engine
+++ b/engines/harold/configure.engine
@@ -1,4 +1,4 @@
 # This file is included from the main "configure" script
 # add_engine [name] [desc] [build-by-default] [subengines] [base games] [deps] [components]
 add_engine harold "J.B. Harold series" no "bcb"
-add_engine bcb "J.B. Harold: Blue Chicago Blues" no "" "" "highres 16bit" "msmpeg4"
+add_engine bcb "J.B. Harold: Blue Chicago Blues" no "" "" "highres 16bit" "msmpeg4 sjis"
diff --git a/engines/kyra/configure.engine b/engines/kyra/configure.engine
index 3c757b1a450..47ad279f4c7 100644
--- a/engines/kyra/configure.engine
+++ b/engines/kyra/configure.engine
@@ -1,5 +1,5 @@
 # This file is included from the main "configure" script
 # add_engine [name] [desc] [build-by-default] [subengines] [base games] [deps] [components]
-add_engine kyra "Kyra" yes "lol eob" "Legend of Kyrandia 1-3" "" "midi fmtowns_pc98_audio"
+add_engine kyra "Kyra" yes "lol eob" "Legend of Kyrandia 1-3" "" "midi fmtowns_pc98_audio sjis"
 add_engine lol "Lands of Lore" yes
 add_engine eob "Eye of the Beholder" yes
diff --git a/engines/saga/configure.engine b/engines/saga/configure.engine
index fdce67fe555..068e0db01c1 100644
--- a/engines/saga/configure.engine
+++ b/engines/saga/configure.engine
@@ -1,4 +1,4 @@
 # This file is included from the main "configure" script
 # add_engine [name] [desc] [build-by-default] [subengines] [base games] [deps] [components]
-add_engine saga "SAGA" yes "ihnm" "ITE" "" "midi fmtowns_pc98_audio"
+add_engine saga "SAGA" yes "ihnm" "ITE" "" "midi fmtowns_pc98_audio sjis"
 add_engine ihnm "IHNM" yes "" "" "highres"
diff --git a/engines/sci/configure.engine b/engines/sci/configure.engine
index b5178f98c47..24161b84bab 100644
--- a/engines/sci/configure.engine
+++ b/engines/sci/configure.engine
@@ -1,4 +1,4 @@
 # This file is included from the main "configure" script
 # add_engine [name] [desc] [build-by-default] [subengines] [base games] [deps] [components]
-add_engine sci "SCI" yes "sci32" "SCI 0-1.1 games" "" "midi fmtowns_pc98_audio"
+add_engine sci "SCI" yes "sci32" "SCI 0-1.1 games" "" "midi fmtowns_pc98_audio sjis"
 add_engine sci32 "SCI32 games" yes "" "" "highres" "indeo3 truemotion1"
diff --git a/engines/scumm/configure.engine b/engines/scumm/configure.engine
index 0f0c80de3f8..86274bfacc5 100644
--- a/engines/scumm/configure.engine
+++ b/engines/scumm/configure.engine
@@ -1,6 +1,6 @@
 # This file is included from the main "configure" script
 # add_engine [name] [desc] [build-by-default] [subengines] [base games] [deps] [components]
-add_engine scumm "SCUMM" yes "scumm_7_8 he rebel2_psx" "v0-v6 games" "" "midi fmtowns_pc98_audio sid_audio imgui"
+add_engine scumm "SCUMM" yes "scumm_7_8 he rebel2_psx" "v0-v6 games" "" "midi fmtowns_pc98_audio sid_audio imgui sjis"
 add_engine scumm_7_8 "v7 & v8 games" yes
 add_engine he "HE71+ games" yes "" "" "highres bink" "enet"
 add_engine rebel2_psx "Rebel Assault II PlayStation" no "" "" "16bit 3d tinygl"
diff --git a/graphics/module.mk b/graphics/module.mk
index d6847ef5a4a..2cc720b52d6 100644
--- a/graphics/module.mk
+++ b/graphics/module.mk
@@ -60,7 +60,6 @@ MODULE_OBJS := \
 	scaler/thumbnail_intern.o \
 	screen.o \
 	scaler/normal.o \
-	sjis.o \
 	surface.o \
 	svg.o \
 	transform_struct.o \
@@ -90,6 +89,10 @@ MODULE_OBJS += \
 	mactoolbox/utils.o
 endif
 
+ifdef USE_SJIS
+MODULE_OBJS += \
+	sjis.o
+endif
 
 ifdef USE_MFC
 MODULE_OBJS += \
diff --git a/graphics/sjis.cpp b/graphics/sjis.cpp
index c4a33f10af3..b41c18b1998 100644
--- a/graphics/sjis.cpp
+++ b/graphics/sjis.cpp
@@ -22,8 +22,6 @@
 #include "common/scummsys.h"
 #include "graphics/sjis.h"
 
-#ifdef GRAPHICS_SJIS_H
-
 #include "common/debug.h"
 #include "common/archive.h"
 #include "common/endian.h"
@@ -549,7 +547,7 @@ const uint8 *FontPC98::getCharData(uint16 ch) const {
 		hiblock = hi - 0x81 - 0x40;
 	else
 		return nullptr;
-	
+
 	uint glyph = hiblock * 192;
 
 	if (lo >= 0x3f && lo <= 0x7e)
@@ -808,5 +806,3 @@ void FontSjisSVM::mapKANJIChar(const uint8 fB, const uint8 sB, int &base, int &i
 }
 
 } // End of namespace Graphics
-
-#endif // defined(GRAPHICS_SJIS_H)
diff --git a/graphics/sjis.h b/graphics/sjis.h
index c801c54be57..831714a8e22 100644
--- a/graphics/sjis.h
+++ b/graphics/sjis.h
@@ -19,17 +19,9 @@
  *
  */
 
-// The code in this file is currently used in BCB, KYRA, SCI, SCUMM,
-// SAGA, and AGOS. If none of those are enabled, we will skip compiling it.
-// We also enable this code for ScummVM builds including support
-// for dynamic engine plugins.
-// If you plan to use this code in another engine, you will have
-// to add the proper define check here.
-#if !(defined(ENABLE_BCB) || defined(ENABLE_KYRA) || defined(ENABLE_SCI) || defined(ENABLE_SCUMM) || defined(ENABLE_SAGA) || defined(ENABLE_AGOS) || defined(DYNAMIC_MODULES))
-
-// If neither of the above mentioned is enabled, do not include the SJIS code.
+#include "common/scummsys.h"
 
-#else
+#ifdef USE_SJIS
 
 #ifndef GRAPHICS_SJIS_H
 #define GRAPHICS_SJIS_H
@@ -330,4 +322,4 @@ private:
 
 #endif
 
-#endif // engine and dynamic plugins guard
+#endif // USE_SJIS




More information about the Scummvm-git-logs mailing list