Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Conversation

@chinglee-iot
Copy link
Member

@chinglee-iot chinglee-iot commented Jun 9, 2023

Description

  • Add CMakeList.txt in posix GCC demos to consume FreeRTOS-Kernel/CMakeLists.txt
  • Add the following option to match existing Makefile

Trace on enter

cmake -S . -B build -DTRACE_ON_ENTER=1

Coverage test

cmake -S . -B build -DCOVERAGE_TEST=1

Profile

cmake -S . -B build -DPROFILE=1

sanitize address and alignment

cmake -S . -B build -DSANITIZE_ADDRESS=1

sanitize leak

cmake -S . -B build -DSANITIZE_LEAK=1

Test Steps

cd ./FreeRTOS/FreeRTOS/Demo/Posix_GCC
cmake -B build -S .
cd build
make

To build with clang compiler, you will need to suppress some compiler warning

target_compile_options( freertos_kernel
  PRIVATE
    $<$<COMPILE_LANG_AND_ID:C,Clang>:-Wno-cast-align>
    $<$<COMPILE_LANG_AND_ID:C,Clang>:-Wno-covered-switch-default>
    $<$<COMPILE_LANG_AND_ID:C,Clang>:-Wno-missing-variable-declarations>
    $<$<COMPILE_LANG_AND_ID:C,Clang>:-Wno-padded>
    $<$<COMPILE_LANG_AND_ID:C,Clang>:-Wno-unused-macros>
)
target_compile_options( freertos_kernel_port
  PRIVATE
     $<$<COMPILE_LANG_AND_ID:C,Clang>:-Wno-disabled-macro-expansion>
     $<$<COMPILE_LANG_AND_ID:C,Clang>:-Wno-padded>
     $<$<COMPILE_LANG_AND_ID:C,Clang>:-Wno-reserved-id-macro>
)

Checklist:

  • I have tested my changes. No regression in existing tests.
  • I have modified and/or added unit-tests to cover the code changes in this Pull Request.

Related Issue

By submitting this pull request, I confirm that you can use, modify, copy, and redistribute this contribution, under the terms of your choice.

@chinglee-iot chinglee-iot requested a review from a team as a code owner June 9, 2023 11:09
* Remove redundent if defined check
@chinglee-iot chinglee-iot requested a review from Skptak June 12, 2023 03:07
aggarg
aggarg previously approved these changes Jun 12, 2023
* Move the define of projCOVERAGE_TEST in COVERAGE_TEST
* Use add_compile_options instead of CMAKE_C_FLAGS
@chinglee-iot chinglee-iot requested a review from aggarg June 16, 2023 07:16
@chinglee-iot chinglee-iot merged commit 8f3233e into FreeRTOS:main Jun 16, 2023
moninom1 pushed a commit to moninom1/FreeRTOS that referenced this pull request Jun 26, 2023
* Add cmake for posix GCC demo

---------

