Skip to content
This repository has been archived by the owner on Aug 29, 2020. It is now read-only.

I want install ytop on windows , but more wrongs... #105

Open
Dongshan-git opened this issue Jul 28, 2020 · 2 comments
Open

I want install ytop on windows , but more wrongs... #105

Dongshan-git opened this issue Jul 28, 2020 · 2 comments

Comments

@Dongshan-git
Copy link

Compiling psutil v3.1.0
error[E0433]: failed to resolve: could not find sys in nix
--> C:\Users\dscod.cargo\registry\src\github.com-1ecc6299db9ec823\psutil-3.1.0\src\process\process.rs:7:10
|
7 | use nix::sys::signal::{kill, Signal};
| ^^^ could not find sys in nix

error[E0433]: failed to resolve: could not find sys in nix
--> C:\Users\dscod.cargo\registry\src\github.com-1ecc6299db9ec823\psutil-3.1.0\src\process\mod.rs:12:14
|
12 | pub use nix::sys::signal::Signal;
| ^^^ could not find sys in nix

error[E0432]: unresolved import nix::unistd
--> C:\Users\dscod.cargo\registry\src\github.com-1ecc6299db9ec823\psutil-3.1.0\src\process\process.rs:8:5
|
8 | use nix::unistd;
| ^^^^^^^^^^^ no unistd in the root

error[E0432]: unresolved import crate::cpu::cpu_times_percpu
--> C:\Users\dscod.cargo\registry\src\github.com-1ecc6299db9ec823\psutil-3.1.0\src\cpu\cpu_times_percent.rs:3:29
|
3 | use crate::cpu::{cpu_times, cpu_times_percpu, CpuTimes};
| ^^^^^^^^^^^^^^^^
| |
| no cpu_times_percpu in cpu
| help: a similar name exists in the module: cpu_times_percent

error[E0432]: unresolved import crate::disk::disk_io_counters_per_partition
--> C:\Users\dscod.cargo\registry\src\github.com-1ecc6299db9ec823\psutil-3.1.0\src\disk\disk_io_counters.rs:6:5
|
6 | use crate::disk::disk_io_counters_per_partition;
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ no disk_io_counters_per_partition in disk

error[E0432]: unresolved import crate::disk::partitions
--> C:\Users\dscod.cargo\registry\src\github.com-1ecc6299db9ec823\psutil-3.1.0\src\disk\partition.rs:3:19
|
3 | use crate::disk::{partitions, FileSystem};
| ^^^^^^^^^^
| |
| no partitions in disk
| help: a similar name exists in the module: partition

error[E0432]: unresolved import crate::network::net_io_counters_pernic
--> C:\Users\dscod.cargo\registry\src\github.com-1ecc6299db9ec823\psutil-3.1.0\src\network\net_io_couters.rs:5:5
|
5 | use crate::network::net_io_counters_pernic;
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ no net_io_counters_pernic in network

error[E0412]: cannot find type Error in crate nix
--> C:\Users\dscod.cargo\registry\src\github.com-1ecc6299db9ec823\psutil-3.1.0\src\errors.rs:57:26
|
57 | NixError { source: nix::Error },
| ^^^^^ not found in nix
|
help: consider importing one of these items
|
1 | use core::fmt::Error;
|
1 | use crate::errors::Error;
|
1 | use platforms::Error;
|
1 | use snafu::Error;
|
and 5 other candidates

