Fix various build issues.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69
diff --git a/configure.ac b/configure.ac
index ff14d3e..eee1f3f 100644
--- a/configure.ac
+++ b/configure.ac
@@ -112,6 +112,8 @@ if test "x$ATISTREAMSDKROOT" != x; then
OPENCL_LIBS="-L$ATISTREAMSDKROOT/lib/$ATI_STREAM_ARCH_DIR $OPENCL_LIBS"
fi
+cpumining="no"
+
AC_ARG_ENABLE([cpumining],
[AC_HELP_STRING([--enable-cpumining],[Build with cpu mining support(default disabled)])],
[cpumining=$enableval]
@@ -121,6 +123,8 @@ if test "x$cpumining" = xyes; then
fi
AM_CONDITIONAL([HAS_CPUMINE], [test x$cpumining = xyes])
+opencl="yes"
+
AC_ARG_ENABLE([opencl],
[AC_HELP_STRING([--disable-opencl],[Override detection and disable building with opencl])],
[opencl=$enableval]
@@ -181,6 +185,8 @@ else
DLOPEN_FLAGS=""
fi
+bitforce="no"
+
AC_ARG_ENABLE([bitforce],
[AC_HELP_STRING([--enable-bitforce],[Compile support for BitForce FPGAs(default disabled)])],
[bitforce=$enableval]
diff --git a/device-cpu.c b/device-cpu.c
index 04b8538..d1eb4eb 100644
--- a/device-cpu.c
+++ b/device-cpu.c
@@ -23,6 +23,7 @@
#include <sys/stat.h>
#include <sys/types.h>
+#include <sys/wait.h>
#ifndef WIN32
#include <sys/resource.h>
diff --git a/main.c b/main.c
index b953454..ef1872a 100644
--- a/main.c
+++ b/main.c
@@ -3896,7 +3896,7 @@ static void *api_thread(void *userdata)
return NULL;
}
-static void thread_reportin(struct thr_info *thr)
+void thread_reportin(struct thr_info *thr)
{
gettimeofday(&thr->last, NULL);
thr->cgpu->status = LIFE_WELL;
diff --git a/miner.h b/miner.h
index 8f4e035..127af49 100644
--- a/miner.h
+++ b/miner.h
@@ -526,6 +526,8 @@ struct work_restart {
char padding[128 - sizeof(unsigned long)];
};
+extern void thread_reportin(struct thr_info *thr);
+
extern void kill_work(void);
extern void reinit_device(struct cgpu_info *cgpu);