From 370cdb3ee2a0f022704370f88eae70a4858f4db5 Mon Sep 17 00:00:00 2001 From: Yota Nagaya Date: Wed, 17 Sep 2025 01:02:19 +0900 Subject: [PATCH] Fix details --- RPi-Pico/benchmark/CMakeLists.txt | 8 -------- RPi-Pico/config/lwipopts.h | 2 +- RPi-Pico/config/user_settings.h | 2 -- RPi-Pico/tcp_client/CMakeLists.txt | 8 -------- RPi-Pico/tcp_server/CMakeLists.txt | 8 -------- RPi-Pico/testwolfcrypt/CMakeLists.txt | 12 ++++-------- RPi-Pico/tls_client/CMakeLists.txt | 8 -------- RPi-Pico/tls_server/CMakeLists.txt | 8 -------- RPi-Pico/wifi/CMakeLists.txt | 8 -------- 9 files changed, 5 insertions(+), 59 deletions(-) diff --git a/RPi-Pico/benchmark/CMakeLists.txt b/RPi-Pico/benchmark/CMakeLists.txt index 9befa3cf..191f5dfa 100644 --- a/RPi-Pico/benchmark/CMakeLists.txt +++ b/RPi-Pico/benchmark/CMakeLists.txt @@ -21,12 +21,4 @@ pico_enable_stdio_usb(benchmark 1) pico_enable_stdio_uart(benchmark 0) endif() -if (${PICO_PLATFORM} STREQUAL "rp2350") -add_compile_definitions(wolfssl WOLFSSL_SP_ARM_CORTEX_M_ASM) -elseif (${PICO_PLATFORM} STREQUAL "rp2350-riscv") -add_compile_definitions(wolfSSL WOLFSSL_SP_RISCV32) -else() -add_compile_definitions(wolfssl WOLFSSL_SP_ARM_THUMB_ASM) -endif() - pico_add_extra_outputs(benchmark) diff --git a/RPi-Pico/config/lwipopts.h b/RPi-Pico/config/lwipopts.h index 28afb551..aff4ddd5 100644 --- a/RPi-Pico/config/lwipopts.h +++ b/RPi-Pico/config/lwipopts.h @@ -28,6 +28,6 @@ #define DEFAULT_TCP_RECVMBOX_SIZE 10 #undef MEM_SIZE -#define MEM_SIZE 4000 * 10 +#define MEM_SIZE 4000 * 4 #endif diff --git a/RPi-Pico/config/user_settings.h b/RPi-Pico/config/user_settings.h index 73e14720..ff136a6d 100644 --- a/RPi-Pico/config/user_settings.h +++ b/RPi-Pico/config/user_settings.h @@ -45,8 +45,6 @@ extern time_t myTime(time_t *); /* ------------------------------------------------------------------------- */ /* Platform */ /* ------------------------------------------------------------------------- */ -#define WOLFSSL_GENERAL_ALIGNMENT 4 -#define SIZEOF_LONG_LONG 8 #if 0 #define NO_64BIT /* disable use of 64-bit variables */ #endif diff --git a/RPi-Pico/tcp_client/CMakeLists.txt b/RPi-Pico/tcp_client/CMakeLists.txt index 119ab069..c74f199c 100644 --- a/RPi-Pico/tcp_client/CMakeLists.txt +++ b/RPi-Pico/tcp_client/CMakeLists.txt @@ -31,12 +31,4 @@ pico_enable_stdio_usb(tcp_Client 1) pico_enable_stdio_uart(tcp_Client 0) endif() -if (${PICO_PLATFORM} STREQUAL "rp2350") -add_compile_definitions(wolfssl WOLFSSL_SP_ARM_CORTEX_M_ASM) -elseif (${PICO_PLATFORM} STREQUAL "rp2350-riscv") -add_compile_definitions(wolfSSL WOLFSSL_SP_RISCV32) -else() -add_compile_definitions(wolfssl WOLFSSL_SP_ARM_THUMB_ASM) -endif() - pico_add_extra_outputs(tcp_Client) diff --git a/RPi-Pico/tcp_server/CMakeLists.txt b/RPi-Pico/tcp_server/CMakeLists.txt index de0c7113..ba0431fe 100644 --- a/RPi-Pico/tcp_server/CMakeLists.txt +++ b/RPi-Pico/tcp_server/CMakeLists.txt @@ -30,12 +30,4 @@ pico_enable_stdio_usb(tcp_Server 1) pico_enable_stdio_uart(tcp_Server 0) endif() -if (${PICO_PLATFORM} STREQUAL "rp2350") -add_compile_definitions(wolfssl WOLFSSL_SP_ARM_CORTEX_M_ASM) -elseif (${PICO_PLATFORM} STREQUAL "rp2350-riscv") -add_compile_definitions(wolfSSL WOLFSSL_SP_RISCV32) -else() -add_compile_definitions(wolfssl WOLFSSL_SP_ARM_THUMB_ASM) -endif() - pico_add_extra_outputs(tcp_Server) diff --git a/RPi-Pico/testwolfcrypt/CMakeLists.txt b/RPi-Pico/testwolfcrypt/CMakeLists.txt index 488b3fbf..ab705449 100644 --- a/RPi-Pico/testwolfcrypt/CMakeLists.txt +++ b/RPi-Pico/testwolfcrypt/CMakeLists.txt @@ -3,6 +3,10 @@ add_executable(testwolfcrypt ${WOLFSSL_ROOT}/wolfcrypt/test/test.c ) +target_compile_definitions(testwolfcrypt PRIVATE + WOLFSSL_USER_SETTINGS +) + target_link_libraries(testwolfcrypt wolfssl pico_stdlib @@ -17,12 +21,4 @@ pico_enable_stdio_usb(testwolfcrypt 1) pico_enable_stdio_uart(testwolfcrypt 0) endif() -if (${PICO_PLATFORM} STREQUAL "rp2350") -add_compile_definitions(wolfssl WOLFSSL_SP_ARM_CORTEX_M_ASM) -elseif (${PICO_PLATFORM} STREQUAL "rp2350-riscv") -add_compile_definitions(wolfSSL WOLFSSL_SP_RISCV32) -else() -add_compile_definitions(wolfssl WOLFSSL_SP_ARM_THUMB_ASM) -endif() - pico_add_extra_outputs(testwolfcrypt) diff --git a/RPi-Pico/tls_client/CMakeLists.txt b/RPi-Pico/tls_client/CMakeLists.txt index 7fd75b40..7a9a31f0 100644 --- a/RPi-Pico/tls_client/CMakeLists.txt +++ b/RPi-Pico/tls_client/CMakeLists.txt @@ -36,12 +36,4 @@ pico_enable_stdio_usb(tls_Client 1) pico_enable_stdio_uart(tls_Client 0) endif() -if (${PICO_PLATFORM} STREQUAL "rp2350") -add_compile_definitions(wolfssl WOLFSSL_SP_ARM_CORTEX_M_ASM) -elseif (${PICO_PLATFORM} STREQUAL "rp2350-riscv") -add_compile_definitions(wolfSSL WOLFSSL_SP_RISCV32) -else() -add_compile_definitions(wolfssl WOLFSSL_SP_ARM_THUMB_ASM) -endif() - pico_add_extra_outputs(tls_Client) diff --git a/RPi-Pico/tls_server/CMakeLists.txt b/RPi-Pico/tls_server/CMakeLists.txt index 229bcb8a..364f9515 100644 --- a/RPi-Pico/tls_server/CMakeLists.txt +++ b/RPi-Pico/tls_server/CMakeLists.txt @@ -35,12 +35,4 @@ pico_enable_stdio_usb(tls_Server 1) pico_enable_stdio_uart(tls_Server 0) endif() -if (${PICO_PLATFORM} STREQUAL "rp2350") -add_compile_definitions(wolfssl WOLFSSL_SP_ARM_CORTEX_M_ASM) -elseif (${PICO_PLATFORM} STREQUAL "rp2350-riscv") -add_compile_definitions(wolfSSL WOLFSSL_SP_RISCV32) -else() -add_compile_definitions(wolfssl WOLFSSL_SP_ARM_THUMB_ASM) -endif() - pico_add_extra_outputs(tls_Server) diff --git a/RPi-Pico/wifi/CMakeLists.txt b/RPi-Pico/wifi/CMakeLists.txt index d7c7d553..eca0e72b 100644 --- a/RPi-Pico/wifi/CMakeLists.txt +++ b/RPi-Pico/wifi/CMakeLists.txt @@ -28,12 +28,4 @@ else() pico_enable_stdio_uart(Wifi 0) endif() -if (${PICO_PLATFORM} STREQUAL "rp2350") - add_compile_definitions(wolfssl WOLFSSL_SP_ARM_CORTEX_M_ASM) -elseif (${PICO_PLATFORM} STREQUAL "rp2350-riscv") - add_compile_definitions(wolfSSL WOLFSSL_SP_RISCV32) -else() - add_compile_definitions(wolfssl WOLFSSL_SP_ARM_THUMB_ASM) -endif() - pico_add_extra_outputs(Wifi)