-
Notifications
You must be signed in to change notification settings - Fork 3
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Major refactor I somehow forgot about and futile attemt to fix I2C (#75)
* Major refactor I somehow forgot about and futile attemt to fix I2C * Replace hal/misc.h * Use macros to disable stdlib from gpio_ll.h * Tidy the clang
- Loading branch information
1 parent
71cf9e0
commit c688ab4
Showing
96 changed files
with
2,006 additions
and
852 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
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
File renamed without changes.
File renamed without changes.
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
File renamed without changes.
File renamed without changes.
File renamed without changes.
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,28 @@ | ||
|
||
# SPDX-License-Identifier: MIT | ||
|
||
cmake_minimum_required(VERSION 3.10.0) | ||
|
||
# The target platform | ||
if(NOT DEFINED ENV{BADGEROS_PORT}) | ||
set(BADGEROS_PORT esp32c6) | ||
else() | ||
set(BADGEROS_PORT $ENV{BADGEROS_PORT}) | ||
endif() | ||
|
||
# Set the C compiler | ||
if(DEFINED CMAKE_C_COMPILER) | ||
message("Using compiler '${CMAKE_C_COMPILER}' from environment") | ||
elseif(DEFINED ENV{CMAKE_C_COMPILER}) | ||
set(CMAKE_C_COMPILER $ENV{CMAKE_C_COMPILER}) | ||
message("Using compiler '${CMAKE_C_COMPILER}' from environment") | ||
else() | ||
find_program(CMAKE_C_COMPILER NAMES riscv32-badgeros-linux-gnu-gcc riscv32-unknown-linux-gnu-gcc riscv32-linux-gnu-gcc riscv64-unknown-linux-gnu-gcc riscv64-linux-gnu-gcc REQUIRED) | ||
message("Detected RISC-V C compiler as '${CMAKE_C_COMPILER}'") | ||
endif() | ||
|
||
# Determine the compiler prefix | ||
get_filename_component(compiler_name "${CMAKE_C_COMPILER}" NAME) | ||
string(REGEX MATCH "^([A-Za-z0-9_]+\-)*" BADGER_COMPILER_PREFIX "${compiler_name}") | ||
find_program(BADGER_OBJCOPY NAMES "${BADGER_COMPILER_PREFIX}objcopy" REQUIRED) | ||
find_program(BADGER_OBJDUMP NAMES "${BADGER_COMPILER_PREFIX}objdump" REQUIRED) |
File renamed without changes.
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
File renamed without changes.
File renamed without changes.
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
Oops, something went wrong.