Skip to content

Commit

Permalink
fixed docker build
Browse files Browse the repository at this point in the history
  • Loading branch information
ClemensElflein committed Oct 30, 2024
1 parent 7db8ad6 commit e8b49c1
Show file tree
Hide file tree
Showing 5 changed files with 31 additions and 41 deletions.
28 changes: 4 additions & 24 deletions bootloader/.idea/workspace.xml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

6 changes: 3 additions & 3 deletions bootloader/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -10,9 +10,9 @@ RUN apt-get update && apt-get install -y \
COPY . /project

WORKDIR /project
#RUN make -j$(nproc)
RUN mkdir build && cd build && cmake .. --preset=Release && cd Release && make -j$(nproc)


FROM scratch
COPY --from=builder /project/build/xcore-boot.elf /
COPY --from=builder /project/build/xcore-boot.bin /
COPY --from=builder /project/build/Release/xcore-boot.elf /
COPY --from=builder /project/build/Release/xcore-boot.bin /
20 changes: 15 additions & 5 deletions bootloader/cfg/chconf.h
Original file line number Diff line number Diff line change
Expand Up @@ -570,12 +570,14 @@ extern volatile uint32_t last_idle_tick;
#if !defined(CH_DBG_SYSTEM_STATE_CHECK)
#ifdef DEBUG_BUILD
#define CH_DBG_SYSTEM_STATE_CHECK TRUE
#elifdef RELEASE_BUILD
#else
#ifdef RELEASE_BUILD
#define CH_DBG_SYSTEM_STATE_CHECK FALSE
#else
#error "Need to define either DEBUG_BUILD or RELEASE_BUILD"
#endif
#endif
#endif

/**
* @brief Debug option, parameters checks.
Expand All @@ -587,12 +589,14 @@ extern volatile uint32_t last_idle_tick;
#if !defined(CH_DBG_ENABLE_CHECKS)
#ifdef DEBUG_BUILD
#define CH_DBG_ENABLE_CHECKS TRUE
#elifdef RELEASE_BUILD
#else
#ifdef RELEASE_BUILD
#define CH_DBG_ENABLE_CHECKS FALSE
#else
#error "Need to define either DEBUG_BUILD or RELEASE_BUILD"
#endif
#endif
#endif

/**
* @brief Debug option, consistency checks.
Expand All @@ -605,12 +609,14 @@ extern volatile uint32_t last_idle_tick;
#if !defined(CH_DBG_ENABLE_ASSERTS)
#ifdef DEBUG_BUILD
#define CH_DBG_ENABLE_ASSERTS TRUE
#elifdef RELEASE_BUILD
#else
#ifdef RELEASE_BUILD
#define CH_DBG_ENABLE_ASSERTS FALSE
#else
#error "Need to define either DEBUG_BUILD or RELEASE_BUILD"
#endif
#endif
#endif

/**
* @brief Debug option, trace buffer.
Expand Down Expand Up @@ -644,12 +650,14 @@ extern volatile uint32_t last_idle_tick;
#if !defined(CH_DBG_ENABLE_STACK_CHECK)
#ifdef DEBUG_BUILD
#define CH_DBG_ENABLE_STACK_CHECK TRUE
#elifdef RELEASE_BUILD
#else
#ifdef RELEASE_BUILD
#define CH_DBG_ENABLE_STACK_CHECK FALSE
#else
#error "Need to define either DEBUG_BUILD or RELEASE_BUILD"
#endif
#endif
#endif

/**
* @brief Debug option, stacks initialization.
Expand All @@ -662,12 +670,14 @@ extern volatile uint32_t last_idle_tick;
#if !defined(CH_DBG_FILL_THREADS)
#ifdef DEBUG_BUILD
#define CH_DBG_FILL_THREADS TRUE
#elifdef RELEASE_BUILD
#else
#ifdef RELEASE_BUILD
#define CH_DBG_FILL_THREADS FALSE
#else
#error "Need to define either DEBUG_BUILD or RELEASE_BUILD"
#endif
#endif
#endif

/**
* @brief Debug option, threads profiling.
Expand Down
2 changes: 1 addition & 1 deletion bootloader/cmake/gcc-arm-none-eabi.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ set(CMAKE_EXECUTABLE_SUFFIX_CXX ".elf")

set(CMAKE_TRY_COMPILE_TARGET_TYPE STATIC_LIBRARY)

add_compile_definitions(-DCORTEX_USE_FPU=TRUE)
add_compile_definitions(CORTEX_USE_FPU=TRUE)

# MCU specific flags
set(TARGET_FLAGS "-mcpu=cortex-m7 -mfpu=fpv5-d16 -mfloat-abi=hard -fomit-frame-pointer -falign-functions=16 -mthumb -fno-common -flto -nostartfiles")
Expand Down
16 changes: 8 additions & 8 deletions bootloader/ext/ChibiOS_21.11.3/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -90,18 +90,18 @@ add_library(
os/common/ports/ARMv7-M/compilers/GCC/chcoreasm.S
#oslib
os/oslib/src/chmboxes.c
os/oslib/src/chmemcore.c
os/oslib/src/chmemheaps.c
os/oslib/src/chmempools.c
os/oslib/src/chpipes.c
os/oslib/src/chobjcaches.c
os/oslib/src/chdelegates.c
os/oslib/src/chfactory.c
os/oslib/src/chmemcore.c
os/oslib/src/chmemheaps.c
os/oslib/src/chmempools.c
os/oslib/src/chpipes.c
os/oslib/src/chobjcaches.c
os/oslib/src/chdelegates.c
os/oslib/src/chfactory.c
# board
${BOARD_DIR}/board.c
# LwIP
os/various/lwip_bindings/lwipthread.c
os/various/lwip_bindings/arch/sys_arch.c
os/various/lwip_bindings/arch/sys_arch.c
os/various/evtimer.c
${lwipnoapps_SRCS}
)
Expand Down

0 comments on commit e8b49c1

Please sign in to comment.