scrypt.h 591 B

123456789101112131415161718192021222324252627
  1. #ifndef SCRYPT_H
  2. #define SCRYPT_H
  3. #include <stdbool.h>
  4. #include <stdint.h>
  5. #include "miner.h"
  6. #ifdef USE_SCRYPT
  7. extern bool scrypt_test(unsigned char *pdata, const unsigned char *ptarget,
  8. uint32_t nonce);
  9. extern void scrypt_outputhash(struct work *work);
  10. #else /* USE_SCRYPT */
  11. static inline bool scrypt_test(__maybe_unused unsigned char *pdata,
  12. __maybe_unused const unsigned char *ptarget,
  13. __maybe_unused uint32_t nonce)
  14. {
  15. return false;
  16. }
  17. static inline void scrypt_outputhash(__maybe_unused struct work *work)
  18. {
  19. }
  20. #endif /* USE_SCRYPT */
  21. #endif /* SCRYPT_H */