Merge pull request #7542 from gojimmypi/PR-Espressif-PlatformIO-semphr

Fix PlatformIO freertos semphr.h include
This commit is contained in:
David Garske
2024-05-16 08:28:12 -07:00
committed by GitHub
2 changed files with 13 additions and 4 deletions

View File

@ -41,6 +41,14 @@
CFLAGS +=-DWOLFSSL_USER_SETTINGS" CFLAGS +=-DWOLFSSL_USER_SETTINGS"
#endif #endif
#ifndef SINGLE_THREADED
#ifdef PLATFORMIO
#include <freertos/semphr.h>
#else
#include "semphr.h"
#endif
#endif
/* Espressif */ /* Espressif */
#include "sdkconfig.h" /* programmatically generated from sdkconfig */ #include "sdkconfig.h" /* programmatically generated from sdkconfig */
#include <esp_log.h> #include <esp_log.h>
@ -257,9 +265,6 @@ esp_err_t esp_sdk_mem_lib_init(void)
ESP_LOGI(TAG, "esp_sdk_mem_lib_init Ver %d", ESP_SDK_MEM_LIB_VERSION); ESP_LOGI(TAG, "esp_sdk_mem_lib_init Ver %d", ESP_SDK_MEM_LIB_VERSION);
return ret; return ret;
} }
#ifndef SINGLE_THREADED
#include "semphr.h"
#endif
void* wc_debug_pvPortMalloc(size_t size, void* wc_debug_pvPortMalloc(size_t size,
const char* file, int line, const char* fname) { const char* file, int line, const char* fname) {

View File

@ -1116,7 +1116,11 @@ extern void uITRON4_free(void *p) ;
#endif #endif
#ifndef SINGLE_THREADED #ifndef SINGLE_THREADED
#include "semphr.h" #ifdef PLATFORMIO
#include <freertos/semphr.h>
#else
#include "semphr.h"
#endif
#endif #endif
#endif #endif