Commit 8c38e9a
sync rusqlite features with OSS builds
Summary:
`fbsource//third-party/rust:rusqlite` has the following features:
https://www.internalfb.com/code/fbsource/[0a5b6cbfa91cd299242d2357db8c8d997e93124b]/third-party/rust/BUCK?lines=163714-163723
2 of these features (`bundled` and `modern_sqlite`) were missing from `third-party/rust/Cargo.toml` and thus not getting synced to all the OSS Cargo.toml files via autocargo. Since the 1.87.0 release, `dune` builds started failing with similar instances to the following error (full trace: P1827721702):
```bash
(.text._ZN8rusqlite9functions61_$LT$impl$u20$rusqlite..inner_connection..InnerConnection$GT$15remove_function17h24530d63b3657513E+0xbd): undefined reference to `sqlite3_create_function_v2'
# more text
```
`sqlite3_create_function_v2` and similar `sqlite3_*` functions come from `libsqlite3-sys`, an internal crate of `rusqlite`, as bindgen-generated bindings. Looking at the `bindgen.rs` files before and after this change (P1827816771) there are a ton of differences but I "think" the reason for the error before this change is owed to `bundled` generating `cargo:rustc-link-lib=static=sqlite3` vs non-`bundled` generating `cargo:rustc-link-lib=dylib=sqlite3`. There is a bunch more logic in the `build.rs` that is gated behind the `bundled` feature so could be a confluence of factors. Build is green though again, so I will leave the rest of the investigation to anyone inclined to spend more time on this.
Worth also highlighting the cost of maintaining OSS bespoke builds vs the standard `buck`-based builds :(
Reviewed By: dtolnay
Differential Revision: D75695703
fbshipit-source-id: 4379d0ad27d7dd9d9b352711010df37bcf1d68341 parent 674b4bb commit 8c38e9a
1 file changed
+1
-1
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
27 | 27 | | |
28 | 28 | | |
29 | 29 | | |
30 | | - | |
| 30 | + | |
31 | 31 | | |
32 | 32 | | |
33 | 33 | | |
| |||
0 commit comments