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

battstat applet: fix NetBSD APM support #130

Merged
merged 1 commit into from May 25, 2015
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
8 changes: 8 additions & 0 deletions battstat/power-management.c
Expand Up @@ -239,7 +239,11 @@ apm_readinfo (BatteryStatus *status)
#elif defined(__NetBSD__) || defined(__OpenBSD__)

#include <sys/param.h>
#if defined(__NetBSD__)
#include <dev/apm/apmio.h>
#else /* __OpenBSD__ */
#include <machine/apmvar.h>
#endif

#define APMDEVICE "/dev/apm"

Expand All @@ -249,7 +253,11 @@ apm_readinfo (BatteryStatus *status)
/* Code for OpenBSD by Joe Ammond <jra@twinight.org>. Using the same
procedure as for FreeBSD.
*/
#if defined(__NetBSD__)
struct apm_power_info apminfo;
#else /* __OpenBSD__ */
struct apm_info apminfo;
#endif
int fd;

#if defined(__NetBSD__)
Expand Down