Co-authored-by: Gaurav-Aggarwal-AWS <[email protected]>
@moninom1 moninom1 mentioned this pull request Jun 26, 2023
2 tasks
moninom1 added a commit that referenced this pull request Jun 28, 2023
* Add IAR projects for LPC55S69  (#1007)

* Add IAR projects for LPC55S69

* IAR Project for trustzone
* MCUXpresso and IAR projects for non-trustzone (NTZ) ports

Signed-off-by: Gaurav Aggarwal <[email protected]>

* Fix build issues and warnings

Signed-off-by: Gaurav Aggarwal <[email protected]>

* Fix formatting check

Signed-off-by: Gaurav Aggarwal <[email protected]>

---------

Signed-off-by: Gaurav Aggarwal <[email protected]>

* Set configMAX_SYSCALL_INTERRUPT_PRIORITY to 4 for QEMU demos (#986)

* Update FreeRTOSConfig.h

* Update FreeRTOSConfig.h

* Update FreeRTOSConfig.h

* Added Posix Demo run in github action (#997)

* Added demo runs for Posix GCC  in git action

---------

Co-authored-by: Joseph Julicher <[email protected]>

* Update FreeRTOSconfig.h for M2351 (#1005)

The number of implemented priority bits for Armv8-M baseline
implementation is defined by the architecture as 2. Therefore the
config option `configPRIO_BITS` is updated to 2.

In addition, in Armv8-M baseline implementation BASEPRI is RES0.
Therefore, `configMAX_SYSCALL_INTERRUPT_PRIORITY` is not supported. Hence
this config option is removed.

Signed-off-by: Devaraj Ranganna <[email protected]>
Co-authored-by: Gaurav-Aggarwal-AWS <[email protected]>

* Fix file path in the project file (#1013)

Signed-off-by: Gaurav Aggarwal <[email protected]>

* Add unit tests for kernel PR #679 (#1015)

Also, fix the broken tests by that PR.

Signed-off-by: Gaurav Aggarwal <[email protected]>

* Update FreeRTOS-Kernel Source submodule

* Updating kernel release script to update source files with tags and release in separate scripts (#1016)

* separating  source file updation to separate script
* give execute permission to update_src_version.py

* risc-v: Fix build flags and linker scripts (#906)

1. miss debug info in assembly code
RISC-V-spike-htif_GCC
        LDFLAGS add arch and abi info for linker
            for riscv64-unknown-elf multilib, if there is no arch and abi
            info, will link to default lib and have below error
            target emulation `elf32-littleriscv' does not match `elf64-littleriscv'
        use CFLAGS to replace ASFLAGS when compile assembly code
            because DEBUG flag is added in CFLAGS, if we use ASFLAGS to compile
            assembly code, there is no debug info in assembly code objfile

2. binutils 2.39 ld warn 'has a LOAD segment with RWX permissions'
RISC-V-Qemu-virt_GCC
RISC-V-spike-htif_GCC
RISC-V_RV32_QEMU_VIRT_GCC

3. fix build fail
RISC-V_RV32_QEMU_VIRT_GCC

Signed-off-by: Eric Chan <[email protected]>

* Create GitHub Workflows that execute the p3 FreeRTOS Kernel Demos (#1018)

* test full demo

* Revert "test full demo"

This reverts commit 09efa00.

revert back to origin

* pre-define user demo to blinky demo

* pre-define user demo to blinky demo with -j

* test run win32-msvc demo

* test run win32-msvc demo

* test run win32-msvc demo

* update git workflow to run WIN32-MSVC demo

* update git workflow to run WIN32-MSVC demo

* update git workflow to run WIN32-MSVC demo

* update git workflow to run WIN32-MSVC demo

* update git workflow to run WIN32-MSVC demo

* update git workflow to run WIN32-MSVC demo

* update git workflow to run WIN32-MSVC demo

* update trigger action

* build and run WIN32-MSVC blinky demo

* build and run WIN32-MSVC blinky demo

* build and run WIN32-MSVC blinky demo

* update WIN32-MSVC workflow

* update WIN32-MSVC Demo main.c file to remove buffer

* Update main.c files to remove buffer when running executable_monitor file for Git Action

* update formatting for WIN32-MSVC demos

* update formatting for Posix demo

* update comment for setvbuf function used in main.c

* add git build and run action for WIN32-MingW Full and Blinky demos; update main.c file to set buffer size as 0

* add git build and run action for WIN32-MingW Full and Blinky demos; update main.c file to set buffer size as 0

* remove whitespace for freertos_demos.yml file

* add function to Force stdout to write immediately by setting the buffer size for it to 0 in demo main.c file when running git Run Action; Correct formatting error for WIN32-MingW main.c file

* add function to Force stdout to write immediately by setting the buffer size for it to 0 in demo main.c file when running git Run Action

* update git run action commands for Posix_GCC demo

* update git run action commands for Posix_GCC demo

* update git run action commands for Posix_GCC demo

* reduce timeout and correct formatting issue

* reduce timeout

---------

Co-authored-by: Xiaodong Li <[email protected]>

* Revert "Remove coroutines (#874)" (#1019)

* Revert "Remove coroutines (#874)"

This reverts commit 569c78f.

* Update freertos Kernel submodule to latest head

* Remove temporary files

* Fix MingW demos and spell check

* Fix manifest version; fix headers

* Add ignore files and paths to core-checker.py

* Fix copyright in remaining files

* Fix PR check build failure

1. Remove defining `inline` in Makefile. This was causing build
   warnings.
2. Ensure that the linker removed unused functions from various
   compilation units.
3. Update the linker script so that all the functions are correctly
   placed in FLASH section.

Signed-off-by: Gaurav Aggarwal <[email protected]>

---------

Signed-off-by: Gaurav Aggarwal <[email protected]>
Co-authored-by: Gaurav Aggarwal <[email protected]>

* Adding CMakeList.txt in posix GCC demos (#1020)

* Add cmake for posix GCC demo

---------

Co-authored-by: Gaurav-Aggarwal-AWS <[email protected]>

* Update File Header CI check failures

---------

Signed-off-by: Gaurav Aggarwal <[email protected]>
Signed-off-by: Devaraj Ranganna <[email protected]>
Signed-off-by: Eric Chan <[email protected]>
Co-authored-by: Gaurav-Aggarwal-AWS <[email protected]>
Co-authored-by: kar-rahul-aws <[email protected]>
Co-authored-by: xuelix <[email protected]>
Co-authored-by: Joseph Julicher <[email protected]>
Co-authored-by: Devaraj Ranganna <[email protected]>
Co-authored-by: Paul Bartell <[email protected]>
Co-authored-by: Tony Josi <[email protected]>
Co-authored-by: e14002270 <[email protected]>
Co-authored-by: Xiaodong Li <[email protected]>
Co-authored-by: Xiaodong Li <[email protected]>
Co-authored-by: Aniruddha Kanhere <[email protected]>
Co-authored-by: Gaurav Aggarwal <[email protected]>
Co-authored-by: chinglee-iot <[email protected]>
@chinglee-iot chinglee-iot deleted the dev-cmake-posix-gcc branch July 28, 2023 04:10
every-breaking-wave pushed a commit to every-breaking-wave/FreeRTOS that referenced this pull request Nov 15, 2024
* Update coverity example README

* Update main.c for comment

---------

Co-authored-by: Ubuntu <[email protected]>
Zangetsu112 pushed a commit to Zangetsu112/FreeRTOS-evpp that referenced this pull request Aug 18, 2025
* Add cmake for posix GCC demo

---------

Co-authored-by: Gaurav-Aggarwal-AWS <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants