From b243110ab2af2299e90d0b8c146b04cc28e12a0e Mon Sep 17 00:00:00 2001 From: MatthewColvin Date: Fri, 9 Aug 2024 22:51:21 -0500 Subject: [PATCH] Add Curl to project so start dev on some HomeAssistant API --- .github/workflows/build-simulator-windows.yml | 1 + .github/workflows/build-simulator.yml | 3 +++ Platformio/platformio.ini | 9 ++++++++- 3 files changed, 12 insertions(+), 1 deletion(-) diff --git a/.github/workflows/build-simulator-windows.yml b/.github/workflows/build-simulator-windows.yml index 2fca0b7e..f63acf9b 100644 --- a/.github/workflows/build-simulator-windows.yml +++ b/.github/workflows/build-simulator-windows.yml @@ -14,6 +14,7 @@ jobs: mingw-w64-x86_64-gcc mingw-w64-x86_64-SDL2 mingw-w64-x86_64-python + mingw-w64-x86_64-curl python3-pip - uses: actions/checkout@v3 diff --git a/.github/workflows/build-simulator.yml b/.github/workflows/build-simulator.yml index c252c549..1bdb419c 100644 --- a/.github/workflows/build-simulator.yml +++ b/.github/workflows/build-simulator.yml @@ -23,6 +23,9 @@ jobs: - name: Install SDL2 run : sudo apt-get update && sudo apt-get install -y libsdl2-dev + - name: Install cURL + run : sudo apt-get update && sudo apt-get install -y libcurl4-openssl-dev + - name: Build PlatformIO Project 64 bit sim working-directory: ./Platformio run: pio run --environment x64_sim \ No newline at end of file diff --git a/Platformio/platformio.ini b/Platformio/platformio.ini index bf1025f4..ed5fb361 100644 --- a/Platformio/platformio.ini +++ b/Platformio/platformio.ini @@ -49,13 +49,14 @@ build_flags = -I OmoteUI/UIs/BasicRefactored/screen -I OmoteUI/UIs/BasicRefactored/page -I OmoteUI/UIs/BasicRefactored/widget + -I OmoteUI/UIs/Matts -I HAL -I HAL/HardwareModules lib_deps = ;lvgl/lvgl@^8.3.9 lvgl=https://github.com/lvgl/lvgl/archive/refs/tags/v8.3.9.zip - + lib_archive = false build_src_filter = +<../OmoteUI/*> @@ -85,6 +86,7 @@ lib_deps = SPI Keypad Preferences + anto/libcurl-esp32 build_flags = ${env.build_flags} -D OMOTE_ESP32 @@ -109,6 +111,10 @@ build_flags = -D LV_TICK_CUSTOM_INCLUDE="\"Arduino.h\"" -D LV_TICK_CUSTOM_SYS_TIME_EXPR="'(millis())'" + ; --------------- libcurl-esp32 Defines ----------------------------- + -D BUILDING_LIBCURL + -D DHAVE_CONFIG_H + ; ------------- Includes -------------------------------------------- -I HAL/Targets/ESP32 -I HAL/Targets/ESP32/battery @@ -136,6 +142,7 @@ build_flags = ;-D LV_LOG_PRINTF=1 -lSDL2 ; SDL2 must be installed on system! Windows:msys2 ubuntu:apt-get -lpthread ; std::thread for Linux + -lcurl ; --------- SDL drivers options ----------------------------- -D LV_LVGL_H_INCLUDE_SIMPLE -D LV_DRV_NO_CONF