-
-
Notifications
You must be signed in to change notification settings - Fork 622
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
More improvements for macOS and conky generally #577
Conversation
Keep BUILD_WLAN OFF by default for compatibility reasons.
There are some problems (probably null-dereference)
Conky wasn't parsing the argument of the variable as it should, thus wasn't allocating the `dev` member variable. Also fix some documentation stuff.
Using the Intel® Power Gadget API (https://software.intel.com/en-us/blogs/2012/12/13/using-the-intel-power-gadget-api-on-mac-os-x) we can now get actual Core frequency and not the constant factory one. Though, for some weird reason the API gives the same freq for all Cores, thus the |cpu| arg becomes useless.
This build option has been introduced for one particular reason: On macOS getting current core-frequency is not supported by the APIs. A solution is to install Intel's ® Power Gadget which comes with an .app, a Framework and a kernel-extension. Though, this may trouble some alot, thus introduce BUILD_IPGFREQ.
Fix frequency not printing correctly (I wasn't using the divisor) Add more guards.
We want to use CoreWLAN framework.
Also, some cleanup.
Updated default conky config to monitor Mac Networking
Let me make you a collaborator, and you can push your branch directly to this repo. |
There must be some problem with sonar, probably because I changed |
@npyl Sonar doesn't work with external pull requests. The PR must originate from a branch on this repo, so it won't pass with this PR. |
I see!! Thats great! But still, why hasn't it passed the check yet? Sonar has been going from the moment I opened the PR |
@npyl it can take 5-10 minutes. |
Hi!
This is some work on both general stuff and macOS specific stuff. 😝
General Changes
BUILD_WLAN
for all OSs (set tofalse
by default)$wireless_essid
(also affected Linux, probably other OS, too!) crashing conky when noarg
was passed. Correct behaviour would be to allocatedev
with default interface (e.g.eth0
). Addingparse_net_stat_arg
fixes the problem.$downspeed
and$upspeed
fromconky.conf
andconky_no_x11.conf
; we want conky to always use theDEFAULTNETDEV
which is set during configuration with cmake and my vary from OS to OS. This is part of 147499f.macOS Changes
$if_up
by removing theSOCK_CLOEXEC
flag fromsocket()
innet_stats.cc
when building for macOS; for some reason the function fails with error 43:Protocol not supported
. This may also affect linux but I haven't checked yet.get_freq()
using the Intel Power Gadget API ifBUILD_IPGFREQ
is enabled.BUILD_IPGFREQ
(set tofalse
by default) so that the user can choose whether to use IPG or stick with old behaviour (Print constant factory frequency of CPU).IPG (Intel Power Gadget concerns)
Intel Power Gadget can be installed using Homebrew-cask and it installs a .app, a Framework and a kernel-extension. This will seem a bit troublesome in my opinion for many users thus the
BUILD_IPGFREQ
option.Now, one has the option to either use a better
$freq
or avoid the hussle of installing a library/kernel extension (with sacrifices).NOTE: IPG doesn't seem to support multiple cores although stating the opposite in the documentation thus, all readings are for core0.
More Concerns
I am not sure if using Objective-C++ in
darwin.mm
will be a problem for sonar but if there is a problem I will work it out.Epilogue
This is a prequel; actual support for WLAN on macOS is coming soon!