CMakeLists.txt 1.6 KB

1234567891011121314151617181920212223242526272829303132333435363738394041
  1. # wolfSSL Espressif Example Project CMakeLists.txt
  2. # v1.0
  3. #
  4. # The following lines of boilerplate have to be in your project's
  5. # CMakeLists in this exact order for cmake to work correctly
  6. cmake_minimum_required(VERSION 3.16)
  7. add_compile_options(-DWOLFSSL_ESP_NO_WATCHDOG=1)
  8. # The wolfSSL CMake file should be able to find the source code.
  9. # Otherwise, assign an environment variable or set it here:
  10. #
  11. # set(WOLFSSL_ROOT "~/workspace/wolfssl-other-source")
  12. #
  13. # Optional WOLFSSL_CMAKE_SYSTEM_NAME detection to find
  14. # USE_MY_PRIVATE_CONFIG path for my_private_config.h
  15. #
  16. # Expected path varies:
  17. #
  18. # WSL: /mnt/c/workspace
  19. # Linux: ~/workspace
  20. # Windows: C:\workspace
  21. #
  22. # Optionally specify a location for wolfSSL component source code
  23. # set(WOLFSSL_ROOT "c:/mydir/wolfssl" )
  24. # This example uses an extra component for common functions such as Wi-Fi and Ethernet connection.
  25. # set (PROTOCOL_EXAMPLES_DIR $ENV{IDF_PATH}/examples/common_components/protocol_examples_common)
  26. #
  27. #if (EXISTS "${PROTOCOL_EXAMPLES_DIR}")
  28. # message("Found PROTOCOL_EXAMPLES_DIR=${PROTOCOL_EXAMPLES_DIR}")
  29. # set(EXTRA_COMPONENT_DIRS $ENV{IDF_PATH}/examples/common_components/protocol_examples_common)
  30. # set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -DFOUND_PROTOCOL_EXAMPLES_DIR")
  31. #else()
  32. # message("NOT FOUND: PROTOCOL_EXAMPLES_DIR=${PROTOCOL_EXAMPLES_DIR}")
  33. #endif()
  34. # Not only is a project-level "set(COMPONENTS" not needed here, this will cause
  35. # an unintuitive error about Unknown CMake command "esptool_py_flash_project_args".
  36. include($ENV{IDF_PATH}/tools/cmake/project.cmake)
  37. project(wolfssl_benchmark)