diff options
Diffstat (limited to 'platform/linuxbsd/detect.py')
-rw-r--r-- | platform/linuxbsd/detect.py | 26 |
1 files changed, 11 insertions, 15 deletions
diff --git a/platform/linuxbsd/detect.py b/platform/linuxbsd/detect.py index afc9d25a80..303a88ab26 100644 --- a/platform/linuxbsd/detect.py +++ b/platform/linuxbsd/detect.py @@ -1,11 +1,11 @@ import os import platform import sys -from methods import print_warning, print_error, get_compiler_version, using_gcc -from platform_methods import detect_arch - from typing import TYPE_CHECKING +from methods import get_compiler_version, print_error, print_warning, using_gcc +from platform_methods import detect_arch + if TYPE_CHECKING: from SCons.Script.SConscript import SConsEnvironment @@ -50,7 +50,7 @@ def get_opts(): BoolVariable("wayland", "Enable Wayland display", True), BoolVariable("libdecor", "Enable libdecor support", True), BoolVariable("touch", "Enable touch events", True), - BoolVariable("execinfo", "Use libexecinfo on systems where glibc is not available", None), + BoolVariable("execinfo", "Use libexecinfo on systems where glibc is not available", False), ] @@ -65,10 +65,10 @@ def get_doc_path(): def get_flags(): - return [ - ("arch", detect_arch()), - ("supported", ["mono"]), - ] + return { + "arch": detect_arch(), + "supported": ["mono"], + } def configure(env: "SConsEnvironment"): @@ -309,7 +309,7 @@ def configure(env: "SConsEnvironment"): if not env["builtin_embree"] and env["arch"] in ["x86_64", "arm64"]: # No pkgconfig file so far, hardcode expected lib name. - env.Append(LIBS=["embree3"]) + env.Append(LIBS=["embree4"]) if not env["builtin_openxr"]: env.ParseConfig("pkg-config openxr --cflags --libs") @@ -491,16 +491,12 @@ def configure(env: "SConsEnvironment"): env.Append(LIBS=["dl"]) if platform.libc_ver()[0] != "glibc": - # The default crash handler depends on glibc, so if the host uses - # a different libc (BSD libc, musl), fall back to libexecinfo. - if not "execinfo" in env: - print("Note: Using `execinfo=yes` for the crash handler as required on platforms where glibc is missing.") - env["execinfo"] = True - if env["execinfo"]: env.Append(LIBS=["execinfo"]) env.Append(CPPDEFINES=["CRASH_HANDLER_ENABLED"]) else: + # The default crash handler depends on glibc, so if the host uses + # a different libc (BSD libc, musl), libexecinfo is required. print("Note: Using `execinfo=no` disables the crash handler on platforms where glibc is missing.") else: env.Append(CPPDEFINES=["CRASH_HANDLER_ENABLED"]) |