From da4c7e7ed675c3bf405668739c3012d140856109 Mon Sep 17 00:00:00 2001 From: Daniel Baumann Date: Wed, 15 May 2024 05:34:42 +0200 Subject: Adding upstream version 126.0. Signed-off-by: Daniel Baumann --- toolkit/library/moz.build | 7 ++++++- toolkit/library/rust/gkrust-features.mozbuild | 2 +- toolkit/library/rust/moz.build | 3 +++ toolkit/library/rust/shared/Cargo.toml | 25 ++++++++++++++----------- toolkit/library/rust/shared/lib.rs | 13 ++++++------- 5 files changed, 30 insertions(+), 20 deletions(-) (limited to 'toolkit/library') diff --git a/toolkit/library/moz.build b/toolkit/library/moz.build index 185d5f74d0..9fa86b386b 100644 --- a/toolkit/library/moz.build +++ b/toolkit/library/moz.build @@ -59,7 +59,7 @@ def Libxul(name, output_category=None): ] if CONFIG["ACCESSIBILITY"]: - DELAYLOAD_DLLS += ["oleacc.dll"] + DELAYLOAD_DLLS += ["oleacc.dll", "UIAutomationCore.dll"] if CONFIG["MOZ_WEBRTC"]: DELAYLOAD_DLLS += ["msdmo.dll"] @@ -100,6 +100,7 @@ def Libxul(name, output_category=None): LDFLAGS += ["-Wl,-U,_OBJC_CLASS_$_NSCustomTouchBarItem"] LDFLAGS += ["-Wl,-U,_OBJC_CLASS_$_NSPopoverTouchBarItem"] LDFLAGS += ["-lresolv"] + LDFLAGS += ["-Wl,-rpath,@executable_path/../Frameworks/ChannelPrefs.framework"] if CONFIG["MOZ_DEBUG_SYMBOLS"] and CONFIG["CC_TYPE"] == "clang-cl": LDFLAGS += ["-NATVIS:%s/toolkit/library/gecko.natvis" % TOPSRCDIR] @@ -232,6 +233,9 @@ if CONFIG["MOZ_WIDGET_TOOLKIT"] == "cocoa": "-framework CoreSymbolication", "cups", ] + USE_LIBS += [ + "ChannelPrefs", + ] if CONFIG["MOZ_WIDGET_TOOLKIT"] == "uikit": OS_LIBS += [ @@ -377,6 +381,7 @@ if CONFIG["OS_ARCH"] == "WINNT": if CONFIG["ACCESSIBILITY"]: OS_LIBS += [ "oleacc", + "uiautomationcore", ] # Prevent winapi-rs from statically linking diff --git a/toolkit/library/rust/gkrust-features.mozbuild b/toolkit/library/rust/gkrust-features.mozbuild index 7b0724960f..bca833213c 100644 --- a/toolkit/library/rust/gkrust-features.mozbuild +++ b/toolkit/library/rust/gkrust-features.mozbuild @@ -21,7 +21,7 @@ if CONFIG["MOZ_WEBRENDER_DEBUGGER"]: if CONFIG["MOZ_PULSEAUDIO"]: gkrust_features += ["cubeb_pulse_rust"] -if CONFIG["MOZ_AUDIOUNIT_RUST"]: +if CONFIG["MOZ_AUDIOUNIT_RUST"] and CONFIG["MOZ_WIDGET_TOOLKIT"] == "cocoa": gkrust_features += ["cubeb_coreaudio_rust"] if CONFIG["MOZ_RUST_SIMD"]: diff --git a/toolkit/library/rust/moz.build b/toolkit/library/rust/moz.build index 0935410268..0926e21a5b 100644 --- a/toolkit/library/rust/moz.build +++ b/toolkit/library/rust/moz.build @@ -21,6 +21,7 @@ for feature in gkrust_features: # Target directory doesn't matter a lot here, since we can't share panic=abort # compilation artifacts with gkrust. RUST_TESTS = [ + "crashreporter", "firefox-on-glean", "l10nregistry", "selectors", @@ -34,6 +35,8 @@ RUST_TESTS = [ if CONFIG["TARGET_OS"] in ("WINNT", "OSX"): RUST_TESTS += ["nmhproxy"] +RUST_TEST_FEATURES.append("crashreporter/mock") + # Code coverage builds link a bunch of Gecko bindings code from the style # crate, which is not used by our tests but would cause link errors. # diff --git a/toolkit/library/rust/shared/Cargo.toml b/toolkit/library/rust/shared/Cargo.toml index 4e7ab800a2..70f783a00f 100644 --- a/toolkit/library/rust/shared/Cargo.toml +++ b/toolkit/library/rust/shared/Cargo.toml @@ -22,11 +22,11 @@ static_prefs = { path = "../../../../modules/libpref/init/static_prefs" } profiler_helper = { path = "../../../../tools/profiler/rust-helper", optional = true } mozurl = { path = "../../../../netwerk/base/mozurl" } webrender_bindings = { path = "../../../../gfx/webrender_bindings" } -cubeb-coreaudio = { git = "https://github.com/mozilla/cubeb-coreaudio-rs", rev = "d23ab55eab684b46f46e1da177c8814f6103a009", optional = true } +cubeb-coreaudio = { git = "https://github.com/mozilla/cubeb-coreaudio-rs", rev = "cc58f92f28015e4e25eba9e482007cf464c10474", optional = true } cubeb-pulse = { git = "https://github.com/mozilla/cubeb-pulse-rs", rev="8ff972c8e2ec1782ff262ac4071c0415e69b1367", optional = true, features=["pulse-dlopen"] } cubeb-sys = { version = "0.12.0", optional = true, features=["gecko-in-tree"] } -audioipc2-client = { git = "https://github.com/mozilla/audioipc", rev = "596bdb7fbb5745ea415726e16bd497e6c850a540", optional = true } -audioipc2-server = { git = "https://github.com/mozilla/audioipc", rev = "596bdb7fbb5745ea415726e16bd497e6c850a540", optional = true } +audioipc2-client = { git = "https://github.com/mozilla/audioipc", rev = "409e11f8de6288e9ddfe269654523735302e59e6", optional = true } +audioipc2-server = { git = "https://github.com/mozilla/audioipc", rev = "409e11f8de6288e9ddfe269654523735302e59e6", optional = true } encoding_glue = { path = "../../../../intl/encoding_glue" } authrs_bridge = { path = "../../../../dom/webauthn/authrs_bridge" } gkrust_utils = { path = "../../../../xpcom/rust/gkrust_utils" } @@ -44,7 +44,7 @@ bitsdownload = { path = "../../../components/bitsdownload", optional = true } storage = { path = "../../../../storage/rust" } bookmark_sync = { path = "../../../components/places/bookmark_sync", optional = true } chardetng_c = "0.1.1" -audio_thread_priority = { version = "0.31", default_features = false } +audio_thread_priority = { version = "0.32", default_features = false } mdns_service = { path="../../../../dom/media/webrtc/transport/mdns_service", optional = true } neqo_glue = { path = "../../../../netwerk/socket/neqo_glue" } wgpu_bindings = { path = "../../../../gfx/wgpu_bindings" } @@ -67,22 +67,24 @@ mozannotation_server = { path = "../../../crashreporter/mozannotation_server", gecko-profiler = { path = "../../../../tools/profiler/rust-api"} midir_impl = { path = "../../../../dom/midi/midir_impl", optional = true } dom = { path = "../../../../dom/base/rust" } +dom_fragmentdirectives = { path="../../../../dom/base/fragmentdirectives" } origin-trials-ffi = { path = "../../../../dom/origin-trials/ffi" } jog = { path = "../../../components/glean/bindings/jog" } dap_ffi = { path = "../../../components/telemetry/dap/ffi" } data-encoding-ffi = { path = "../../../../dom/fs/parent/rust/data-encoding-ffi" } -uniffi-example-arithmetic = { git = "https://github.com/mozilla/uniffi-rs.git", rev = "afb29ebdc1d9edf15021b1c5332fc9f285bbe13b", optional = true } -uniffi-example-geometry = { git = "https://github.com/mozilla/uniffi-rs.git", rev = "afb29ebdc1d9edf15021b1c5332fc9f285bbe13b", optional = true } -uniffi-example-rondpoint = { git = "https://github.com/mozilla/uniffi-rs.git", rev = "afb29ebdc1d9edf15021b1c5332fc9f285bbe13b", optional = true } -uniffi-example-sprites = { git = "https://github.com/mozilla/uniffi-rs.git", rev = "afb29ebdc1d9edf15021b1c5332fc9f285bbe13b", optional = true } -uniffi-example-todolist = { git = "https://github.com/mozilla/uniffi-rs.git", rev = "afb29ebdc1d9edf15021b1c5332fc9f285bbe13b", optional = true } +uniffi-example-arithmetic = { git = "https://github.com/mozilla/uniffi-rs.git", rev = "d52c5460ae42ecad1e73a5b394ac96d48f4769de", optional = true } +uniffi-example-geometry = { git = "https://github.com/mozilla/uniffi-rs.git", rev = "d52c5460ae42ecad1e73a5b394ac96d48f4769de", optional = true } +uniffi-example-rondpoint = { git = "https://github.com/mozilla/uniffi-rs.git", rev = "d52c5460ae42ecad1e73a5b394ac96d48f4769de", optional = true } +uniffi-example-sprites = { git = "https://github.com/mozilla/uniffi-rs.git", rev = "d52c5460ae42ecad1e73a5b394ac96d48f4769de", optional = true } +uniffi-example-todolist = { git = "https://github.com/mozilla/uniffi-rs.git", rev = "d52c5460ae42ecad1e73a5b394ac96d48f4769de", optional = true } uniffi-example-custom-types = { path = "../../../components/uniffi-example-custom-types/", optional = true } uniffi-fixture-callbacks = { path = "../../../components/uniffi-fixture-callbacks/", optional = true } uniffi-fixture-external-types = { path = "../../../components/uniffi-fixture-external-types/", optional = true } +uniffi-fixture-refcounts = { path = "../../../components/uniffi-fixture-refcounts/", optional = true } binary_http = { path = "../../../../netwerk/protocol/http/binary_http" } oblivious_http = { path = "../../../../netwerk/protocol/http/oblivious_http" } mime-guess-ffi = { path = "../../../../dom/fs/parent/rust/mime-guess-ffi" } -uniffi = { version = "0.25.2" } +uniffi = { workspace = true } # Note: `modern_sqlite` means rusqlite's bindings file be for a sqlite with # version less than or equal to what we link to. This isn't a problem because we @@ -113,6 +115,7 @@ viaduct = "0.1" webext_storage_bridge = { path = "../../../components/extensions/storage/webext_storage_bridge" } tabs = { version = "0.1" } suggest = { version = "0.1" } +relevancy = { version = "0.1" } [target.'cfg(target_os = "windows")'.dependencies] detect_win32k_conflicts = { path = "../../../xre/detect_win32k_conflicts" } @@ -143,7 +146,7 @@ thread_sanitizer = ["xpcom/thread_sanitizer"] uniffi_fixtures = [ "uniffi-example-arithmetic", "uniffi-example-geometry", "uniffi-example-rondpoint", "uniffi-example-sprites", "uniffi-example-todolist", "uniffi-example-custom-types", "uniffi-fixture-callbacks", - "uniffi-fixture-external-types", + "uniffi-fixture-external-types", "uniffi-fixture-refcounts", ] webmidi_midir_impl = ["midir_impl"] icu4x = ["jsrust_shared/icu4x"] diff --git a/toolkit/library/rust/shared/lib.rs b/toolkit/library/rust/shared/lib.rs index 0179c27a05..7108e3c17c 100644 --- a/toolkit/library/rust/shared/lib.rs +++ b/toolkit/library/rust/shared/lib.rs @@ -24,6 +24,7 @@ extern crate cubeb_coreaudio; #[cfg(feature = "cubeb_pulse_rust")] extern crate cubeb_pulse; extern crate data_storage; +extern crate dom_fragmentdirectives; extern crate encoding_glue; extern crate fog_control; extern crate gecko_profiler; @@ -57,18 +58,15 @@ extern crate webext_storage_bridge; extern crate tabs; #[cfg(not(target_os = "android"))] -mod reexport_tabs { +mod reexport_appservices_uniffi_scaffolding { tabs::uniffi_reexport_scaffolding!(); + relevancy::uniffi_reexport_scaffolding!(); + suggest::uniffi_reexport_scaffolding!(); } #[cfg(not(target_os = "android"))] extern crate suggest; -#[cfg(not(target_os = "android"))] -mod reexport_suggest { - suggest::uniffi_reexport_scaffolding!(); -} - #[cfg(feature = "webrtc")] extern crate mdns_service; extern crate neqo_glue; @@ -138,6 +136,7 @@ mod uniffi_fixtures { uniffi_fixture_callbacks::uniffi_reexport_scaffolding!(); uniffi_custom_types::uniffi_reexport_scaffolding!(); uniffi_fixture_external_types::uniffi_reexport_scaffolding!(); + uniffi_fixture_refcounts::uniffi_reexport_scaffolding!(); uniffi_geometry::uniffi_reexport_scaffolding!(); uniffi_rondpoint::uniffi_reexport_scaffolding!(); uniffi_sprites::uniffi_reexport_scaffolding!(); @@ -176,7 +175,7 @@ pub unsafe extern "C" fn debug_log(target: *const c_char, message: *const c_char // Define extern "C" versions of these UniFFI functions, so that they can be called from C++ #[no_mangle] pub extern "C" fn uniffi_rustbuffer_alloc( - size: i32, + size: u64, call_status: &mut uniffi::RustCallStatus, ) -> uniffi::RustBuffer { uniffi::uniffi_rustbuffer_alloc(size, call_status) -- cgit v1.2.3