This repository has been archived by the owner on Dec 8, 2022. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 1.1k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
vendors/espressif: Add support for esp32s3
- Loading branch information
1 parent
d26a7ce
commit 608bf03
Showing
84 changed files
with
9,403 additions
and
21 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,31 @@ | ||
include("${CMAKE_CURRENT_LIST_DIR}/find_compiler.cmake") | ||
|
||
set(CMAKE_SYSTEM_NAME Generic) | ||
|
||
# Find GCC for Xtensa-ESP32S2. | ||
afr_find_compiler(AFR_COMPILER_CC xtensa-esp32s3-elf-gcc) | ||
afr_find_compiler(AFR_COMPILER_CXX xtensa-esp32s3-elf-g++) | ||
|
||
# Specify the cross compiler. | ||
set(CMAKE_C_COMPILER ${AFR_COMPILER_CC} CACHE FILEPATH "C compiler") | ||
set(CMAKE_CXX_COMPILER ${AFR_COMPILER_CXX} CACHE FILEPATH "C++ compiler") | ||
set(CMAKE_ASM_COMPILER ${AFR_COMPILER_CC} CACHE FILEPATH "ASM compiler") | ||
|
||
# Disable compiler checks. | ||
set(CMAKE_C_COMPILER_FORCED TRUE) | ||
set(CMAKE_CXX_COMPILER_FORCED TRUE) | ||
|
||
# Add target system root to cmake find path. | ||
get_filename_component(AFR_COMPILER_DIR "${AFR_COMPILER_CC}" DIRECTORY) | ||
get_filename_component(CMAKE_FIND_ROOT_PATH "${AFR_COMPILER_DIR}" DIRECTORY) | ||
|
||
# Look for includes and libraries only in the target system prefix. | ||
set(CMAKE_FIND_ROOT_PATH_MODE_INCLUDE ONLY) | ||
set(CMAKE_FIND_ROOT_PATH_MODE_LIBRARY ONLY) | ||
|
||
# Helper variables to abstracts some common compiler flags. | ||
set(AFR_COMPILER_NO_WARNINGS "-w" CACHE INTERNAL "") | ||
|
||
# Global compiler flags. | ||
set(CMAKE_C_FLAGS "-mlongcalls" CACHE STRING "C Compiler Base Flags") | ||
set(CMAKE_CXX_FLAGS "-mlongcalls" CACHE STRING "C++ Compiler Base Flags") |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
# Ignore the build artifacts in the projects. | ||
*build* |
Oops, something went wrong.