diff options
Diffstat (limited to 'platform')
| -rw-r--r-- | platform/osx/os_osx.h | 1 | ||||
| -rw-r--r-- | platform/osx/os_osx.mm | 23 | ||||
| -rw-r--r-- | platform/server/detect.py | 12 | ||||
| -rw-r--r-- | platform/windows/detect.py | 9 | ||||
| -rw-r--r-- | platform/x11/detect.py | 15 |
5 files changed, 16 insertions, 44 deletions
diff --git a/platform/osx/os_osx.h b/platform/osx/os_osx.h index c6a9aeba88..6c81da04f5 100644 --- a/platform/osx/os_osx.h +++ b/platform/osx/os_osx.h @@ -184,7 +184,6 @@ public: virtual void get_fullscreen_mode_list(List<VideoMode> *p_list, int p_screen = 0) const; virtual String get_executable_path() const; - virtual String get_resource_dir() const; virtual LatinKeyboardVariant get_latin_keyboard_variant() const; diff --git a/platform/osx/os_osx.mm b/platform/osx/os_osx.mm index 2e300c963d..9a26adc155 100644 --- a/platform/osx/os_osx.mm +++ b/platform/osx/os_osx.mm @@ -1733,29 +1733,6 @@ String OS_OSX::get_executable_path() const { } } -String OS_OSX::get_resource_dir() const { - /* - Bastiaan Olij - I'm leaving this code commented out but in place so we can have a further discussion about this later on. - For loading the package file from the resource folder it makes more sense to make this call work in ProjectSettings::setup - instead of relying on changing the current working folder as is the case right now (see godot_main_osx.mm). - The problem is that when this function returns a value we try and load a project.godot file from this resources folder and - stop attempting to load anything else if that fails. That breaks our tools build. - One possible solution is to only apply this logic in a non-tools build with an ifdef block. - - For now however, just returning this to working condition. - - // start with our executable path - String path = get_executable_path(); - - int pos = path.find_last("/Contents/MacOS/"); - if (pos < 0) - return OS::get_resource_dir(); - - return path.substr(0, pos) + "/Contents/Resources/"; -*/ - return OS::get_resource_dir(); -} - // Returns string representation of keys, if they are printable. // static NSString *createStringForKeys(const CGKeyCode *keyCode, int length) { diff --git a/platform/server/detect.py b/platform/server/detect.py index 2bb4b59e94..5c13297bc6 100644 --- a/platform/server/detect.py +++ b/platform/server/detect.py @@ -65,15 +65,6 @@ def configure(env): # FIXME: Check for existence of the libs before parsing their flags with pkg-config if (env['builtin_openssl'] == 'no'): - # Currently not compatible with OpenSSL 1.1.0+ - # https://github.com/godotengine/godot/issues/8624 - import subprocess - openssl_version = subprocess.check_output(['pkg-config', 'openssl', '--modversion']).strip('\n') - if (openssl_version >= "1.1.0"): - print("Error: Found system-installed OpenSSL %s, currently only supporting version 1.0.x." % openssl_version) - print("Aborting.. You can compile with 'builtin_openssl=yes' to use the bundled version.\n") - sys.exit(255) - env.ParseConfig('pkg-config openssl --cflags --libs') if (env['builtin_libwebp'] == 'no'): @@ -98,6 +89,9 @@ def configure(env): if (env['builtin_squish'] == 'no' and env["tools"] == "yes"): env.ParseConfig('pkg-config libsquish --cflags --libs') + if env['builtin_zstd'] == 'no': + env.ParseConfig('pkg-config libzstd --cflags --libs') + # Sound and video libraries # Keep the order as it triggers chained dependencies (ogg needed by others, etc.) diff --git a/platform/windows/detect.py b/platform/windows/detect.py index 65eb51a2f3..053ea466f3 100644 --- a/platform/windows/detect.py +++ b/platform/windows/detect.py @@ -64,6 +64,7 @@ def get_opts(): return [ ('mingw_prefix_32', 'MinGW prefix (Win32)', mingw32), ('mingw_prefix_64', 'MinGW prefix (Win64)', mingw64), + ('use_lto', 'Use link time optimization (when using MingW)', 'no'), ('debug_symbols', 'Add debug symbols to release version (yes/no/full)', 'yes') ] @@ -256,11 +257,15 @@ def configure(env): env["CC"] = mingw_prefix + "gcc" env['AS'] = mingw_prefix + "as" env['CXX'] = mingw_prefix + "g++" - env['AR'] = mingw_prefix + "ar" - env['RANLIB'] = mingw_prefix + "ranlib" + env['AR'] = mingw_prefix + "gcc-ar" + env['RANLIB'] = mingw_prefix + "gcc-ranlib" env['LD'] = mingw_prefix + "g++" env["x86_libtheora_opt_gcc"] = True + if (env["use_lto"] == "yes"): + env.Append(CCFLAGS=['-flto']) + env.Append(LINKFLAGS=['-flto']) + ## Compile flags env.Append(CCFLAGS=['-DWINDOWS_ENABLED', '-mwindows']) diff --git a/platform/x11/detect.py b/platform/x11/detect.py index efd388e44f..b9b4ad8201 100644 --- a/platform/x11/detect.py +++ b/platform/x11/detect.py @@ -120,6 +120,9 @@ def configure(env): if (env["use_lto"] == "yes"): env.Append(CCFLAGS=['-flto']) env.Append(LINKFLAGS=['-flto']) + if (env["use_llvm"] == "no"): + env['RANLIB'] = 'gcc-ranlib' + env['AR'] = 'gcc-ar' env.Append(CCFLAGS=['-pipe']) env.Append(LINKFLAGS=['-pipe']) @@ -134,15 +137,6 @@ def configure(env): # FIXME: Check for existence of the libs before parsing their flags with pkg-config if (env['builtin_openssl'] == 'no'): - # Currently not compatible with OpenSSL 1.1.0+ - # https://github.com/godotengine/godot/issues/8624 - import subprocess - openssl_version = subprocess.check_output(['pkg-config', 'openssl', '--modversion']).strip('\n') - if (openssl_version >= "1.1.0"): - print("Error: Found system-installed OpenSSL %s, currently only supporting version 1.0.x." % openssl_version) - print("Aborting.. You can compile with 'builtin_openssl=yes' to use the bundled version.\n") - sys.exit(255) - env.ParseConfig('pkg-config openssl --cflags --libs') if (env['builtin_libwebp'] == 'no'): @@ -167,6 +161,9 @@ def configure(env): if (env['builtin_squish'] == 'no' and env["tools"] == "yes"): env.ParseConfig('pkg-config libsquish --cflags --libs') + if env['builtin_zstd'] == 'no': + env.ParseConfig('pkg-config libzstd --cflags --libs') + # Sound and video libraries # Keep the order as it triggers chained dependencies (ogg needed by others, etc.) |