diff options
Diffstat (limited to 'platform')
| -rw-r--r-- | platform/osx/os_osx.mm | 2 | ||||
| -rw-r--r-- | platform/x11/detect.py | 12 |
2 files changed, 13 insertions, 1 deletions
diff --git a/platform/osx/os_osx.mm b/platform/osx/os_osx.mm index 985811e166..81dc861f3f 100644 --- a/platform/osx/os_osx.mm +++ b/platform/osx/os_osx.mm @@ -326,7 +326,6 @@ static Vector2 get_mouse_pos(NSPoint locationInWindow, CGFloat backingScaleFacto - (void)windowDidBecomeKey:(NSNotification *)notification { //_GodotInputWindowFocus(window, GL_TRUE); //_GodotPlatformSetCursorMode(window, window->cursorMode); - [OS_OSX::singleton->context update]; if (OS_OSX::singleton->get_main_loop()) { get_mouse_pos( @@ -1238,6 +1237,7 @@ Error OS_OSX::initialize(const VideoMode &p_desired, int p_video_driver, int p_a ERR_FAIL_COND_V(window_object == nil, ERR_UNAVAILABLE); window_view = [[GodotContentView alloc] init]; + [window_view setWantsLayer:TRUE]; float displayScale = 1.0; if (is_hidpi_allowed()) { diff --git a/platform/x11/detect.py b/platform/x11/detect.py index ee59e9b5a1..dc5c22b4b3 100644 --- a/platform/x11/detect.py +++ b/platform/x11/detect.py @@ -149,6 +149,18 @@ def configure(env): env.Append(CCFLAGS=['-pipe']) env.Append(LINKFLAGS=['-pipe']) + # Check for gcc version > 4 before adding -no-pie + import re + import subprocess + proc = subprocess.Popen([env['CXX'], '--version'], stdout=subprocess.PIPE) + (stdout, _) = proc.communicate() + match = re.search('[0-9][0-9.]*', stdout) + if match is not None: + version = match.group().split('.') + if (version[0] > '4'): + env.Append(CCFLAGS=['-fpie']) + env.Append(LINKFLAGS=['-no-pie']) + ## Dependencies env.ParseConfig('pkg-config x11 --cflags --libs') |