error[E0412]: cannot find type Error in crate nix
--> C:\Users\dscod.cargo\registry\src\github.com-1ecc6299db9ec823\psutil-3.1.0\src\errors.rs:64:16
|
64 | impl Fromnix::Error for Error {
| ^^^^^ not found in nix
|
help: consider importing one of these items
|
1 | use core::fmt::Error;
|
1 | use crate::errors::Error;
|
1 | use platforms::Error;
|
1 | use snafu::Error;
|
and 5 other candidates

error[E0412]: cannot find type Error in crate nix
--> C:\Users\dscod.cargo\registry\src\github.com-1ecc6299db9ec823\psutil-3.1.0\src\errors.rs:65:22
|
65 | fn from(error: nix::Error) -> Self {
| ^^^^^ not found in nix
|
help: consider importing one of these items
|
1 | use core::fmt::Error;
|
1 | use crate::errors::Error;
|
1 | use platforms::Error;
|
1 | use snafu::Error;
|
and 5 other candidates

error[E0423]: expected function, found module cpu_times
--> C:\Users\dscod.cargo\registry\src\github.com-1ecc6299db9ec823\psutil-3.1.0\src\cpu\cpu_times_percent.rs:144:19
|
144 | let cpu_times = cpu_times()?;
| ^^^^^^^^^ a field by this name exists in Self

error[E0423]: expected function, found module cpu_times
--> C:\Users\dscod.cargo\registry\src\github.com-1ecc6299db9ec823\psutil-3.1.0\src\cpu\cpu_times_percent.rs:156:27
|
156 | let current_cpu_times = cpu_times()?;
| ^^^^^^^^^ help: you might have meant to use the available field: self.cpu_times

error[E0425]: cannot find function processes in module process
--> C:\Users\dscod.cargo\registry\src\github.com-1ecc6299db9ec823\psutil-3.1.0\src\process\collector.rs:16:28
|
16 | let processes = process::processes()?
| ^^^^^^^^^ not found in process

error[E0423]: expected function, found module memory::virtual_memory
--> C:\Users\dscod.cargo\registry\src\github.com-1ecc6299db9ec823\psutil-3.1.0\src\process\process.rs:163:4
|
163 | memory::virtual_memory().map_err(|e| psutil_error_to_process_error(e, self.pid))?;
| ^^^^^^^^^^^^^^^^^^^^^^ not a function

error[E0412]: cannot find type Signal in this scope
--> C:\Users\dscod.cargo\registry\src\github.com-1ecc6299db9ec823\psutil-3.1.0\src\process\process.rs:229:36
|
229 | pub fn send_signal(&self, signal: Signal) -> ProcessResult<()> {
| ^^^^^^ not found in this scope

error[E0603]: module virtual_memory is private
--> C:\Users\dscod.cargo\registry\src\github.com-1ecc6299db9ec823\psutil-3.1.0\src\process\process.rs:163:12
|
163 | memory::virtual_memory().map_err(|e| psutil_error_to_process_error(e, self.pid))?;
| ^^^^^^^^^^^^^^ private module
|
note: the module virtual_memory is defined here
--> C:\Users\dscod.cargo\registry\src\github.com-1ecc6299db9ec823\psutil-3.1.0\src\memory\mod.rs:4:1
|
4 | mod virtual_memory;
| ^^^^^^^^^^^^^^^^^^^

error[E0308]: mismatched types
--> C:\Users\dscod.cargo\registry\src\github.com-1ecc6299db9ec823\psutil-3.1.0\src\cpu\cpu_times_percent.rs:42:24
|
42 | pub fn idle(&self) -> Percent {
| ---- ^^^^^^^ expected f32, found ()
| |
| implicitly returns () as its body has no tail or return expression

error[E0308]: mismatched types
--> C:\Users\dscod.cargo\registry\src\github.com-1ecc6299db9ec823\psutil-3.1.0\src\cpu\cpu_times_percent.rs:54:24
|
54 | pub fn busy(&self) -> Percent {
| ---- ^^^^^^^ expected f32, found ()
| |
| implicitly returns () as its body has no tail or return expression

error[E0599]: no function or associated item named sys_new found for struct process::process::Process in the current scope
--> C:\Users\dscod.cargo\registry\src\github.com-1ecc6299db9ec823\psutil-3.1.0\src\process\process.rs:38:12
|
24 | pub struct Process {
| ------------------ function or associated item sys_new not found for this
...
38 | Process::sys_new(pid)
| ^^^^^^^ function or associated item not found in process::process::Process

error[E0599]: no method named sys_ppid found for reference &process::process::Process in the current scope
--> C:\Users\dscod.cargo\registry\src\github.com-1ecc6299db9ec823\psutil-3.1.0\src\process\process.rs:50:8
|
50 | self.sys_ppid()
| ^^^^^^^^ method not found in &process::process::Process

error[E0599]: no method named sys_name found for reference &process::process::Process in the current scope
--> C:\Users\dscod.cargo\registry\src\github.com-1ecc6299db9ec823\psutil-3.1.0\src\process\process.rs:54:8
|
54 | self.sys_name()
| ^^^^^^^^ method not found in &process::process::Process

error[E0599]: no method named sys_exe found for reference &process::process::Process in the current scope
--> C:\Users\dscod.cargo\registry\src\github.com-1ecc6299db9ec823\psutil-3.1.0\src\process\process.rs:58:8
|
58 | self.sys_exe()
| ^^^^^^^ method not found in &process::process::Process

error[E0599]: no method named sys_cmdline found for reference &process::process::Process in the current scope
--> C:\Users\dscod.cargo\registry\src\github.com-1ecc6299db9ec823\psutil-3.1.0\src\process\process.rs:64:8
|
64 | self.sys_cmdline()
| ^^^^^^^^^^^ method not found in &process::process::Process

error[E0599]: no method named sys_cmdline_vec found for reference &process::process::Process in the current scope
--> C:\Users\dscod.cargo\registry\src\github.com-1ecc6299db9ec823\psutil-3.1.0\src\process\process.rs:70:8
|
70 | self.sys_cmdline_vec()
| ^^^^^^^^^^^^^^^ help: there is an associated function with a similar name: cmdline_vec

error[E0599]: no method named sys_parents found for reference &process::process::Process in the current scope
--> C:\Users\dscod.cargo\registry\src\github.com-1ecc6299db9ec823\psutil-3.1.0\src\process\process.rs:91:8
|
91 | self.sys_parents()
| ^^^^^^^^^^^ method not found in &process::process::Process

error[E0599]: no method named sys_status found for reference &process::process::Process in the current scope
--> C:\Users\dscod.cargo\registry\src\github.com-1ecc6299db9ec823\psutil-3.1.0\src\process\process.rs:95:8
|
95 | self.sys_status()
| ^^^^^^^^^^ method not found in &process::process::Process

error[E0599]: no method named sys_cwd found for reference &process::process::Process in the current scope
--> C:\Users\dscod.cargo\registry\src\github.com-1ecc6299db9ec823\psutil-3.1.0\src\process\process.rs:99:8
|
99 | self.sys_cwd()
| ^^^^^^^ method not found in &process::process::Process

error[E0599]: no method named sys_username found for reference &process::process::Process in the current scope
--> C:\Users\dscod.cargo\registry\src\github.com-1ecc6299db9ec823\psutil-3.1.0\src\process\process.rs:103:8
|
103 | self.sys_username()
| ^^^^^^^^^^^^ help: there is an associated function with a similar name: username

error[E0599]: no method named sys_get_nice found for reference &process::process::Process in the current scope
--> C:\Users\dscod.cargo\registry\src\github.com-1ecc6299db9ec823\psutil-3.1.0\src\process\process.rs:107:8
|
107 | self.sys_get_nice()
| ^^^^^^^^^^^^ help: there is an associated function with a similar name: get_nice

error[E0599]: no method named sys_set_nice found for reference &process::process::Process in the current scope
--> C:\Users\dscod.cargo\registry\src\github.com-1ecc6299db9ec823\psutil-3.1.0\src\process\process.rs:111:8
|
111 | self.sys_set_nice(nice)
| ^^^^^^^^^^^^ help: there is an associated function with a similar name: set_nice

error[E0599]: no method named sys_num_ctx_switches found for reference &process::process::Process in the current scope
--> C:\Users\dscod.cargo\registry\src\github.com-1ecc6299db9ec823\psutil-3.1.0\src\process\process.rs:115:8
|
115 | self.sys_num_ctx_switches()
| ^^^^^^^^^^^^^^^^^^^^ help: there is an associated function with a similar name: num_ctx_switches

error[E0599]: no method named sys_num_threads found for reference &process::process::Process in the current scope
--> C:\Users\dscod.cargo\registry\src\github.com-1ecc6299db9ec823\psutil-3.1.0\src\process\process.rs:119:8
|
119 | self.sys_num_threads()
| ^^^^^^^^^^^^^^^ help: there is an associated function with a similar name: num_threads

error[E0599]: no method named sys_threads found for reference &process::process::Process in the current scope
--> C:\Users\dscod.cargo\registry\src\github.com-1ecc6299db9ec823\psutil-3.1.0\src\process\process.rs:123:8
|
123 | self.sys_threads()
| ^^^^^^^^^^^ help: there is an associated function with a similar name: num_threads

error[E0599]: no method named sys_cpu_times found for reference &process::process::Process in the current scope
--> C:\Users\dscod.cargo\registry\src\github.com-1ecc6299db9ec823\psutil-3.1.0\src\process\process.rs:127:8
|
127 | self.sys_cpu_times()
| ^^^^^^^^^^^^^ help: there is an associated function with a similar name: cpu_times

error[E0599]: no method named sys_memory_info found for reference &process::process::Process in the current scope
--> C:\Users\dscod.cargo\registry\src\github.com-1ecc6299db9ec823\psutil-3.1.0\src\process\process.rs:154:8
|
154 | self.sys_memory_info()
| ^^^^^^^^^^^^^^^ help: there is an associated function with a similar name: memory_info

error[E0599]: no method named sys_memory_full_info found for reference &process::process::Process in the current scope
--> C:\Users\dscod.cargo\registry\src\github.com-1ecc6299db9ec823\psutil-3.1.0\src\process\process.rs:158:8
|
158 | self.sys_memory_full_info()
| ^^^^^^^^^^^^^^^^^^^^ help: there is an associated function with a similar name: memory_full_info

error[E0599]: no method named sys_memory_percent_with_type found for reference &process::process::Process in the current scope
--> C:\Users\dscod.cargo\registry\src\github.com-1ecc6299db9ec823\psutil-3.1.0\src\process\process.rs:179:8
|
179 | self.sys_memory_percent_with_type(r#type)
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: there is an associated function with a similar name: memory_percent_with_type

error[E0599]: no method named sys_chidren found for reference &process::process::Process in the current scope
--> C:\Users\dscod.cargo\registry\src\github.com-1ecc6299db9ec823\psutil-3.1.0\src\process\process.rs:183:8
|
183 | self.sys_chidren()
| ^^^^^^^^^^^ method not found in &process::process::Process

error[E0599]: no method named sys_open_files found for reference &process::process::Process in the current scope
--> C:\Users\dscod.cargo\registry\src\github.com-1ecc6299db9ec823\psutil-3.1.0\src\process\process.rs:187:8
|
187 | self.sys_open_files()
| ^^^^^^^^^^^^^^ help: there is an associated function with a similar name: open_files

error[E0599]: no method named sys_connections found for reference &process::process::Process in the current scope
--> C:\Users\dscod.cargo\registry\src\github.com-1ecc6299db9ec823\psutil-3.1.0\src\process\process.rs:191:8
|
191 | self.sys_connections()
| ^^^^^^^^^^^^^^^ help: there is an associated function with a similar name: connections

error[E0599]: no method named sys_connections_with_type found for reference &process::process::Process in the current scope
--> C:\Users\dscod.cargo\registry\src\github.com-1ecc6299db9ec823\psutil-3.1.0\src\process\process.rs:195:8
|
195 | self.sys_connections_with_type(r#type)
| ^^^^^^^^^^^^^^^^^^^^^^^^^ help: there is an associated function with a similar name: connections_with_type

error[E0599]: no method named sys_wait found for reference &process::process::Process in the current scope
--> C:\Users\dscod.cargo\registry\src\github.com-1ecc6299db9ec823\psutil-3.1.0\src\process\process.rs:293:8
|
293 | self.sys_wait()
| ^^^^^^^^ method not found in &process::process::Process

error: aborting due to 42 previous errors

Some errors have detailed explanations: E0308, E0412, E0423, E0425, E0432, E0433, E0599, E0603.
For more information about an error, try rustc --explain E0308.
error: could not compile psutil.

To learn more, run the command again with --verbose.
warning: build failed, waiting for other jobs to finish...
error: build failed

@Dongshan-git
Copy link
Author

How to install this on windows???

@CosmicHorrorDev
Copy link

Windows currently isn't supported, but the README did list that support for all major platforms is planned.

Check #74 since this issue is a duplicate of that.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants