mirror of
				https://github.com/esphome/esphome.git
				synced 2025-11-04 00:51:49 +00:00 
			
		
		
		
	fix nrf52
This commit is contained in:
		@@ -1,4 +1,8 @@
 | 
			
		||||
#include "sha256.h"
 | 
			
		||||
 | 
			
		||||
// Only compile SHA256 implementation on platforms that support it
 | 
			
		||||
#if defined(USE_ESP32) || defined(USE_ESP8266) || defined(USE_RP2040) || defined(USE_LIBRETINY)
 | 
			
		||||
 | 
			
		||||
#include "esphome/core/helpers.h"
 | 
			
		||||
#include <cstring>
 | 
			
		||||
 | 
			
		||||
@@ -142,3 +146,5 @@ bool SHA256::equals_hex(const char *expected) {
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
}  // namespace esphome::sha256
 | 
			
		||||
 | 
			
		||||
#endif  // Platform check
 | 
			
		||||
 
 | 
			
		||||
@@ -1,6 +1,10 @@
 | 
			
		||||
#pragma once
 | 
			
		||||
 | 
			
		||||
#include "esphome/core/defines.h"
 | 
			
		||||
 | 
			
		||||
// Only define SHA256 on platforms that support it
 | 
			
		||||
#if defined(USE_ESP32) || defined(USE_ESP8266) || defined(USE_RP2040) || defined(USE_LIBRETINY)
 | 
			
		||||
 | 
			
		||||
#include <cstdint>
 | 
			
		||||
#include <string>
 | 
			
		||||
#include <memory>
 | 
			
		||||
@@ -59,3 +63,5 @@ class SHA256 {
 | 
			
		||||
};
 | 
			
		||||
 | 
			
		||||
}  // namespace esphome::sha256
 | 
			
		||||
 | 
			
		||||
#endif  // Platform check
 | 
			
		||||
 
 | 
			
		||||
		Reference in New Issue
	
	Block a user