Skip to content

Commit

Permalink
Bug 1882174: Vendor application-services into mozilla-central r=adw,lina
Browse files Browse the repository at this point in the history
  • Loading branch information
Daisuke Akatsuka committed Feb 28, 2024
1 parent a7467e3 commit 46f89ef
Show file tree
Hide file tree
Showing 15 changed files with 269 additions and 82 deletions.
4 changes: 2 additions & 2 deletions .cargo/config.in
Original file line number Diff line number Diff line change
Expand Up @@ -55,9 +55,9 @@ git = "https://github.com/mozilla-spidermonkey/jsparagus"
rev = "61f399c53a641ebd3077c1f39f054f6d396a633c"
replace-with = "vendored-sources"

[source."git+https://github.com/mozilla/application-services?rev=0b241a66c0722290b3a42366378b3f97d8c268d7"]
[source."git+https://github.com/mozilla/application-services?rev=5fc8ee2f0f6950e36d4096983757bd046d55df9f"]
git = "https://github.com/mozilla/application-services"
rev = "0b241a66c0722290b3a42366378b3f97d8c268d7"
rev = "5fc8ee2f0f6950e36d4096983757bd046d55df9f"
replace-with = "vendored-sources"

[source."git+https://github.com/mozilla/audioipc?rev=596bdb7fbb5745ea415726e16bd497e6c850a540"]
Expand Down
24 changes: 12 additions & 12 deletions Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

