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

sev- noreply at scummvm.org
Sun May 10 09:59:21 UTC 2026


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

Summary:
d9a9f83d50 CONFIGURE: MACOS: Replace `-ObjC++` compiler flag with `-x objective-c++`
b73f6e3094 CONFIGURE: MACOS: Improve NSSpeechSynthesizerDelegate test for Tiger/Leopard


Commit: d9a9f83d50dc1e68757aa0f515eb672554b52390
    https://github.com/scummvm/scummvm/commit/d9a9f83d50dc1e68757aa0f515eb672554b52390
Author: Donovan Watteau (contrib at dwatteau.fr)
Date: 2026-05-10T11:59:17+02:00

Commit Message:
CONFIGURE: MACOS: Replace `-ObjC++` compiler flag with `-x objective-c++`

The former doesn't exist in all compilers; for instance, GCC 7.5.0
from MacPorts doesn't have it, and so all the configure checks for
Objective-C++ could fail, when building for Tiger/Leopard.

The `-x objective-c++` syntax is more portable, but has the additional
requirement of needing to be set before any input file in the argument
list given to cc_check.

So, introduce cc_objc_check for this purpose.

Changed paths:
    configure


diff --git a/configure b/configure
index bb52b25bd8c..32d5c335c4e 100755
--- a/configure
+++ b/configure
@@ -435,6 +435,18 @@ cc_check() {
 	return "$TMPR"
 }
 
+cc_objc_check() {
+	prevcxx=$CXX
+	# `-ObjC++` flag doesn't always exist; `-x` flag is more portable, but
+	# should appear before any input file.
+	CXX="$CXX -x objective-c++ -lobjc"
+	cc_check_no_clean "$@"
+	TMPR="$?"
+	cc_check_clean
+	CXX=$prevcxx
+	return "$TMPR"
+}
+
 cc_check_define() {
 cat > $TMPC << EOF
 int main(void) {
@@ -5441,7 +5453,7 @@ EOF
 @end
 int main(void) { return 0; }
 EOF
-				cc_check -ObjC++ -lobjc && _tts=yes
+				cc_objc_check && _tts=yes
 			else
 				# Check the newer AVSpeechSynthesizer API is available
 				cat > $TMPC << EOF
@@ -5451,7 +5463,7 @@ EOF
 @end
 int main(void) { return 0; }
 EOF
-				cc_check -ObjC++ -lobjc && _tts=yes
+				cc_objc_check && _tts=yes
 			fi
 			;;
 		iphoneos)
@@ -5462,7 +5474,7 @@ EOF
 @end
 int main(void) { return 0; }
 EOF
-			cc_check -ObjC++ -lobjc && _tts=yes
+			cc_objc_check && _tts=yes
 			;;
 		emscripten)
 			# Emscripten has the "Web Speech API" available
@@ -5996,7 +6008,7 @@ case $_host_os in
 #include <Sparkle/Sparkle.h>
 int main(void) { SPUStandardUpdaterController *updater = [[SPUStandardUpdaterController alloc] initWithUpdaterDelegate:nil userDriverDelegate:nil]; return 0; }
 EOF
-				cc_check $SPARKLE_CFLAGS $SPARKLE_LIBS -framework Sparkle -ObjC++ -lobjc && _sparkle=yes
+				cc_objc_check $SPARKLE_CFLAGS $SPARKLE_LIBS -framework Sparkle && _sparkle=yes
 			fi
 			if test "$_sparkle" = yes ; then
 				append_var LIBS "$SPARKLE_LIBS -framework Sparkle"
@@ -6315,8 +6327,9 @@ case $_host_os in
 @interface ScummVMDockTilePlugIn : NSObject <NSDockTilePlugIn> {
 }
 @end
+int main(void) { return 0; }
 EOF
-			cc_check -c -ObjC++ && _osxdockplugin=yes
+			cc_objc_check && _osxdockplugin=yes
 		fi
 		define_in_config_if_yes "$_osxdockplugin" 'USE_DOCKTILEPLUGIN'
 		echo "$_osxdockplugin"


Commit: b73f6e30942fc098b74ca23905e576cab91b8d8c
    https://github.com/scummvm/scummvm/commit/b73f6e30942fc098b74ca23905e576cab91b8d8c
Author: Donovan Watteau (contrib at dwatteau.fr)
Date: 2026-05-10T11:59:17+02:00

Commit Message:
CONFIGURE: MACOS: Improve NSSpeechSynthesizerDelegate test for Tiger/Leopard

On Leopard, using `NSObject<NSSpeechSynthesizerDelegate>` was not
possible yet, so use a plain `NSObject`, but also introduce a test for
the `NSSpeechImmediateBoundary` symbol, so that some proper NSSpeech API
is checked as well.

On Tiger, NSSpeech exists but is missing a lot of the features we're
using.  So, just exclude Tiger.  (This relies on an explicit check for
MAC_OS_X_VERSION_MIN_REQUIRED, as, for some reason I can't explain yet,
targeting 10.5 with the 10.4 SDK would still embed the 10.5+ symbols,
even though they seem to be properly protected in the SDK definitions.)

So, the TTS feature is now available when targeting Leopard (but not
when keeping Tiger compatibility, which the current OSXPPC builds do.)

Changed paths:
    configure


diff --git a/configure b/configure
index 32d5c335c4e..a8e7513a4bf 100755
--- a/configure
+++ b/configure
@@ -5447,11 +5447,19 @@ EOF
 			if test "$_osx_tts_backend" = "NSSpeechSynthesizer" ; then
 				# Check older NSSpeechSynthesizer API.
 				cat > $TMPC << EOF
+#include <AvailabilityMacros.h>
 #include <AppKit/NSSpeechSynthesizer.h>
+#if MAC_OS_X_VERSION_MIN_REQUIRED < 1050
+#error Not enough NSSpeechSynthesizerDelegate features available
+#endif
+#if MAC_OS_X_VERSION_MAX_ALLOWED < 1060
+ at interface SpeechDelegate : NSObject {
+#else
 @interface SpeechDelegate : NSObject<NSSpeechSynthesizerDelegate> {
+#endif
 }
 @end
-int main(void) { return 0; }
+int main(void) { return NSSpeechImmediateBoundary; }
 EOF
 				cc_objc_check && _tts=yes
 			else




More information about the Scummvm-git-logs mailing list