Browse Source

Bugfix: Add missing includes of config.h, stdbool.h, and stdint.h

Luke Dashjr 12 years ago
parent
commit
2546c0598d
42 changed files with 93 additions and 0 deletions
  1. 3 0
      adl.c
  2. 3 0
      adl.h
  3. 2 0
      driver-avalon.c
  4. 2 0
      driver-avalon.h
  5. 2 0
      driver-bfsb.c
  6. 4 0
      driver-bigpic.c
  7. 2 0
      driver-bigpic.h
  8. 1 0
      driver-bitforce.c
  9. 2 0
      driver-bitfury.c
  10. 5 0
      driver-cairnsmore.c
  11. 2 0
      driver-erupter.c
  12. 2 0
      driver-icarus.c
  13. 2 0
      driver-metabank.c
  14. 2 0
      driver-modminer.c
  15. 1 0
      driver-nanofury.c
  16. 1 0
      driver-opencl.c
  17. 2 0
      driver-opencl.h
  18. 2 0
      driver-x6500.c
  19. 3 0
      driver-ztex.c
  20. 3 0
      dynclock.c
  21. 1 0
      findnonce.c
  22. 3 0
      findnonce.h
  23. 1 0
      fpgautils.c
  24. 2 0
      hexdump.c
  25. 3 0
      libbitfury.h
  26. 2 0
      libztex.c
  27. 3 0
      libztex.h
  28. 1 0
      logging.c
  29. 1 0
      mcp2210.h
  30. 1 0
      miner.c
  31. 2 0
      ocl.c
  32. 2 0
      scrypt.h
  33. 1 0
      sha2.c
  34. 3 0
      sha2.h
  35. 3 0
      sha256_4way.c
  36. 3 0
      sha256_altivec_4way.c
  37. 3 0
      sha256_sse2_amd64.c
  38. 3 0
      sha256_sse2_i386.c
  39. 3 0
      sha256_sse4_amd64.c
  40. 3 0
      sha256_via.c
  41. 2 0
      util.c
  42. 1 0
      util.h

+ 3 - 0
adl.c

@@ -17,9 +17,12 @@
 #include <math.h>
 
 #ifdef HAVE_CURSES
+// Must be before stdbool, since pdcurses typedefs bool :/
 #include <curses.h>
 #endif
 
+#include <stdbool.h>
+
 #include "miner.h"
 #include "ADL/adl_sdk.h"
 #include "compat.h"

+ 3 - 0
adl.h

@@ -1,6 +1,9 @@
 #ifndef __ADL_H__
 #define __ADL_H__
 #ifdef HAVE_ADL
+
+#include <stdbool.h>
+
 bool adl_active;
 bool opt_reorder;
 const int opt_targettemp;

+ 2 - 0
driver-avalon.c

@@ -14,6 +14,8 @@
 
 #include <limits.h>
 #include <pthread.h>
+#include <stdbool.h>
+#include <stdint.h>
 #include <stdio.h>
 #include <sys/time.h>
 #include <sys/types.h>

+ 2 - 0
driver-avalon.h

@@ -13,6 +13,8 @@
 
 #ifdef USE_AVALON
 
+#include <stdint.h>
+
 #define AVALON_TIME_FACTOR 10
 #define AVALON_RESET_FAULT_DECISECONDS 1
 #define AVALON_MINER_THREADS 1

+ 2 - 0
driver-bfsb.c

@@ -24,6 +24,8 @@
 
 #include "config.h"
 
+#include <stdbool.h>
+
 #include "deviceapi.h"
 #include "libbitfury.h"
 #include "spidevc.h"

+ 4 - 0
driver-bigpic.c

@@ -13,6 +13,10 @@
  */
 
 #include "config.h"
+
+#include <stdbool.h>
+#include <stdint.h>
+
 #include "miner.h"
 #include "fpgautils.h"
 #include "logging.h"

+ 2 - 0
driver-bigpic.h

@@ -1,6 +1,8 @@
 #ifndef BFG_DRIVER_BIGPIC_H
 #define BFG_DRIVER_BIGPIC_H
 
+#include <stdint.h>
+
 #define BPM_BAUD	115200
 
 struct bigpic_identity

+ 1 - 0
driver-bitforce.c

@@ -13,6 +13,7 @@
 #include <ctype.h>
 #include <limits.h>
 #include <pthread.h>
+#include <stdbool.h>
 #include <stdint.h>
 #include <stdio.h>
 #include <strings.h>

+ 2 - 0
driver-bitfury.c

