Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

macOS support #3

Open
p-e-w opened this issue Sep 30, 2018 · 5 comments
Open

macOS support #3

p-e-w opened this issue Sep 30, 2018 · 5 comments
Labels
enhancement New feature or request help wanted Extra attention is needed

Comments

@p-e-w
Copy link
Owner

p-e-w commented Sep 30, 2018

No description provided.

@p-e-w p-e-w added enhancement New feature or request help wanted Extra attention is needed labels Sep 30, 2018
@hawkins
Copy link

hawkins commented Dec 1, 2018

I’m a rust rookie but am looking to dive more into it and all of my development is on a Mac these days, so I’m interested to help out here. Could you help me understand what work at a high level needs to be done for this effort?

@p-e-w
Copy link
Owner Author

p-e-w commented Dec 8, 2018

@hawkins Thank you for your interest! There are two things that need to be done here:

  1. Allow Hegemon to build without libsensors (Allow building without libsensors #16). I am already working on this.
  2. Improve macOS support in systemstat. This is the main task. systemstat does have macOS platform code but currently, most of the functions are placeholders. Working macOS code can be found in the sysinfo crate, but keep in mind that sysinfo is MIT-licensed while systemstat aims to be public domain. I have studied both of these crates in detail and while sysinfo's cross-platform support is more mature, I found systemstat to have the better overall design, and its API to be a much better match for Hegemon's requirements.

@hawkins
Copy link

hawkins commented Dec 8, 2018

Thanks so much for the detailed response! 😄 I'll start studying the two libraries as well to see if I can help out in supporting macOS under systemstat on the assumption that we'll figure out licensing issues.

@fenollp
Copy link

fenollp commented May 28, 2019

FYI this is what a cargo install hegemon does today

error[E0609]: no field `meminfo` on type `systemstat::PlatformMemory`
  --> /Users/pete/.cargo/registry/src/github.com-1ecc6299db9ec823/hegemon-0.1.0/src/providers/memory.rs:50:50
   |
50 |             let meminfo = memory.platform_memory.meminfo;
   |                                                  ^^^^^^^ unknown field
   |
   = note: available fields are: `active`, `inactive`, `wired`, `cache`, `free`

error[E0609]: no field `meminfo` on type `systemstat::PlatformMemory`
  --> /Users/pete/.cargo/registry/src/github.com-1ecc6299db9ec823/hegemon-0.1.0/src/providers/memory.rs:57:66
   |
57 |                             let meminfo = memory.platform_memory.meminfo;
   |                                                                  ^^^^^^^ unknown field
   |
   = note: available fields are: `active`, `inactive`, `wired`, `cache`, `free`
Darwin baobao 18.6.0 Darwin Kernel Version 18.6.0: Thu Apr 25 23:16:27 PDT 2019; root:xnu-4903.261.4~2/RELEASE_X86_64 x86_64 i386 MacBookPro14,1 Darwin

@hawkins
Copy link

hawkins commented Oct 29, 2019

I wasn't able to get anywhere with this last year (obviously and unfortunately 🙁 ), but I heard about this heim library today that I thought sounded interesting for this project. Maybe it's relevant? https://github.com/heim-rs/heim/blob/master/COMPARISON.md

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request help wanted Extra attention is needed
Projects
None yet
Development

No branches or pull requests

3 participants