StardustXR / server

Stardust XR Reference Server, now blazingly fast in Rust :D

Home Page:https://stardustxr.org/

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Cargo build fail

lkong opened this issue · comments

commented

➜ stardust-xr-server git:(main) ✗ cargo build
Compiling stardust-xr-schemas v0.1.0
Compiling stereokit-sys v1.0.4
error: failed to run custom build command for stereokit-sys v1.0.4

Caused by:
process didn't exit successfully: /home/lkong/workspace/rice/stardust-xr-server/target/debug/build/stereokit-sys-c1e4de3a8832151d/build-script-build (exit status: 101)
--- stdout
CMAKE_TOOLCHAIN_FILE_x86_64-unknown-linux-gnu = None
CMAKE_TOOLCHAIN_FILE_x86_64_unknown_linux_gnu = None
HOST_CMAKE_TOOLCHAIN_FILE = None
CMAKE_TOOLCHAIN_FILE = None
CMAKE_GENERATOR_x86_64-unknown-linux-gnu = None
CMAKE_GENERATOR_x86_64_unknown_linux_gnu = None
HOST_CMAKE_GENERATOR = None
CMAKE_GENERATOR = None
CMAKE_PREFIX_PATH_x86_64-unknown-linux-gnu = None
CMAKE_PREFIX_PATH_x86_64_unknown_linux_gnu = None
HOST_CMAKE_PREFIX_PATH = None
CMAKE_PREFIX_PATH = None
CMAKE_x86_64-unknown-linux-gnu = None
CMAKE_x86_64_unknown_linux_gnu = None
HOST_CMAKE = None
CMAKE = None
running: "cmake" "/home/lkong/.cargo/registry/src/github.com-1ecc6299db9ec823/stereokit-sys-1.0.4/StereoKit" "-DSK_BUILD_SHARED_LIBS=OFF" "-DSK_BUILD_TESTS=OFF" "-DSK_LINUX_EGL=ON" "-DSK_PHYSICS=OFF" "-DCMAKE_INSTALL_PREFIX=/home/lkong/workspace/rice/stardust-xr-server/target/debug/build/stereokit-sys-21e5226600d182e3/out" "-DCMAKE_C_FLAGS= -ffunction-sections -fdata-sections -fPIC -m64" "-DCMAKE_C_COMPILER=/usr/bin/cc" "-DCMAKE_CXX_FLAGS= -ffunction-sections -fdata-sections -fPIC -m64" "-DCMAKE_CXX_COMPILER=/usr/bin/c++" "-DCMAKE_ASM_FLAGS= -ffunction-sections -fdata-sections -fPIC -m64" "-DCMAKE_ASM_COMPILER=/usr/bin/cc" "-DCMAKE_BUILD_TYPE=Debug"
-- Configuring incomplete, errors occurred!
See also "/home/lkong/workspace/rice/stardust-xr-server/target/debug/build/stereokit-sys-21e5226600d182e3/out/build/CMakeFiles/CMakeOutput.log".

--- stderr
CMake Error at CMakeLists.txt:90 (CPMAddPackage):
Unknown CMake command "CPMAddPackage".

thread 'main' panicked at '
command did not execute successfully, got: exit status: 1

build script failed, must exit now', /home/lkong/.cargo/registry/src/github.com-1ecc6299db9ec823/cmake-0.1.48/src/lib.rs:975:5
note: run with RUST_BACKTRACE=1 environment variable to display a backtrace
warning: build failed, waiting for other jobs to finish...
error: build failed

stereokit 0.20 is about 2yrs old on crates.io. maybe bump it will solve the issue?

can you reproduce this bug if you build https://github.com/MalekiRe/stereokit-rs directly? if so, please put the issue there

commented

stereokit-rs builds just fine on its own.

commented

I think my rust version is just too old, upgrading that gets me further, also pulled latest from main. but there's still issues with stereokit"

Compiling stereokit-sys v1.0.4
Compiling stereokit v0.2.0
Compiling stardust-xr-server v0.10.0 (/home/lkong/workspace/rice/stardust-xr-server)
error[E0432]: unresolved imports stereokit::text, stereokit::text
--> src/nodes/drawable/text.rs:24:2
|
24 | text::{self, TextAlign, TextFit, TextStyle},
| ^^^^ ^^^^ no text in the root
| |
| could not find text in stereokit

warning: unused import: convert::TryFrom
--> src/nodes/drawable/text.rs:20:11
|
20 | use std::{convert::TryFrom, path::PathBuf, sync::Arc};
| ^^^^^^^^^^^^^^^^
|
= note: #[warn(unused_imports)] on by default

error[E0599]: the method get exists for struct lazy_static::lazy::Lazy<Registry<core::client::Client>>, but its trait bounds were not satisfied
--> src/core/client.rs:17:1
|
17 | / lazy_static! {
18 | | pub static ref CLIENTS: Registry = Registry::new();
19 | | pub static ref INTERNAL_CLIENT: Arc = CLIENTS.add(Client {
20 | | event_loop: Weak::new(),
... |
30 | | });
31 | | }
| |_^ method cannot be called on lazy_static::lazy::Lazy<Registry<core::client::Client>> due to unsatisfied trait bounds
|
::: src/core/registry.rs:10:1
|
10 | pub struct Registry<T: Send + Sync + ?Sized>(Lazy<Mutex<FxHashMap<usize, Weak>>>);
| -------------------------------------------- doesn't satisfy Registry<core::client::Client>: Sync
|
= note: the following trait bounds were not satisfied:
Registry<core::client::Client>: Sync
note: the following trait must be implemented
= note: this error originates in the macro __lazy_static_internal which comes from the expansion of the macro lazy_static (in Nightly builds, run with -Z macro-backtrace for more info)