14 changes: 7 additions & 7 deletions Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -207,13 +207,13 @@ warp = { git = "https://github.com/seanmonstar/warp", rev = "9d081461ae1167eb321
malloc_size_of_derive = { path = "xpcom/rust/malloc_size_of_derive" }

# application-services overrides to make updating them all simpler.
interrupt-support = { git = "https://github.com/mozilla/application-services", rev = "0b241a66c0722290b3a42366378b3f97d8c268d7" }
sql-support = { git = "https://github.com/mozilla/application-services", rev = "0b241a66c0722290b3a42366378b3f97d8c268d7" }
suggest = { git = "https://github.com/mozilla/application-services", rev = "0b241a66c0722290b3a42366378b3f97d8c268d7" }
sync15 = { git = "https://github.com/mozilla/application-services", rev = "0b241a66c0722290b3a42366378b3f97d8c268d7" }
tabs = { git = "https://github.com/mozilla/application-services", rev = "0b241a66c0722290b3a42366378b3f97d8c268d7" }
viaduct = { git = "https://github.com/mozilla/application-services", rev = "0b241a66c0722290b3a42366378b3f97d8c268d7" }
webext-storage = { git = "https://github.com/mozilla/application-services", rev = "0b241a66c0722290b3a42366378b3f97d8c268d7" }
interrupt-support = { git = "https://github.com/mozilla/application-services", rev = "5fc8ee2f0f6950e36d4096983757bd046d55df9f" }
sql-support = { git = "https://github.com/mozilla/application-services", rev = "5fc8ee2f0f6950e36d4096983757bd046d55df9f" }
suggest = { git = "https://github.com/mozilla/application-services", rev = "5fc8ee2f0f6950e36d4096983757bd046d55df9f" }
sync15 = { git = "https://github.com/mozilla/application-services", rev = "5fc8ee2f0f6950e36d4096983757bd046d55df9f" }
tabs = { git = "https://github.com/mozilla/application-services", rev = "5fc8ee2f0f6950e36d4096983757bd046d55df9f" }
viaduct = { git = "https://github.com/mozilla/application-services", rev = "5fc8ee2f0f6950e36d4096983757bd046d55df9f" }
webext-storage = { git = "https://github.com/mozilla/application-services", rev = "5fc8ee2f0f6950e36d4096983757bd046d55df9f" }

# Patch mio 0.8.8 to use windows-sys 0.52 (backport https://github.com/tokio-rs/mio/commit/eea9e3e0c469480e5c59c01e6c3c7e5fd88f0848)
mio_0_8 = { package = "mio", git = "https://github.com/glandium/mio", rev = "9a2ef335c366044ffe73b1c4acabe50a1daefe05" }
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@ const REMOTE_SETTINGS_RECORDS = [
locationSigns: [{ keyword: "in", needLocation: true }],
yelpModifiers: [],
icon: "1234",
score: 0.5,
},
},
];
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,7 @@ const REMOTE_SETTINGS_RECORDS = [
locationSigns: [{ keyword: "in", needLocation: true }],
yelpModifiers: [],
icon: "1234",
score: 0.5,
},
},
];
Expand Down
2 changes: 1 addition & 1 deletion third_party/rust/nss_build_common/.cargo-checksum.json
Original file line number Diff line number Diff line change
@@ -1 +1 @@
{"files":{"Cargo.toml":"6597b6d5217376ab747534364a58958ddbb23ffda52045e68b610cd8f2dcdfd1","src/lib.rs":"0abb87e42c9fb1c8e199721a258ef6d6eb05df0efd1e4e0696fc60cc3440041f"},"package":null}
{"files":{"Cargo.toml":"6597b6d5217376ab747534364a58958ddbb23ffda52045e68b610cd8f2dcdfd1","src/lib.rs":"9f7379d76c3c663fba7aceb0cc273ab459e1dd9a25664354402c3895bbd25240"},"package":null}
6 changes: 3 additions & 3 deletions third_party/rust/nss_build_common/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -92,13 +92,13 @@ fn link_nss_libs(kind: LinkingKind) {
let target_arch = env::var("CARGO_CFG_TARGET_ARCH").unwrap();
if target_arch == "x86_64" && target_os == "android" {
let android_home = env::var("ANDROID_HOME").expect("ANDROID_HOME not set");
const ANDROID_NDK_VERSION: &str = "25.2.9519653";
const ANDROID_NDK_VERSION: &str = "26.2.11394342";
// One of these will exist, depending on the host platform.
const DARWIN_X86_64_LIB_DIR: &str =
"/toolchains/llvm/prebuilt/darwin-x86_64/lib64/clang/14.0.7/lib/linux/";
"/toolchains/llvm/prebuilt/darwin-x86_64/lib/clang/17/lib/linux/";
println!("cargo:rustc-link-search={android_home}/ndk/{ANDROID_NDK_VERSION}/{DARWIN_X86_64_LIB_DIR}");
const LINUX_X86_64_LIB_DIR: &str =
"/toolchains/llvm/prebuilt/linux-x86_64/lib64/clang/14.0.7/lib/linux/";
"/toolchains/llvm/prebuilt/linux-x86_64/lib/clang/17/lib/linux/";
println!("cargo:rustc-link-search={android_home}/ndk/{ANDROID_NDK_VERSION}/{LINUX_X86_64_LIB_DIR}");
println!("cargo:rustc-link-lib=static=clang_rt.builtins-x86_64-android");
}
Expand Down
2 changes: 1 addition & 1 deletion third_party/rust/suggest/.cargo-checksum.json
Original file line number Diff line number Diff line change
@@ -1 +1 @@
{"files":{"Cargo.toml":"4aa81cff67e67b08ba3348c1acddaa5aee887df3c35006754c9cda4273a94458","README.md":"8d7457893194e255b87e5a2667ee25c87bd470f5338d7078506f866a67a3fdbd","build.rs":"78780c5cccfe22c3ff4198624b9e188559c437c3e6fa1c8bb66548eee6aa66bf","src/config.rs":"03630b2219b6674e332a1f96f44db74def17f985c850a800299b815fa72241c2","src/db.rs":"d373ad097edac2bbcc6e1b14f51c21b6e2cab2289d27667332798c9cde4dcbef","src/error.rs":"f563210a6c050d98ec85e0f6d9401e7373bfb816e865e8edabbabb23d848ba13","src/keyword.rs":"988d0ab021c0df19cfd3c519df7d37f606bf984cd14d0efca4e5a7aff88344dd","src/lib.rs":"65a035dbfb17e2d2d9f237ad52dc03982ae28c70e3dcf3d96cc9f2d7af79efe3","src/pocket.rs":"c4dda43390d1c39dc795933596b3c1e4e282932cac6c69da53c6e05d39e9ef29","src/provider.rs":"4fe662587efc5a80d000c217ce124506c6800293c50ff460ef95e9e659c764b9","src/rs.rs":"5dc41f6fac152b9f87d77a6b97b30377403d089649c35f6550460494d79246d0","src/schema.rs":"4c7264cd70050fbc1f711c80727ca65f7103d0e06d9247eacc5cc42b965bcd6f","src/store.rs":"77e1b8580fbd5e725a20d8da721e420306a762331046cb46faa4cee239ebe946","src/suggest.udl":"7dcc48cadcac44f67830d320b1e964e59d389b935107f18a066e5b30275073e7","src/suggestion.rs":"5994710ddefbcb4589e25b7b89854344b58bfb6754e13d0aa0549a8c188a0899","src/yelp.rs":"8f90146f5b32ea04b7506cae217c5025d532337ac9acd977866f110979559101","uniffi.toml":"f26317442ddb5b3281245bef6e60ffcb78bb95d29fe4a351a56dbb88d4ec8aab"},"package":null}
{"files":{"Cargo.toml":"4aa81cff67e67b08ba3348c1acddaa5aee887df3c35006754c9cda4273a94458","README.md":"8d7457893194e255b87e5a2667ee25c87bd470f5338d7078506f866a67a3fdbd","build.rs":"78780c5cccfe22c3ff4198624b9e188559c437c3e6fa1c8bb66548eee6aa66bf","src/config.rs":"03630b2219b6674e332a1f96f44db74def17f985c850a800299b815fa72241c2","src/db.rs":"d373ad097edac2bbcc6e1b14f51c21b6e2cab2289d27667332798c9cde4dcbef","src/error.rs":"f563210a6c050d98ec85e0f6d9401e7373bfb816e865e8edabbabb23d848ba13","src/keyword.rs":"988d0ab021c0df19cfd3c519df7d37f606bf984cd14d0efca4e5a7aff88344dd","src/lib.rs":"65a035dbfb17e2d2d9f237ad52dc03982ae28c70e3dcf3d96cc9f2d7af79efe3","src/pocket.rs":"c4dda43390d1c39dc795933596b3c1e4e282932cac6c69da53c6e05d39e9ef29","src/provider.rs":"4fe662587efc5a80d000c217ce124506c6800293c50ff460ef95e9e659c764b9","src/rs.rs":"0910368f9e7c4703b00d0de86902d647d70c1f75a256fbeb2126c91f0499a083","src/schema.rs":"8fad4cc624f48946676adbc3de7d061f05fe82531523008f417d6130a2132e34","src/store.rs":"a869971d5593bec2dd40822ba63d0e5a5def96a870ff5a7c33afbcbf5869946b","src/suggest.udl":"d941662596d48793d1570e5b8432b7fd7b4fb1b4550fb38d4e14224fcf4195bc","src/suggestion.rs":"7ee407949f40d88e5d3d4c0da400b987e85ace9f34c648f010cd7f5f2aba0506","src/yelp.rs":"37e77900c12c68cca292a84c6dd6c67d16628c68f4612d8d9bedb1bddf985229","uniffi.toml":"f26317442ddb5b3281245bef6e60ffcb78bb95d29fe4a351a56dbb88d4ec8aab"},"package":null}
1 change: 1 addition & 0 deletions third_party/rust/suggest/src/rs.rs
Original file line number Diff line number Diff line change
Expand Up @@ -298,6 +298,7 @@ pub(crate) struct DownloadedYelpSuggestion {
pub yelp_modifiers: Vec<String>,
#[serde(rename = "icon")]
pub icon_id: String,
pub score: f64,
}

/// An MDN suggestion to ingest from an attachment
Expand Down
5 changes: 3 additions & 2 deletions third_party/rust/suggest/src/schema.rs
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ use sql_support::open_database::{self, ConnectionInitializer};
/// 1. Bump this version.
/// 2. Add a migration from the old version to the new version in
/// [`SuggestConnectionInitializer::upgrade_from`].
pub const VERSION: u32 = 13;
pub const VERSION: u32 = 14;

/// The current Suggest database schema.
pub const SQL: &str = "
Expand Down Expand Up @@ -102,6 +102,7 @@ pub const SQL: &str = "
CREATE TABLE yelp_custom_details(
icon_id TEXT PRIMARY KEY,
score REAL NOT NULL,
record_id TEXT NOT NULL
) WITHOUT ROWID;
Expand Down Expand Up @@ -140,7 +141,7 @@ impl ConnectionInitializer for SuggestConnectionInitializer {

fn upgrade_from(&self, _db: &Transaction<'_>, version: u32) -> open_database::Result<()> {
match version {
1..=12 => {
1..=13 => {
// Treat databases with these older schema versions as corrupt,
// so that they'll be replaced by a fresh, empty database with
// the current schema.
Expand Down
Loading

0 comments on commit 46f89ef

Please sign in to comment.