Line 0
Link Here
|
|
|
1 |
--- src/cryptonote_basic/miner.cpp.orig 2019-10-13 11:25:19 UTC |
2 |
+++ src/cryptonote_basic/miner.cpp |
3 |
@@ -61,7 +61,9 @@ |
4 |
#include <devstat.h> |
5 |
#include <errno.h> |
6 |
#include <fcntl.h> |
7 |
+#if defined(__amd64__ ) || defined(__i386__) |
8 |
#include <machine/apm_bios.h> |
9 |
+#endif |
10 |
#include <stdio.h> |
11 |
#include <sys/resource.h> |
12 |
#include <sys/sysctl.h> |
13 |
@@ -1082,6 +1084,7 @@ namespace cryptonote |
14 |
return boost::logic::tribool(boost::logic::indeterminate); |
15 |
} |
16 |
|
17 |
+#if defined(__amd64__ ) || defined(__i386__) |
18 |
apm_info info; |
19 |
if( ioctl(fd, APMIO_GETINFO, &info) == -1 ) { |
20 |
close(fd); |
21 |
@@ -1116,6 +1119,7 @@ namespace cryptonote |
22 |
<< "unexpected ac-line status (" << info.ai_acline << ") and " |
23 |
<< "battery status (" << info.ai_batt_stat << ")."); |
24 |
return boost::logic::tribool(boost::logic::indeterminate); |
25 |
+#endif |
26 |
} |
27 |
if( n != sizeof(ac) ) |
28 |
{ |