error[E0599]: the method add exists for struct CLIENTS, but its trait bounds were not satisfied
--> src/core/client.rs:19:56
|
17 | / lazy_static! {
18 | | pub static ref CLIENTS: Registry = Registry::new();
19 | | pub static ref INTERNAL_CLIENT: Arc = CLIENTS.add(Client {
| | ^^^ method cannot be called on CLIENTS due to unsatisfied trait bounds
20 | | event_loop: Weak::new(),
... |
30 | | });
31 | | }
| |_- method add not found for this struct
32 |
33 | pub struct Client {
| -----------------
| |
| doesn't satisfy core::client::Client: Sync
| doesn't satisfy core::client::Client: std::marker::Send
|
= note: the following trait bounds were not satisfied:
core::client::Client: std::marker::Send
core::client::Client: Sync
note: the following traits must be implemented

error[E0599]: the method get exists for struct lazy_static::lazy::Lazy<Arc<core::client::Client>>, but its trait bounds were not satisfied
--> src/core/client.rs:17:1
|
17 | / lazy_static! {
18 | | pub static ref CLIENTS: Registry = Registry::new();
19 | | pub static ref INTERNAL_CLIENT: Arc = CLIENTS.add(Client {
20 | | event_loop: Weak::new(),
... |
30 | | });
31 | | }
| |_^ method cannot be called on lazy_static::lazy::Lazy<Arc<core::client::Client>> due to unsatisfied trait bounds
|
= note: the following trait bounds were not satisfied:
Arc<core::client::Client>: Sync
= note: this error originates in the macro __lazy_static_internal which comes from the expansion of the macro lazy_static (in Nightly builds, run with -Z macro-backtrace for more info)

error[E0599]: the method add exists for struct CLIENTS, but its trait bounds were not satisfied
--> src/core/client.rs:51:24
|
17 | / lazy_static! {
18 | | pub static ref CLIENTS: Registry = Registry::new();
19 | | pub static ref INTERNAL_CLIENT: Arc = CLIENTS.add(Client {
20 | | event_loop: Weak::new(),
... |
30 | | });
31 | | }
| |_- method add not found for this struct
32 |
33 | pub struct Client {
| -----------------
| |
| doesn't satisfy core::client::Client: Sync
| doesn't satisfy core::client::Client: std::marker::Send
...
51 | let client = CLIENTS.add(Client {
| ^^^ method cannot be called on CLIENTS due to unsatisfied trait bounds
|
= note: the following trait bounds were not satisfied:
core::client::Client: std::marker::Send
core::client::Client: Sync
note: the following traits must be implemented

error[E0599]: the method remove exists for struct CLIENTS, but its trait bounds were not satisfied
--> src/core/client.rs:126:11
|
17 | / lazy_static! {
18 | | pub static ref CLIENTS: Registry = Registry::new();
19 | | pub static ref INTERNAL_CLIENT: Arc = CLIENTS.add(Client {
20 | | event_loop: Weak::new(),
... |
30 | | });
31 | | }
| |_- method remove not found for this struct
32 |
33 | pub struct Client {
| -----------------
| |
| doesn't satisfy core::client::Client: Sync
| doesn't satisfy core::client::Client: std::marker::Send
...
126 | CLIENTS.remove(self);
| ^^^^^^ method cannot be called on CLIENTS due to unsatisfied trait bounds
|
= note: the following trait bounds were not satisfied:
core::client::Client: std::marker::Send
core::client::Client: Sync
note: the following traits must be implemented

error: future cannot be sent between threads safely
--> src/core/eventloop.rs:31:32
|
31 | let event_loop_join_handle = tokio::spawn({
| ^^^^^^^^^^^^ future created by async block is not Send
|
= help: within Text, the trait Sync is not implemented for *mut once_cell::imp::Waiter
note: captured value is not Send
--> src/core/eventloop.rs:33:47
|
33 | async move { EventLoop::event_loop(socket, event_loop).await }
| ^^^^^^^^^^ has type Arc<eventloop::EventLoop> which is not Send
note: required by a bound in tokio::spawn
--> /home/lkong/.cargo/registry/src/github.com-1ecc6299db9ec823/tokio-1.21.1/src/task/spawn.rs:127:21
|
127 | T: Future + Send + 'static,
| ^^^^ required by this bound in tokio::spawn

error: future cannot be sent between threads safely
--> src/core/eventloop.rs:31:32
|
31 | let event_loop_join_handle = tokio::spawn({
| ^^^^^^^^^^^^ future created by async block is not Send
|
= help: within Text, the trait std::marker::Send is not implemented for *mut once_cell::imp::Waiter
note: captured value is not Send
--> src/core/eventloop.rs:33:47
|
33 | async move { EventLoop::event_loop(socket, event_loop).await }
| ^^^^^^^^^^ has type Arc<eventloop::EventLoop> which is not Send
note: required by a bound in tokio::spawn
--> /home/lkong/.cargo/registry/src/github.com-1ecc6299db9ec823/tokio-1.21.1/src/task/spawn.rs:127:21
|
127 | T: Future + Send + 'static,
| ^^^^ required by this bound in tokio::spawn

error[E0599]: the method add exists for struct Registry<Alias>, but its trait bounds were not satisfied
--> src/nodes/alias.rs:31:32
|
5 | pub struct Alias {
| ----------------
| |
| doesn't satisfy Alias: Sync
| doesn't satisfy Alias: std::marker::Send
...
31 | let alias = original.aliases.add(alias);
| ^^^ method cannot be called on Registry<Alias> due to unsatisfied trait bounds
|
::: src/core/registry.rs:10:1
|
10 | pub struct Registry<T: Send + Sync + ?Sized>(Lazy<Mutex<FxHashMap<usize, Weak>>>);
| -------------------------------------------- method add not found for this struct
|
= note: the following trait bounds were not satisfied:
Alias: std::marker::Send
Alias: Sync
note: the following traits must be implemented

error[E0599]: the method add exists for struct Registry<PulseSender>, but its trait bounds were not satisfied
--> src/nodes/data.rs:75:38
|
63 | pub struct PulseSender {
| ----------------------
| |
| doesn't satisfy PulseSender: Sync
| doesn't satisfy PulseSender: std::marker::Send
...
75 | let sender = PULSE_SENDER_REGISTRY.add(sender);
| ^^^ method cannot be called on Registry<PulseSender> due to unsatisfied trait bounds
|
::: src/core/registry.rs:10:1
|
10 | pub struct Registry<T: Send + Sync + ?Sized>(Lazy<Mutex<FxHashMap<usize, Weak>>>);
| -------------------------------------------- method add not found for this struct
|
= note: the following trait bounds were not satisfied:
PulseSender: std::marker::Send
PulseSender: Sync
note: the following traits must be implemented

error[E0599]: the method get_valid_contents exists for struct Registry<PulseReceiver>, but its trait bounds were not satisfied
--> src/nodes/data.rs:107:49
|
107 | let valid_receivers = PULSE_RECEIVER_REGISTRY.get_valid_contents();
| ^^^^^^^^^^^^^^^^^^ method cannot be called on Registry<PulseReceiver> due to unsatisfied trait bounds
...
154 | pub struct PulseReceiver {
| ------------------------
| |
| doesn't satisfy PulseReceiver: Sync
| doesn't satisfy PulseReceiver: std::marker::Send
|
::: src/core/registry.rs:10:1
|
10 | pub struct Registry<T: Send + Sync + ?Sized>(Lazy<Mutex<FxHashMap<usize, Weak>>>);
| -------------------------------------------- method get_valid_contents not found for this struct
|
= note: the following trait bounds were not satisfied:
PulseReceiver: std::marker::Send
PulseReceiver: Sync
note: the following traits must be implemented

error[E0599]: the method remove exists for struct Registry<PulseSender>, but its trait bounds were not satisfied
--> src/nodes/data.rs:150:25
|
63 | pub struct PulseSender {
| ----------------------
| |
| doesn't satisfy PulseSender: Sync
| doesn't satisfy PulseSender: std::marker::Send
...
150 | PULSE_SENDER_REGISTRY.remove(self);
| ^^^^^^ method cannot be called on Registry<PulseSender> due to unsatisfied trait bounds
|
::: src/core/registry.rs:10:1
|
10 | pub struct Registry<T: Send + Sync + ?Sized>(Lazy<Mutex<FxHashMap<usize, Weak>>>);
| -------------------------------------------- method remove not found for this struct
|
= note: the following trait bounds were not satisfied:
PulseSender: std::marker::Send
PulseSender: Sync
note: the following traits must be implemented

error[E0599]: the method add exists for struct Registry<PulseReceiver>, but its trait bounds were not satisfied
--> src/nodes/data.rs:173:42
|
154 | pub struct PulseReceiver {
| ------------------------
| |
| doesn't satisfy PulseReceiver: Sync
| doesn't satisfy PulseReceiver: std::marker::Send
...
173 | let receiver = PULSE_RECEIVER_REGISTRY.add(receiver);
| ^^^ method cannot be called on Registry<PulseReceiver> due to unsatisfied trait bounds
|
::: src/core/registry.rs:10:1
|
10 | pub struct Registry<T: Send + Sync + ?Sized>(Lazy<Mutex<FxHashMap<usize, Weak>>>);
| -------------------------------------------- method add not found for this struct
|
= note: the following trait bounds were not satisfied:
PulseReceiver: std::marker::Send
PulseReceiver: Sync
note: the following traits must be implemented

error[E0599]: the method remove exists for struct Registry<PulseReceiver>, but its trait bounds were not satisfied
--> src/nodes/data.rs:218:27
|
154 | pub struct PulseReceiver {
| ------------------------
| |
| doesn't satisfy PulseReceiver: Sync
| doesn't satisfy PulseReceiver: std::marker::Send
...
218 | PULSE_RECEIVER_REGISTRY.remove(self);
| ^^^^^^ method cannot be called on Registry<PulseReceiver> due to unsatisfied trait bounds
|
::: src/core/registry.rs:10:1
|
10 | pub struct Registry<T: Send + Sync + ?Sized>(Lazy<Mutex<FxHashMap<usize, Weak>>>);
| -------------------------------------------- method remove not found for this struct
|
= note: the following trait bounds were not satisfied:
PulseReceiver: std::marker::Send
PulseReceiver: Sync
note: the following traits must be implemented

error[E0599]: the method add exists for struct Registry<drawable::model::Model>, but its trait bounds were not satisfied
--> src/nodes/drawable/model.rs:58:34
|
30 | pub struct Model {
| ----------------
| |
| doesn't satisfy drawable::model::Model: Sync
| doesn't satisfy drawable::model::Model: std::marker::Send
...
58 | let model_arc = MODEL_REGISTRY.add(model);
| ^^^ method cannot be called on Registry<drawable::model::Model> due to unsatisfied trait bounds
|
::: src/core/registry.rs:10:1
|
10 | pub struct Registry<T: Send + Sync + ?Sized>(Lazy<Mutex<FxHashMap<usize, Weak>>>);
| -------------------------------------------- method add not found for this struct
|
= note: the following trait bounds were not satisfied:
drawable::model::Model: std::marker::Send
drawable::model::Model: Sync
note: the following traits must be implemented

error[E0599]: the method remove exists for struct Registry<drawable::model::Model>, but its trait bounds were not satisfied
--> src/nodes/drawable/model.rs:156:18
|
30 | pub struct Model {
| ----------------
| |
| doesn't satisfy drawable::model::Model: Sync
| doesn't satisfy drawable::model::Model: std::marker::Send
...
156 | MODEL_REGISTRY.remove(self);
| ^^^^^^ method cannot be called on Registry<drawable::model::Model> due to unsatisfied trait bounds
|
::: src/core/registry.rs:10:1
|
10 | pub struct Registry<T: Send + Sync + ?Sized>(Lazy<Mutex<FxHashMap<usize, Weak>>>);
| -------------------------------------------- method remove not found for this struct
|
= note: the following trait bounds were not satisfied:
drawable::model::Model: std::marker::Send
drawable::model::Model: Sync
note: the following traits must be implemented

error[E0599]: the method get_valid_contents exists for struct Registry<drawable::model::Model>, but its trait bounds were not satisfied
--> src/nodes/drawable/model.rs:161:30
|
30 | pub struct Model {
| ----------------
| |
| doesn't satisfy drawable::model::Model: Sync
| doesn't satisfy drawable::model::Model: std::marker::Send
...
161 | for model in MODEL_REGISTRY.get_valid_contents() {
| ^^^^^^^^^^^^^^^^^^ method cannot be called on Registry<drawable::model::Model> due to unsatisfied trait bounds
|
::: src/core/registry.rs:10:1
|
10 | pub struct Registry<T: Send + Sync + ?Sized>(Lazy<Mutex<FxHashMap<usize, Weak>>>);
| -------------------------------------------- method get_valid_contents not found for this struct
|
= note: the following trait bounds were not satisfied:
drawable::model::Model: std::marker::Send
drawable::model::Model: Sync
note: the following traits must be implemented

error[E0599]: the method add exists for struct Registry<Text>, but its trait bounds were not satisfied
--> src/nodes/drawable/text.rs:69:28
|
40 | pub struct Text {
| ---------------
| |
| doesn't satisfy Text: Sync
| doesn't satisfy Text: std::marker::Send
...
69 | let text = TEXT_REGISTRY.add(Text {
| ^^^ method cannot be called on Registry<Text> due to unsatisfied trait bounds
|
::: src/core/registry.rs:10:1
|
10 | pub struct Registry<T: Send + Sync + ?Sized>(Lazy<Mutex<FxHashMap<usize, Weak>>>);
| -------------------------------------------- method add not found for this struct
|
= note: the following trait bounds were not satisfied:
Text: std::marker::Send
Text: Sync
note: the following traits must be implemented

error[E0599]: the method remove exists for struct Registry<Text>, but its trait bounds were not satisfied
--> src/nodes/drawable/text.rs:167:17
|
40 | pub struct Text {
| ---------------
| |
| doesn't satisfy Text: Sync
| doesn't satisfy Text: std::marker::Send
...
167 | TEXT_REGISTRY.remove(self);
| ^^^^^^ method cannot be called on Registry<Text> due to unsatisfied trait bounds
|
::: src/core/registry.rs:10:1
|
10 | pub struct Registry<T: Send + Sync + ?Sized>(Lazy<Mutex<FxHashMap<usize, Weak>>>);
| -------------------------------------------- method remove not found for this struct
|
= note: the following trait bounds were not satisfied:
Text: std::marker::Send
Text: Sync
note: the following traits must be implemented

error[E0599]: the method get_valid_contents exists for struct Registry<Text>, but its trait bounds were not satisfied
--> src/nodes/drawable/text.rs:172:28
|
40 | pub struct Text {
| ---------------
| |
| doesn't satisfy Text: Sync
| doesn't satisfy Text: std::marker::Send
...
172 | for text in TEXT_REGISTRY.get_valid_contents() {
| ^^^^^^^^^^^^^^^^^^ method cannot be called on Registry<Text> due to unsatisfied trait bounds
|
::: src/core/registry.rs:10:1
|
10 | pub struct Registry<T: Send + Sync + ?Sized>(Lazy<Mutex<FxHashMap<usize, Weak>>>);
| -------------------------------------------- method get_valid_contents not found for this struct
|
= note: the following trait bounds were not satisfied:
Text: std::marker::Send
Text: Sync
note: the following traits must be implemented

error[E0308]: mismatched types
--> src/nodes/drawable/mod.rs:29:46
|
29 | Texture::from_cubemap_equirectangular(sk, &skytex, true, i32::MAX)
| ------------------------------------- ^^^^^^^ expected str, found struct PathBuf
| |
| arguments to this function are incorrect
|
= note: expected reference &str
found reference &PathBuf
note: associated function defined here
--> /home/lkong/.cargo/registry/src/github.com-1ecc6299db9ec823/stereokit-0.2.0/src/texture.rs:211:9
|
211 | pub fn from_cubemap_equirectangular(
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^

error[E0599]: no method named set_skytex found for mutable reference &mut StereoKit in the current scope
--> src/nodes/drawable/mod.rs:31:7
|
31 | sk.set_skytex(&skytex);
| ^^^^^^^^^^ method not found in &mut StereoKit

error[E0599]: no method named set_skylight found for mutable reference &mut StereoKit in the current scope
--> src/nodes/drawable/mod.rs:33:8
|
33 | sk.set_skylight(&skylight);
| ^^^^^^^^^^^^ method not found in &mut StereoKit

error[E0308]: mismatched types
--> src/nodes/drawable/mod.rs:40:46
|
40 | Texture::from_cubemap_equirectangular(sk, &skylight, true, i32::MAX)
| ------------------------------------- ^^^^^^^^^ expected str, found struct PathBuf
| |
| arguments to this function are incorrect
|
= note: expected reference &str
found reference &PathBuf
note: associated function defined here
--> /home/lkong/.cargo/registry/src/github.com-1ecc6299db9ec823/stereokit-0.2.0/src/texture.rs:211:9
|
211 | pub fn from_cubemap_equirectangular(
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^

error[E0599]: no method named set_skylight found for mutable reference &mut StereoKit in the current scope
--> src/nodes/drawable/mod.rs:42:7
|
42 | sk.set_skylight(&skylight);
| ^^^^^^^^^^^^ method not found in &mut StereoKit

error[E0599]: the method get exists for struct lazy_static::lazy::Lazy<Arc<Node>>, but its trait bounds were not satisfied
--> src/nodes/hmd.rs:7:1
|
7 | / lazy_static::lazy_static! {
8 | | static ref HMD: Arc = create();
9 | | }
| |_^ method cannot be called on lazy_static::lazy::Lazy<Arc<Node>> due to unsatisfied trait bounds
|
= note: the following trait bounds were not satisfied:
Arc<Node>: Sync
= note: this error originates in the macro __lazy_static_internal which comes from the expansion of the macro lazy_static::lazy_static (in Nightly builds, run with -Z macro-backtrace for more info)

error[E0599]: the method add exists for struct Registry<nodes::input::InputMethod>, but its trait bounds were not satisfied
--> src/nodes/input/mod.rs:68:25
|
52 | pub struct InputMethod {
| ----------------------
| |
| doesn't satisfy nodes::input::InputMethod: Sync
| doesn't satisfy nodes::input::InputMethod: std::marker::Send
...
68 | INPUT_METHOD_REGISTRY.add(method)
| ^^^ method cannot be called on Registry<nodes::input::InputMethod> due to unsatisfied trait bounds
|
::: src/core/registry.rs:10:1
|
10 | pub struct Registry<T: Send + Sync + ?Sized>(Lazy<Mutex<FxHashMap<usize, Weak>>>);
| -------------------------------------------- method add not found for this struct
|
= note: the following trait bounds were not satisfied:
nodes::input::InputMethod: std::marker::Send
nodes::input::InputMethod: Sync
note: the following traits must be implemented

error[E0599]: the method add exists for struct Registry<nodes::input::InputMethod>, but its trait bounds were not satisfied
--> src/nodes/input/mod.rs:84:38
|
52 | pub struct InputMethod {
| ----------------------
| |
| doesn't satisfy nodes::input::InputMethod: Sync
| doesn't satisfy nodes::input::InputMethod: std::marker::Send
...
84 | let method = INPUT_METHOD_REGISTRY.add(method);
| ^^^ method cannot be called on Registry<nodes::input::InputMethod> due to unsatisfied trait bounds
|
::: src/core/registry.rs:10:1
|
10 | pub struct Registry<T: Send + Sync + ?Sized>(Lazy<Mutex<FxHashMap<usize, Weak>>>);
| -------------------------------------------- method add not found for this struct
|
= note: the following trait bounds were not satisfied:
nodes::input::InputMethod: std::marker::Send
nodes::input::InputMethod: Sync
note: the following traits must be implemented

error[E0599]: the method remove exists for struct Registry<nodes::input::InputMethod>, but its trait bounds were not satisfied
--> src/nodes/input/mod.rs:97:25
|
52 | pub struct InputMethod {
| ----------------------
| |
| doesn't satisfy nodes::input::InputMethod: Sync
| doesn't satisfy nodes::input::InputMethod: std::marker::Send
...
97 | INPUT_METHOD_REGISTRY.remove(self);
| ^^^^^^ method cannot be called on Registry<nodes::input::InputMethod> due to unsatisfied trait bounds
|
::: src/core/registry.rs:10:1
|
10 | pub struct Registry<T: Send + Sync + ?Sized>(Lazy<Mutex<FxHashMap<usize, Weak>>>);
| -------------------------------------------- method remove not found for this struct
|
= note: the following trait bounds were not satisfied:
nodes::input::InputMethod: std::marker::Send
nodes::input::InputMethod: Sync
note: the following traits must be implemented

error[E0599]: the method add exists for struct Registry<InputHandler>, but its trait bounds were not satisfied
--> src/nodes/input/mod.rs:164:40
|
147 | pub struct InputHandler {
| -----------------------
| |
| doesn't satisfy InputHandler: Sync
| doesn't satisfy InputHandler: std::marker::Send
...
164 | let handler = INPUT_HANDLER_REGISTRY.add(handler);
| ^^^ method cannot be called on Registry<InputHandler> due to unsatisfied trait bounds
|
::: src/core/registry.rs:10:1
|
10 | pub struct Registry<T: Send + Sync + ?Sized>(Lazy<Mutex<FxHashMap<usize, Weak>>>);
| -------------------------------------------- method add not found for this struct
|
= note: the following trait bounds were not satisfied:
InputHandler: std::marker::Send
InputHandler: Sync
note: the following traits must be implemented

error[E0599]: the method add_raw exists for struct Registry<InputHandler>, but its trait bounds were not satisfied
--> src/nodes/input/mod.rs:186:25
|
147 | pub struct InputHandler {
| -----------------------
| |
| doesn't satisfy InputHandler: Sync
| doesn't satisfy InputHandler: std::marker::Send
...
186 | method.captures.add_raw(&handler);
| ^^^^^^^ method cannot be called on Registry<InputHandler> due to unsatisfied trait bounds
|
::: src/core/registry.rs:10:1
|
10 | pub struct Registry<T: Send + Sync + ?Sized>(Lazy<Mutex<FxHashMap<usize, Weak>>>);
| -------------------------------------------- method add_raw not found for this struct
|
= note: the following trait bounds were not satisfied:
InputHandler: std::marker::Send
InputHandler: Sync
note: the following traits must be implemented

error[E0599]: the method remove exists for struct Registry<InputHandler>, but its trait bounds were not satisfied
--> src/nodes/input/mod.rs:197:26
|
147 | pub struct InputHandler {
| -----------------------
| |
| doesn't satisfy InputHandler: Sync
| doesn't satisfy InputHandler: std::marker::Send
...
197 | INPUT_HANDLER_REGISTRY.remove(self);
| ^^^^^^ method cannot be called on Registry<InputHandler> due to unsatisfied trait bounds
|
::: src/core/registry.rs:10:1
|
10 | pub struct Registry<T: Send + Sync + ?Sized>(Lazy<Mutex<FxHashMap<usize, Weak>>>);
| -------------------------------------------- method remove not found for this struct
|
= note: the following trait bounds were not satisfied:
InputHandler: std::marker::Send
InputHandler: Sync
note: the following traits must be implemented

error[E0599]: the method get_valid_contents exists for struct Registry<nodes::input::InputMethod>, but its trait bounds were not satisfied
--> src/nodes/input/mod.rs:239:4
|
52 | pub struct InputMethod {
| ----------------------
| |
| doesn't satisfy nodes::input::InputMethod: Sync
| doesn't satisfy nodes::input::InputMethod: std::marker::Send
...
239 | .get_valid_contents()
| ^^^^^^^^^^^^^^^^^^ method cannot be called on Registry<nodes::input::InputMethod> due to unsatisfied trait bounds
|
::: src/core/registry.rs:10:1
|
10 | pub struct Registry<T: Send + Sync + ?Sized>(Lazy<Mutex<FxHashMap<usize, Weak>>>);
| -------------------------------------------- method get_valid_contents not found for this struct
|
= note: the following trait bounds were not satisfied:
nodes::input::InputMethod: std::marker::Send
nodes::input::InputMethod: Sync
note: the following traits must be implemented

error[E0599]: the method get_valid_contents exists for struct Registry<InputHandler>, but its trait bounds were not satisfied
--> src/nodes/input/mod.rs:244:5
|
147 | pub struct InputHandler {
| -----------------------
| |
| doesn't satisfy InputHandler: Sync
| doesn't satisfy InputHandler: std::marker::Send
...
244 | .get_valid_contents()
| ^^^^^^^^^^^^^^^^^^ method cannot be called on Registry<InputHandler> due to unsatisfied trait bounds
|
::: src/core/registry.rs:10:1
|
10 | pub struct Registry<T: Send + Sync + ?Sized>(Lazy<Mutex<FxHashMap<usize, Weak>>>);
| -------------------------------------------- method get_valid_contents not found for this struct
|
= note: the following trait bounds were not satisfied:
InputHandler: std::marker::Send
InputHandler: Sync
note: the following traits must be implemented

error[E0599]: the method get exists for struct lazy_static::lazy::Lazy<TypeInfo>, but its trait bounds were not satisfied
--> src/nodes/items/mod.rs:20:1
|
20 | / lazy_static! {
21 | | static ref ITEM_ALIAS_LOCAL_SIGNALS: Vec<&'static str> = vec![
22 | | "getTransform",
23 | | "setTransform",
... |
41 | | };
42 | | }
| |_^ method cannot be called on lazy_static::lazy::Lazy<TypeInfo> due to unsatisfied trait bounds
...
64 | pub struct TypeInfo {
| ------------------- doesn't satisfy TypeInfo: Sync
|
= note: the following trait bounds were not satisfied:
TypeInfo: Sync
note: the following trait must be implemented
= note: this error originates in the macro __lazy_static_internal which comes from the expansion of the macro lazy_static (in Nightly builds, run with -Z macro-backtrace for more info)

error[E0599]: the method add exists for struct Registry<Item>, but its trait bounds were not satisfied
--> src/nodes/items/mod.rs:112:30
|
91 | pub struct Item {
| ---------------
| |
| doesn't satisfy Item: Sync
| doesn't satisfy Item: std::marker::Send
...
112 | let item = type_info.items.add(item);
| ^^^ method cannot be called on Registry<Item> due to unsatisfied trait bounds
|
::: src/core/registry.rs:10:1
|
10 | pub struct Registry<T: Send + Sync + ?Sized>(Lazy<Mutex<FxHashMap<usize, Weak>>>);
| -------------------------------------------- method add not found for this struct
|
= note: the following trait bounds were not satisfied:
Item: std::marker::Send
Item: Sync
note: the following traits must be implemented

error[E0599]: no method named clone found for struct Item in the current scope
--> src/nodes/items/mod.rs:116:30
|
91 | pub struct Item {
| --------------- method clone not found for this struct
...
116 | let _ = node.item.set(item.clone());
| ^^^^^ method not found in Item
|
= help: items from traits can only be used if the trait is implemented and in scope
= note: the following trait defines an item clone, perhaps you need to implement it:
candidate #1: Clone
help: one of the expressions' fields has a method of the same name
|
116 | let _ = node.item.set(item.type_info.clone());
| ++++++++++

error[E0308]: mismatched types
--> src/nodes/items/mod.rs:117:3
|
103 | ) -> Arc {
| --------- expected Arc<Item> because of return type
...
117 | item
| ^^^^ expected struct Arc, found struct Item
|
= note: expected struct Arc<Item>
found struct Item

error[E0599]: the method remove exists for struct Registry<Item>, but its trait bounds were not satisfied
--> src/nodes/items/mod.rs:150:24
|
91 | pub struct Item {
| ---------------
| |
| doesn't satisfy Item: Sync
| doesn't satisfy Item: std::marker::Send
...
150 | self.type_info.items.remove(self);
| ^^^^^^ method cannot be called on Registry<Item> due to unsatisfied trait bounds
|
::: src/core/registry.rs:10:1
|
10 | pub struct Registry<T: Send + Sync + ?Sized>(Lazy<Mutex<FxHashMap<usize, Weak>>>);
| -------------------------------------------- method remove not found for this struct
|
= note: the following trait bounds were not satisfied:
Item: std::marker::Send
Item: Sync
note: the following traits must be implemented

error[E0599]: the method get_valid_contents exists for struct Registry<Item>, but its trait bounds were not satisfied
--> src/nodes/items/mod.rs:196:31
|
91 | pub struct Item {
| ---------------
| |
| doesn't satisfy Item: Sync
| doesn't satisfy Item: std::marker::Send
...
196 | for item in type_info.items.get_valid_contents() {
| ^^^^^^^^^^^^^^^^^^ method cannot be called on Registry<Item> due to unsatisfied trait bounds
|
::: src/core/registry.rs:10:1
|
10 | pub struct Registry<T: Send + Sync + ?Sized>(Lazy<Mutex<FxHashMap<usize, Weak>>>);
| -------------------------------------------- method get_valid_contents not found for this struct
|
= note: the following trait bounds were not satisfied:
Item: std::marker::Send
Item: Sync
note: the following traits must be implemented

error[E0599]: the method add exists for struct Registry<ItemAcceptor>, but its trait bounds were not satisfied
--> src/nodes/items/mod.rs:260:38
|
252 | pub struct ItemAcceptor {
| -----------------------
| |
| doesn't satisfy ItemAcceptor: Sync
| doesn't satisfy ItemAcceptor: std::marker::Send
...
260 | let acceptor = type_info.acceptors.add(ItemAcceptor {
| ^^^ method cannot be called on Registry<ItemAcceptor> due to unsatisfied trait bounds
|
::: src/core/registry.rs:10:1
|
10 | pub struct Registry<T: Send + Sync + ?Sized>(Lazy<Mutex<FxHashMap<usize, Weak>>>);
| -------------------------------------------- method add not found for this struct
|
= note: the following trait bounds were not satisfied:
ItemAcceptor: std::marker::Send
ItemAcceptor: Sync
note: the following traits must be implemented

error[E0308]: mismatched types
--> src/nodes/items/mod.rs:269:34
|
269 | let _ = node.item_acceptor.set(acceptor);
| --- ^^^^^^^^ expected struct Arc, found struct ItemAcceptor
| |
| arguments to this function are incorrect
|
= note: expected struct Arc<ItemAcceptor>
found struct ItemAcceptor
note: associated function defined here
--> /home/lkong/.cargo/registry/src/github.com-1ecc6299db9ec823/once_cell-1.15.0/src/lib.rs:1010:16
|
1010 | pub fn set(&self, value: T) -> Result<(), T> {
| ^^^

error[E0599]: the method add_raw exists for struct Registry<Item>, but its trait bounds were not satisfied
--> src/nodes/items/mod.rs:308:17
|
91 | pub struct Item {
| ---------------
| |
| doesn't satisfy Item: Sync
| doesn't satisfy Item: std::marker::Send
...
308 | self.accepted.add_raw(item);
| ^^^^^^^ method cannot be called on Registry<Item> due to unsatisfied trait bounds
|
::: src/core/registry.rs:10:1
|
10 | pub struct Registry<T: Send + Sync + ?Sized>(Lazy<Mutex<FxHashMap<usize, Weak>>>);
| -------------------------------------------- method add_raw not found for this struct
|
= note: the following trait bounds were not satisfied:
Item: std::marker::Send
Item: Sync
note: the following traits must be implemented

error[E0599]: the method remove exists for struct Registry<Item>, but its trait bounds were not satisfied
--> src/nodes/items/mod.rs:312:17
|
91 | pub struct Item {
| ---------------
| |
| doesn't satisfy Item: Sync
| doesn't satisfy Item: std::marker::Send
...
312 | self.accepted.remove(item);
| ^^^^^^ method cannot be called on Registry<Item> due to unsatisfied trait bounds
|
::: src/core/registry.rs:10:1
|
10 | pub struct Registry<T: Send + Sync + ?Sized>(Lazy<Mutex<FxHashMap<usize, Weak>>>);
| -------------------------------------------- method remove not found for this struct
|
= note: the following trait bounds were not satisfied:
Item: std::marker::Send
Item: Sync
note: the following traits must be implemented

error[E0599]: the method remove exists for struct Registry<ItemAcceptor>, but its trait bounds were not satisfied
--> src/nodes/items/mod.rs:318:28
|
252 | pub struct ItemAcceptor {
| -----------------------
| |
| doesn't satisfy ItemAcceptor: Sync
| doesn't satisfy ItemAcceptor: std::marker::Send
...
318 | self.type_info.acceptors.remove(self);
| ^^^^^^ method cannot be called on Registry<ItemAcceptor> due to unsatisfied trait bounds
|
::: src/core/registry.rs:10:1
|
10 | pub struct Registry<T: Send + Sync + ?Sized>(Lazy<Mutex<FxHashMap<usize, Weak>>>);
| -------------------------------------------- method remove not found for this struct
|
= note: the following trait bounds were not satisfied:
ItemAcceptor: std::marker::Send
ItemAcceptor: Sync
note: the following traits must be implemented

error[E0599]: the method add exists for struct Registry<Root>, but its trait bounds were not satisfied
--> src/nodes/root.rs:28:17
|
15 | pub struct Root {
| ---------------
| |
| doesn't satisfy Root: Sync
| doesn't satisfy Root: std::marker::Send
...
28 | ROOT_REGISTRY.add(Root {
| ^^^ method cannot be called on Registry<Root> due to unsatisfied trait bounds
|
::: src/core/registry.rs:10:1
|
10 | pub struct Registry<T: Send + Sync + ?Sized>(Lazy<Mutex<FxHashMap<usize, Weak>>>);
| -------------------------------------------- method add not found for this struct
|
= note: the following trait bounds were not satisfied:
Root: std::marker::Send
Root: Sync
note: the following traits must be implemented

error[E0599]: the method get_valid_contents exists for struct Registry<Root>, but its trait bounds were not satisfied
--> src/nodes/root.rs:66:29
|
15 | pub struct Root {
| ---------------
| |
| doesn't satisfy Root: Sync
| doesn't satisfy Root: std::marker::Send
...
66 | for root in ROOT_REGISTRY.get_valid_contents() {
| ^^^^^^^^^^^^^^^^^^ method cannot be called on Registry<Root> due to unsatisfied trait bounds
|
::: src/core/registry.rs:10:1
|
10 | pub struct Registry<T: Send + Sync + ?Sized>(Lazy<Mutex<FxHashMap<usize, Weak>>>);
| -------------------------------------------- method get_valid_contents not found for this struct
|
= note: the following trait bounds were not satisfied:
Root: std::marker::Send
Root: Sync
note: the following traits must be implemented

error[E0599]: the method remove exists for struct Registry<Root>, but its trait bounds were not satisfied
--> src/nodes/root.rs:87:17
|
15 | pub struct Root {
| ---------------
| |
| doesn't satisfy Root: Sync
| doesn't satisfy Root: std::marker::Send
...
87 | ROOT_REGISTRY.remove(self);
| ^^^^^^ method cannot be called on Registry<Root> due to unsatisfied trait bounds
|
::: src/core/registry.rs:10:1
|
10 | pub struct Registry<T: Send + Sync + ?Sized>(Lazy<Mutex<FxHashMap<usize, Weak>>>);
| -------------------------------------------- method remove not found for this struct
|
= note: the following trait bounds were not satisfied:
Root: std::marker::Send
Root: Sync
note: the following traits must be implemented

error[E0599]: the method get_valid_contents exists for struct Registry<Alias>, but its trait bounds were not satisfied
--> src/nodes/mod.rs:196:5
|
196 | .get_valid_contents()
| ^^^^^^^^^^^^^^^^^^ method cannot be called on Registry<Alias> due to unsatisfied trait bounds
|
::: src/core/registry.rs:10:1
|
10 | pub struct Registry<T: Send + Sync + ?Sized>(Lazy<Mutex<FxHashMap<usize, Weak>>>);
| -------------------------------------------- method get_valid_contents not found for this struct
|
::: src/nodes/alias.rs:5:1
|
5 | pub struct Alias {
| ----------------
| |
| doesn't satisfy Alias: Sync
| doesn't satisfy Alias: std::marker::Send
|
= note: the following trait bounds were not satisfied:
Alias: std::marker::Send
Alias: Sync
note: the following traits must be implemented

error[E0599]: the method get exists for struct lazy_static::lazy::Lazy<TypeInfo>, but its trait bounds were not satisfied
--> src/wayland/panel_item.rs:32:1
|
32 | / lazy_static! {
33 | | static ref ITEM_TYPE_INFO_PANEL: TypeInfo = TypeInfo {
34 | | type_name: "panel",
35 | | aliased_local_signals: vec![
... |
54 | | };
55 | | }
| |_^ method cannot be called on lazy_static::lazy::Lazy<TypeInfo> due to unsatisfied trait bounds
|
::: src/nodes/items/mod.rs:64:1
|
64 | pub struct TypeInfo {
| ------------------- doesn't satisfy TypeInfo: Sync
|
= note: the following trait bounds were not satisfied:
TypeInfo: Sync
note: the following trait must be implemented
= note: this error originates in the macro __lazy_static_internal which comes from the expansion of the macro lazy_static (in Nightly builds, run with -Z macro-backtrace for more info)

error[E0599]: the method add exists for struct Registry<CoreSurface>, but its trait bounds were not satisfied
--> src/wayland/surface.rs:107:17
|
91 | pub struct CoreSurface {
| ----------------------
| |
| doesn't satisfy CoreSurface: Sync
| doesn't satisfy CoreSurface: std::marker::Send
...
107 | CORE_SURFACES.add(CoreSurface {
| ^^^ method cannot be called on Registry<CoreSurface> due to unsatisfied trait bounds
|
::: src/core/registry.rs:10:1
|
10 | pub struct Registry<T: Send + Sync + ?Sized>(Lazy<Mutex<FxHashMap<usize, Weak>>>);
| -------------------------------------------- method add not found for this struct
|
= note: the following trait bounds were not satisfied:
CoreSurface: std::marker::Send
CoreSurface: Sync
note: the following traits must be implemented

error[E0599]: the method remove exists for struct Registry<CoreSurface>, but its trait bounds were not satisfied
--> src/wayland/surface.rs:218:17
|
91 | pub struct CoreSurface {
| ----------------------
| |
| doesn't satisfy CoreSurface: Sync
| doesn't satisfy CoreSurface: std::marker::Send
...
218 | CORE_SURFACES.remove(self);
| ^^^^^^ method cannot be called on Registry<CoreSurface> due to unsatisfied trait bounds
|
::: src/core/registry.rs:10:1
|
10 | pub struct Registry<T: Send + Sync + ?Sized>(Lazy<Mutex<FxHashMap<usize, Weak>>>);
| -------------------------------------------- method remove not found for this struct
|
= note: the following trait bounds were not satisfied:
CoreSurface: std::marker::Send
CoreSurface: Sync
note: the following traits must be implemented

error[E0599]: the method get_valid_contents exists for struct Registry<CoreSurface>, but its trait bounds were not satisfied
--> src/wayland/mod.rs:151:37
|
151 | for core_surface in CORE_SURFACES.get_valid_contents() {
| ^^^^^^^^^^^^^^^^^^ method cannot be called on Registry<CoreSurface> due to unsatisfied trait bounds
|
::: src/core/registry.rs:10:1
|
10 | pub struct Registry<T: Send + Sync + ?Sized>(Lazy<Mutex<FxHashMap<usize, Weak>>>);
| -------------------------------------------- method get_valid_contents not found for this struct
|
::: src/wayland/surface.rs:91:1
|
91 | pub struct CoreSurface {
| ----------------------
| |
| doesn't satisfy CoreSurface: Sync
| doesn't satisfy CoreSurface: std::marker::Send
|
= note: the following trait bounds were not satisfied:
CoreSurface: std::marker::Send
CoreSurface: Sync
note: the following traits must be implemented

error[E0308]: mismatched types
--> src/main.rs:61:63
|
61 | .then(|| Texture::from_cubemap_equirectangular(&stereokit, &skytex_path, true, 100))
| ------------------------------------- ^^^^^^^^^^^^ expected str, found struct PathBuf
| |
| arguments to this function are incorrect
|
= note: expected reference &str
found reference &PathBuf
note: associated function defined here
--> /home/lkong/.cargo/registry/src/github.com-1ecc6299db9ec823/stereokit-0.2.0/src/texture.rs:211:9
|
211 | pub fn from_cubemap_equirectangular(
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^

error[E0599]: no method named set_skytex found for struct StereoKit in the current scope
--> src/main.rs:64:14
|
64 | stereokit.set_skytex(&tex);
| ^^^^^^^^^^ method not found in StereoKit

error[E0599]: no method named set_skylight found for struct StereoKit in the current scope
--> src/main.rs:65:14
|
65 | stereokit.set_skylight(&light);
| ^^^^^^^^^^^^ method not found in StereoKit

error[E0599]: no function or associated item named cubemap_from_spherical_harmonics found for struct stereokit::texture::Texture in the current scope
--> src/main.rs:66:38
|
66 | } else if let Some(tex) = Texture::cubemap_from_spherical_harmonics(
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ function or associated item not found in stereokit::texture::Texture

error[E0599]: no function or associated item named default found for struct SphericalHarmonics in the current scope
--> src/main.rs:68:25
|
68 | &SphericalHarmonics::default(),
| ^^^^^^^ function or associated item not found in SphericalHarmonics

error[E0599]: no method named set_skytex found for struct StereoKit in the current scope
--> src/main.rs:73:14
|
73 | stereokit.set_skytex(&tex);
| ^^^^^^^^^^ method not found in StereoKit

error[E0593]: closure is expected to take 1 argument, but it takes 2 arguments
--> src/main.rs:97:12
|
97 | stereokit.run(
| ^^^ expected closure that takes 1 argument
98 | |sk, draw_ctx| {
| -------------- takes 2 arguments

error[E0593]: closure is expected to take 0 arguments, but it takes 1 argument
--> src/main.rs:97:12
|
97 | stereokit.run(
| ^^^ expected closure that takes 0 arguments
...
117 | |_| {
| --- takes 1 argument

warning: unused import: Resource
--> src/wayland/mod.rs:20:75
|
20 | reexports::wayland_server::{backend::GlobalId, Display, ListeningSocket, Resource},
| ^^^^^^^^

Some errors have detailed explanations: E0308, E0432, E0593, E0599.
For more information about an error, try rustc --explain E0308.
warning: stardust-xr-server (bin "stardust-xr-server") generated 2 warnings
error: could not compile stardust-xr-server due to 61 previous errors; 2 warnings emitted

oh i forgot to publish the new stereokit version to crates.io

should be fixed now @lkong ! thanks for letting me know :D

and close the issue if it is fixed plz :3

commented

That fixed it!