From 4ad8c5a78182587db58fa1ec943962d4eb8fb386 Mon Sep 17 00:00:00 2001 From: Hanno Braun Date: Thu, 13 Oct 2022 12:33:04 +0200 Subject: [PATCH] Disable default `egui-winit` features This takes care of this error: ``` 2022-10-13T10:23:44.527262Z ERROR egui_winit::clipboard: Cannot initialize smithay clipboard without a display handle! at /home/hanno/.cargo/registry/src/github.com-1ecc6299db9ec823/egui-winit-0.19.0/src/clipboard.rs:139 ``` See #807 for more context. --- Cargo.lock | 228 ++---------------------------------- crates/fj-window/Cargo.toml | 5 +- 2 files changed, 14 insertions(+), 219 deletions(-) diff --git a/Cargo.lock b/Cargo.lock index ba5f04829..823d90e79 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -98,23 +98,6 @@ dependencies = [ "num-traits", ] -[[package]] -name = "arboard" -version = "2.1.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "dc120354d1b5ec6d7aaf4876b602def75595937b5e15d356eb554ab5177e08bb" -dependencies = [ - "clipboard-win", - "log", - "objc", - "objc-foundation", - "objc_id", - "parking_lot", - "thiserror", - "winapi", - "x11rb", -] - [[package]] name = "arc-swap" version = "1.5.1" @@ -317,7 +300,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "a22a6a8f622f797120d452c630b0ab12e1331a1a753e2039ce7868d4ac77b4ee" dependencies = [ "log", - "nix 0.24.2", + "nix", "slotmap", "thiserror", "vec_map", @@ -360,12 +343,6 @@ version = "1.0.73" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "2fff2a6927b3bb87f9595d67196a70493f627687a71d87a0d692242c33f58c11" -[[package]] -name = "cesu8" -version = "1.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6d43a04d8753f35258c91f8ec639f792891f748a1edbd759cf1dcea3382ad83c" - [[package]] name = "cfg-if" version = "1.0.0" @@ -431,17 +408,6 @@ dependencies = [ "os_str_bytes", ] -[[package]] -name = "clipboard-win" -version = "4.4.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c4ab1b92798304eedc095b53942963240037c0516452cb11aeba709d420b2219" -dependencies = [ - "error-code", - "str-buf", - "winapi", -] - [[package]] name = "cmake" version = "0.1.48" @@ -517,16 +483,6 @@ dependencies = [ "unicode-width", ] -[[package]] -name = "combine" -version = "4.6.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "35ed6e9d84f0b51a7f52daf1c7d71dd136fd7a3f41a8462b8cdb8c78d920fad4" -dependencies = [ - "bytes", - "memchr", -] - [[package]] name = "copyless" version = "0.1.5" @@ -864,12 +820,9 @@ version = "0.19.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "07ddc525334c416e11580123e147b970f738507f427c9fb1cd09ea2dd7416a3a" dependencies = [ - "arboard", "egui", "instant", - "smithay-clipboard", "tracing", - "webbrowser", "winit", ] @@ -925,16 +878,6 @@ dependencies = [ "parking_lot", ] -[[package]] -name = "error-code" -version = "2.3.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "64f18991e7bf11e7ffee451b5318b5c1a73c52d0d0ada6e5a3017c8c1ced6a21" -dependencies = [ - "libc", - "str-buf", -] - [[package]] name = "expat-sys" version = "2.1.6" @@ -1335,16 +1278,6 @@ dependencies = [ "byteorder 1.4.3", ] -[[package]] -name = "gethostname" -version = "0.2.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c1ebd34e35c46e00bb73e81363248d627782724609fe1b6396f553f68fe3862e" -dependencies = [ - "libc", - "winapi", -] - [[package]] name = "getrandom" version = "0.2.7" @@ -1701,20 +1634,6 @@ version = "1.0.4" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "4217ad341ebadf8d8e724e264f13e593e0648f5b3e94b3896a5df283be015ecc" -[[package]] -name = "jni" -version = "0.19.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c6df18c2e3db7e453d3c6ac5b3e9d5182664d28788126d39b91f2d1e22b017ec" -dependencies = [ - "cesu8", - "combine", - "jni-sys", - "log", - "thiserror", - "walkdir", -] - [[package]] name = "jni-sys" version = "0.3.0" @@ -2018,19 +1937,6 @@ dependencies = [ "tempfile", ] -[[package]] -name = "ndk" -version = "0.6.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2032c77e030ddee34a6787a64166008da93f6a352b629261d0fee232b8742dd4" -dependencies = [ - "bitflags", - "jni-sys", - "ndk-sys 0.3.0", - "num_enum", - "thiserror", -] - [[package]] name = "ndk" version = "0.7.0" @@ -2039,7 +1945,7 @@ checksum = "451422b7e4718271c8b5b3aadf5adedba43dc76312454b387e98fae0fc951aa0" dependencies = [ "bitflags", "jni-sys", - "ndk-sys 0.4.0", + "ndk-sys", "num_enum", "raw-window-handle 0.5.0", "thiserror", @@ -2051,21 +1957,6 @@ version = "0.1.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "27b02d87554356db9e9a873add8782d4ea6e3e58ea071a9adb9a2e8ddb884a8b" -[[package]] -name = "ndk-glue" -version = "0.6.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0d0c4a7b83860226e6b4183edac21851f05d5a51756e97a1144b7f5a6b63e65f" -dependencies = [ - "lazy_static", - "libc", - "log", - "ndk 0.6.0", - "ndk-context", - "ndk-macro", - "ndk-sys 0.3.0", -] - [[package]] name = "ndk-glue" version = "0.7.0" @@ -2074,10 +1965,10 @@ checksum = "0434fabdd2c15e0aab768ca31d5b7b333717f03cf02037d5a0a3ff3c278ed67f" dependencies = [ "libc", "log", - "ndk 0.7.0", + "ndk", "ndk-context", "ndk-macro", - "ndk-sys 0.4.0", + "ndk-sys", "once_cell", "parking_lot", ] @@ -2095,15 +1986,6 @@ dependencies = [ "syn", ] -[[package]] -name = "ndk-sys" -version = "0.3.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6e5a6ae77c8ee183dcbbba6150e2e6b9f3f4196a7666c02a715a95692ec1fa97" -dependencies = [ - "jni-sys", -] - [[package]] name = "ndk-sys" version = "0.4.0" @@ -2113,19 +1995,6 @@ dependencies = [ "jni-sys", ] -[[package]] -name = "nix" -version = "0.22.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e4916f159ed8e5de0082076562152a76b7a1f64a01fd9d1e0fea002c37624faf" -dependencies = [ - "bitflags", - "cc", - "cfg-if", - "libc", - "memoffset", -] - [[package]] name = "nix" version = "0.24.2" @@ -2294,17 +2163,6 @@ dependencies = [ "objc_exception", ] -[[package]] -name = "objc-foundation" -version = "0.1.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1add1b659e36c9607c7aab864a76c7a4c2760cd0cd2e120f3fb8b952c7e22bf9" -dependencies = [ - "block", - "objc", - "objc_id", -] - [[package]] name = "objc_exception" version = "0.1.2" @@ -2314,15 +2172,6 @@ dependencies = [ "cc", ] -[[package]] -name = "objc_id" -version = "0.1.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c92d4ddb4bd7b50d730c215ff871754d0da6b2178849f8a2a2ab69712d0c073b" -dependencies = [ - "objc", -] - [[package]] name = "object" version = "0.29.0" @@ -3198,23 +3047,13 @@ dependencies = [ "lazy_static", "log", "memmap2", - "nix 0.24.2", + "nix", "pkg-config", "wayland-client", "wayland-cursor", "wayland-protocols", ] -[[package]] -name = "smithay-clipboard" -version = "0.6.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0a345c870a1fae0b1b779085e81b51e614767c239e93503588e54c5b17f4b0e8" -dependencies = [ - "smithay-client-toolkit", - "wayland-client", -] - [[package]] name = "snafu" version = "0.7.2" @@ -3305,12 +3144,6 @@ dependencies = [ "byteorder 0.4.2", ] -[[package]] -name = "str-buf" -version = "1.0.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9e08d8363704e6c71fc928674353e6b7c23dcea9d82d7012c8faf2a3a025f8d0" - [[package]] name = "strsim" version = "0.10.0" @@ -3837,7 +3670,7 @@ dependencies = [ "bitflags", "downcast-rs", "libc", - "nix 0.24.2", + "nix", "scoped-tls", "wayland-commons", "wayland-scanner", @@ -3850,7 +3683,7 @@ version = "0.29.5" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "8691f134d584a33a6606d9d717b95c4fa20065605f798a3f350d78dced02a902" dependencies = [ - "nix 0.24.2", + "nix", "once_cell", "smallvec", "wayland-sys", @@ -3862,7 +3695,7 @@ version = "0.29.5" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "6865c6b66f13d6257bef1cd40cbfe8ef2f150fb8ebbdb1e8e873455931377661" dependencies = [ - "nix 0.24.2", + "nix", "wayland-client", "xcursor", ] @@ -3911,20 +3744,6 @@ dependencies = [ "wasm-bindgen", ] -[[package]] -name = "webbrowser" -version = "0.7.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fc6a3cffdb686fbb24d9fb8f03a213803277ed2300f11026a3afe1f108dc021b" -dependencies = [ - "jni", - "ndk-glue 0.6.2", - "url", - "web-sys", - "widestring", - "winapi", -] - [[package]] name = "wgpu" version = "0.13.1" @@ -4041,12 +3860,6 @@ dependencies = [ "safe_arch 0.6.0", ] -[[package]] -name = "widestring" -version = "0.5.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "17882f045410753661207383517a6f62ec3dbeb6a4ed2acce01f0728238d1983" - [[package]] name = "winapi" version = "0.3.9" @@ -4072,15 +3885,6 @@ dependencies = [ "winapi", ] -[[package]] -name = "winapi-wsapoll" -version = "0.1.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "44c17110f57155602a80dca10be03852116403c9ff3cd25b079d666f2aa3df6e" -dependencies = [ - "winapi", -] - [[package]] name = "winapi-x86_64-pc-windows-gnu" version = "0.4.0" @@ -4145,8 +3949,8 @@ dependencies = [ "libc", "log", "mio", - "ndk 0.7.0", - "ndk-glue 0.7.0", + "ndk", + "ndk-glue", "objc", "once_cell", "parking_lot", @@ -4192,18 +3996,6 @@ dependencies = [ "pkg-config", ] -[[package]] -name = "x11rb" -version = "0.9.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6e99be55648b3ae2a52342f9a870c0e138709a3493261ce9b469afe6e4df6d8a" -dependencies = [ - "gethostname", - "nix 0.22.3", - "winapi", - "winapi-wsapoll", -] - [[package]] name = "xcursor" version = "0.3.4" diff --git a/crates/fj-window/Cargo.toml b/crates/fj-window/Cargo.toml index ada8da742..5092bc562 100644 --- a/crates/fj-window/Cargo.toml +++ b/crates/fj-window/Cargo.toml @@ -15,8 +15,11 @@ fj-host.workspace = true fj-operations.workspace = true fj-viewer.workspace = true fj-interop.workspace = true -egui-winit = "0.19.0" futures = "0.3.24" thiserror = "1.0.35" tracing = "0.1.37" winit = "0.27.4" + +[dependencies.egui-winit] +version = "0.19.0" +default-features = false