Skip to content

Commit dfb2bc5

Browse files
committed
Fix macOS build with dev_build=yes and target=template_debug
1 parent 09fcbb8 commit dfb2bc5

File tree

1 file changed

+5
-2
lines changed

1 file changed

+5
-2
lines changed

platform/macos/godot_application.mm

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -63,11 +63,14 @@ - (void)activateApplication {
6363
NSString *nsbundleid_env = [NSString stringWithUTF8String:(bundled_id != nullptr) ? bundled_id : ""];
6464
NSString *nsbundleid = [[NSBundle mainBundle] bundleIdentifier];
6565
if (nsappname == nil || isatty(STDOUT_FILENO) || isatty(STDIN_FILENO) || isatty(STDERR_FILENO) || ![nsbundleid isEqualToString:nsbundleid_env]) {
66-
#if DEV_ENABLED
67-
if (!OS_MacOS::is_debugger_attached())
66+
#ifdef TOOLS_ENABLED
67+
if (!OS_MacOS::is_debugger_attached()) {
68+
#else
69+
{
6870
#endif
6971
// If the executable is started from terminal or is not bundled, macOS WindowServer won't register and activate app window correctly (menu and title bar are grayed out and input ignored).
7072
[self performSelector:@selector(forceUnbundledWindowActivationHackStep1) withObject:nil afterDelay:0.02];
73+
}
7174
}
7275
}
7376

0 commit comments

Comments
 (0)