powersupplyclass_darwin: enable builds against older macOS SDK

This is necessary to build on darwin using nix, as nix-darwin uses an
older macOS SDK, built from Apple's open source releases.

Signed-off-by: Peter Woodman <peter@shortbus.org>
This commit is contained in:
Peter Woodman 2022-03-23 22:35:15 -04:00
parent 9aae303a46
commit 2370cccc1f
No known key found for this signature in database
GPG key ID: E2BEB7BAA835F758

View file

@ -18,9 +18,11 @@ package collector
/*
#cgo LDFLAGS: -framework IOKit -framework CoreFoundation
#include <CoreFoundation/CFNumber.h>
#include <CoreFoundation/CFRunLoop.h>
#include <CoreFoundation/CFString.h>
#include <IOKit/ps/IOPowerSources.h>
#include <IOKit/ps/IOPSKeys.h>
#include <CoreFoundation/CFArray.h>
// values collected from IOKit Power Source APIs
// Functions documentation available at