@@ -27,6 +27,8 @@
 #include <limits.h>
 #include "miner.h"
 #include <unistd.h>
+#include <stdbool.h>
+#include <stdint.h>
 #include <sha2.h>
 
 #include "deviceapi.h"

+ 5 - 0
driver-cairnsmore.c

@@ -7,6 +7,11 @@
  * any later version.  See COPYING for more details.
  */
 
+#include "config.h"
+
+#include <stdbool.h>
+#include <stdint.h>
+
 #include "compat.h"
 #include "dynclock.h"
 #include "fpgautils.h"

+ 2 - 0
driver-erupter.c

@@ -9,6 +9,8 @@
 
 #include "config.h"
 
+#include <stdbool.h>
+
 #include "miner.h"
 #include "fpgautils.h"
 #include "icarus-common.h"

+ 2 - 0
driver-icarus.c

@@ -38,6 +38,8 @@
 
 #include <limits.h>
 #include <pthread.h>
+#include <stdbool.h>
+#include <stdint.h>
 #include <stdio.h>
 #include <sys/time.h>
 #include <sys/types.h>

+ 2 - 0
driver-metabank.c

@@ -24,6 +24,8 @@
 
 #include "config.h"
 
+#include <stdbool.h>
+
 #include "deviceapi.h"
 #include "driver-bitfury.h"
 #include "libbitfury.h"

+ 2 - 0
driver-modminer.c

@@ -12,6 +12,8 @@
 
 #include <limits.h>
 #include <stdarg.h>
+#include <stdbool.h>
+#include <stdint.h>
 #include <stdio.h>
 #include <unistd.h>
 

+ 1 - 0
driver-nanofury.c

@@ -11,6 +11,7 @@
 #include "config.h"
 
 #include <stdbool.h>
+#include <stdint.h>
 
 #include "deviceapi.h"
 #include "driver-bitfury.h"

+ 1 - 0
driver-opencl.c

@@ -16,6 +16,7 @@
 #endif
 
 #ifdef HAVE_CURSES
+// Must be before stdbool, since pdcurses typedefs bool :/
 #include <curses.h>
 #endif
 

+ 2 - 0
driver-opencl.h

@@ -1,6 +1,8 @@
 #ifndef __DEVICE_GPU_H__
 #define __DEVICE_GPU_H__
 
+#include <stdbool.h>
+
 #include "miner.h"
 
 

+ 2 - 0
driver-x6500.c

@@ -16,6 +16,8 @@
 
 #include <limits.h>
 #include <math.h>
+#include <stdbool.h>
+#include <stdint.h>
 #include <sys/time.h>
 
 #include <libusb.h>

+ 3 - 0
driver-ztex.c

@@ -16,6 +16,9 @@
 
 #include "config.h"
 
+#include <stdbool.h>
+#include <stdint.h>
+
 #include "miner.h"
 #include <unistd.h>
 #include <sha2.h>

+ 3 - 0
dynclock.c

@@ -10,6 +10,9 @@
 
 #include "config.h"
 
+#include <stdbool.h>
+#include <stdint.h>
+
 #include "dynclock.h"
 #include "miner.h"
 

+ 1 - 0
findnonce.c

@@ -12,6 +12,7 @@
 #include "config.h"
 #ifdef HAVE_OPENCL
 
+#include <stdint.h>
 #include <stdio.h>
 #include <inttypes.h>
 #include <pthread.h>

+ 3 - 0
findnonce.h

@@ -1,5 +1,8 @@
 #ifndef __FINDNONCE_H__
 #define __FINDNONCE_H__
+
+#include <stdint.h>
+
 #include "miner.h"
 #include "config.h"
 

+ 1 - 0
fpgautils.c

@@ -18,6 +18,7 @@
 
 #include <ctype.h>
 #include <stdarg.h>
+#include <stdbool.h>
 #include <stdint.h>
 #include <stdlib.h>
 #include <sys/types.h>

+ 2 - 0
hexdump.c

@@ -19,6 +19,8 @@
  * along with this program.  If not, see <http://www.gnu.org/licenses/>.
  */
 
+#include "config.h"
+
 #include "logging.h"
 
 #define hex_print(p) applog(LOG_DEBUG, "%s", p)

+ 3 - 0
libbitfury.h

@@ -1,6 +1,9 @@
 #ifndef __LIBBITFURY_H__
 #define __LIBBITFURY_H__
 
+#include <stdbool.h>
+#include <stdint.h>
+
 #include "miner.h"
 #include "spidevc.h"
 

+ 2 - 0
libztex.c

@@ -25,6 +25,8 @@
 
 #include "config.h"
 
+#include <stdbool.h>
+#include <stdint.h>
 #include <stdio.h>
 #include <unistd.h>
 #include <string.h>

+ 3 - 0
libztex.h

@@ -1,6 +1,9 @@
 #ifndef __LIBZTEX_H__
 #define __LIBZTEX_H__
 
+#include <stdbool.h>
+#include <stdint.h>
+
 #include <libusb.h>
 
 #include "dynclock.h"

+ 1 - 0
logging.c

@@ -11,6 +11,7 @@
 
 #include "config.h"
 
+#include <stdbool.h>
 #include <unistd.h>
 
 #include "compat.h"

+ 1 - 0
mcp2210.h

@@ -2,6 +2,7 @@
 #define BFG_MCP2210_H
 
 #include <stdbool.h>
+#include <stdint.h>
 
 enum mcp2210_gpio_direction {
 	MGD_OUTPUT,

+ 1 - 0
miner.c

@@ -16,6 +16,7 @@
 #ifdef USE_UNICODE
 #define PDC_WIDE
 #endif
+// Must be before stdbool, since pdcurses typedefs bool :/
 #include <curses.h>
 #endif
 

+ 2 - 0
ocl.c

@@ -12,6 +12,8 @@
 #ifdef HAVE_OPENCL
 
 #include <signal.h>
+#include <stdbool.h>
+#include <stdint.h>
 #include <stdlib.h>
 #include <string.h>
 #include <stdio.h>

+ 2 - 0
scrypt.h

@@ -1,6 +1,8 @@
 #ifndef SCRYPT_H
 #define SCRYPT_H
 
+#include <stdint.h>
+
 #include "miner.h"
 
 #ifdef USE_SCRYPT

+ 1 - 0
sha2.c

@@ -34,6 +34,7 @@
 
 #include "config.h"
 
+#include <stdint.h>
 #include <string.h>
 
 #include "sha2.h"

+ 3 - 0
sha2.h

@@ -33,6 +33,9 @@
  */
 
 #include "config.h"
+
+#include <stdint.h>
+
 #include "miner.h"
 
 #ifndef SHA2_H

+ 3 - 0
sha256_4way.c

@@ -5,10 +5,13 @@
 
 // tcatm's 4-way 128-bit SSE2 SHA-256
 
+#include "config.h"
+
 #include "driver-cpu.h"
 
 #ifdef WANT_SSE2_4WAY
 
+#include <stdbool.h>
 #include <string.h>
 #include <assert.h>
 

+ 3 - 0
sha256_altivec_4way.c

@@ -10,10 +10,13 @@
 //
 
 
+#include "config.h"
+
 #include "driver-cpu.h"
 
 #ifdef WANT_ALTIVEC_4WAY
 
+#include <stdbool.h>
 #include <string.h>
 #include <assert.h>
 

+ 3 - 0
sha256_sse2_amd64.c

@@ -10,10 +10,13 @@
  *
  */
 
+#include "config.h"
+
 #include "driver-cpu.h"
 
 #ifdef WANT_X8664_SSE2
 
+#include <stdbool.h>
 #include <string.h>
 #include <assert.h>
 

+ 3 - 0
sha256_sse2_i386.c

@@ -10,10 +10,13 @@
  *
  */
 
+#include "config.h"
+
 #include "driver-cpu.h"
 
 #ifdef WANT_X8632_SSE2
 
+#include <stdbool.h>
 #include <string.h>
 #include <assert.h>
 

+ 3 - 0
sha256_sse4_amd64.c

@@ -10,10 +10,13 @@
  *
  */
 
+#include "config.h"
+
 #include "driver-cpu.h"
 
 #ifdef WANT_X8664_SSE4
 
+#include <stdbool.h>
 #include <string.h>
 #include <assert.h>
 

+ 3 - 0
sha256_via.c

@@ -9,8 +9,11 @@
  * any later version.  See COPYING for more details.
  */
 
+#include "config.h"
+
 #include "driver-cpu.h"
 
+#include <stdbool.h>
 #include <stdint.h>
 #include <stdlib.h>
 #include <string.h>

+ 2 - 0
util.c

@@ -13,6 +13,8 @@
 
 #include "config.h"
 
+#include <stdbool.h>
+#include <stdint.h>
 #include <stdio.h>
 #include <stdlib.h>
 #include <ctype.h>

+ 1 - 0
util.h

@@ -14,6 +14,7 @@
 #define __UTIL_H__
 
 #include <stdbool.h>
+#include <stdint.h>
 #include <string.h>
 #include <sys/time.h>