Skip to content

Commit

Permalink
Merge branch 'main' into dev-ip-build-sep
Browse files Browse the repository at this point in the history
  • Loading branch information
tony-josi-aws authored Nov 5, 2024
2 parents cecf06e + 9af3768 commit e8f5b2e
Show file tree
Hide file tree
Showing 33 changed files with 25,352 additions and 21 deletions.
16 changes: 16 additions & 0 deletions .github/.cSpellWords.txt
Original file line number Diff line number Diff line change
Expand Up @@ -229,6 +229,7 @@ DEFR
Deglitchers
DEMCR
DEREN
Descs
DEVAD
DFREERTOS
DFSR
Expand Down Expand Up @@ -394,6 +395,8 @@ ETHERC
ethernetif
ETHMACRX
ETHMACTX
ETHTX
ETHRX
ETIE
EVCNT
EVCNTR
Expand Down Expand Up @@ -441,6 +444,7 @@ FFSR
FIFOSZ
FLMSK
FMAC
FNUM
FOLDEVTENA
FORCEWT
FORWARDALLEXCEPTPA
Expand Down Expand Up @@ -477,6 +481,14 @@ Gpbs
GPCNTRL
gpio
GPIO
GPIOA
GPIOB
GPIOC
GPIOD
GPIOE
GPIOF
GPIOG
GPIOH
GPSL
GPSLCE
gptimer
Expand Down Expand Up @@ -593,6 +605,7 @@ IVLTV
IVTIR
JABBR
JFRAME
Jndex
jscott
jscotts
karkhaz
Expand Down Expand Up @@ -677,6 +690,7 @@ MACECR
MACFCR
MACHT
MACHTLR
MACHWF
MACIMR
MACISR
MACMDIOAR
Expand Down Expand Up @@ -922,6 +936,7 @@ Picovolts
PIDEVAD
pidr
PIDR
PINSEL
PIOA
PKHBT
pkhtb
Expand Down Expand Up @@ -1323,6 +1338,7 @@ TBFT
TBQB
TBQBAPQ
TBUE
TBUS
TCKER
TCMSSV
TCOMP
Expand Down
2 changes: 2 additions & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -126,6 +126,7 @@ jobs:
uses: FreeRTOS/CI-CD-Github-Actions/spellings@main
with:
path: ./
exclude-dirs: source/portable/NetworkInterface/STM32

formatting:
runs-on: ubuntu-20.04
Expand All @@ -135,6 +136,7 @@ jobs:
uses: FreeRTOS/CI-CD-Github-Actions/formatting@main
with:
path: ./
exclude-dirs: source/portable/NetworkInterface/STM32

doxygen:
runs-on: ubuntu-latest
Expand Down
54 changes: 38 additions & 16 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -20,31 +20,43 @@ jobs:
with:
ref: ${{ github.event.inputs.commit_id }}
- name: Configure git identity
env:
ACTOR: ${{ github.actor }}
run: |
git config --global user.name ${{ github.actor }}
git config --global user.email ${{ github.actor }}@users.noreply.github.com
git config --global user.name "$ACTOR"
git config --global user.email "$ACTOR"@users.noreply.github.com
- name: create a new branch that references commit id
run: git checkout -b ${{ github.event.inputs.version_number }} ${{ github.event.inputs.commit_id }}
env:
VERSION_NUMBER: ${{ github.event.inputs.version_number }}
COMMIT_ID: ${{ github.event.inputs.commit_id }}
run: git checkout -b "$VERSION_NUMBER" "$COMMIT_ID"
- name: Generate SBOM
uses: FreeRTOS/CI-CD-Github-Actions/sbom-generator@main
with:
repo_path: ./
source_path: ./source
- name: commit SBOM file
env:
VERSION_NUMBER: ${{ github.event.inputs.version_number }}
run: |
git add .
git commit -m 'Update SBOM'
git push -u origin ${{ github.event.inputs.version_number }}
git push -u origin "$VERSION_NUMBER"
- name: Tag Commit and Push to remote
env:
VERSION_NUMBER: ${{ github.event.inputs.version_number }}
run: |
git tag ${{ github.event.inputs.version_number }} -a -m "FreeRTOS-Plus-TCP Library ${{ github.event.inputs.version_number }}"
git tag "$VERSION_NUMBER" -a -m "FreeRTOS-Plus-TCP Library $VERSION_NUMBER"
git push origin --tags
- name: Verify tag on remote
env:
VERSION_NUMBER: ${{ github.event.inputs.version_number }}
COMMIT_ID: ${{ github.event.inputs.commit_id }}
run: |
git tag -d ${{ github.event.inputs.version_number }}
git tag -d "$VERSION_NUMBER"
git remote update
git checkout tags/${{ github.event.inputs.version_number }}
git diff ${{ github.event.inputs.commit_id }} tags/${{ github.event.inputs.version_number }}
git checkout tags/"$VERSION_NUMBER"
git diff "$COMMIT_ID" tags/"$VERSION_NUMBER"
create-zip:
needs: tag-commit
name: Create ZIP and verify package for release asset.
Expand All @@ -63,28 +75,36 @@ jobs:
cd FreeRTOS-Plus-TCP
git submodule update --init --checkout --recursive
- name: Create ZIP
env:
VERSION_NUMBER: ${{ github.event.inputs.version_number }}
run: |
zip -r FreeRTOS-Plus-TCP-${{ github.event.inputs.version_number }}.zip FreeRTOS-Plus-TCP -x "*.git*"
zip -r FreeRTOS-Plus-TCP-"$VERSION_NUMBER".zip FreeRTOS-Plus-TCP -x "*.git*"
ls ./
- name: Validate created ZIP
env:
VERSION_NUMBER: ${{ github.event.inputs.version_number }}
run: |
mkdir zip-check
mv FreeRTOS-Plus-TCP-${{ github.event.inputs.version_number }}.zip zip-check
mv FreeRTOS-Plus-TCP-"$VERSION_NUMBER".zip zip-check
cd zip-check
unzip FreeRTOS-Plus-TCP-${{ github.event.inputs.version_number }}.zip -d FreeRTOS-Plus-TCP-${{ github.event.inputs.version_number }}
ls FreeRTOS-Plus-TCP-${{ github.event.inputs.version_number }}
diff -r -x "*.git*" FreeRTOS-Plus-TCP-${{ github.event.inputs.version_number }}/FreeRTOS-Plus-TCP/ ../FreeRTOS-Plus-TCP/
unzip FreeRTOS-Plus-TCP-"$VERSION_NUMBER".zip -d FreeRTOS-Plus-TCP-"$VERSION_NUMBER"
ls FreeRTOS-Plus-TCP-"$VERSION_NUMBER"
diff -r -x "*.git*" FreeRTOS-Plus-TCP-"$VERSION_NUMBER"/FreeRTOS-Plus-TCP/ ../FreeRTOS-Plus-TCP/
cd ../
- name: Build
env:
VERSION_NUMBER: ${{ github.event.inputs.version_number }}
run: |
cd zip-check/FreeRTOS-Plus-TCP-${{ github.event.inputs.version_number }}/FreeRTOS-Plus-TCP
cd zip-check/FreeRTOS-Plus-TCP-"$VERSION_NUMBER"/FreeRTOS-Plus-TCP
sudo apt-get install -y lcov
sudo apt-get install unifdef
cmake -S test/unit-test -B test/unit-test/build/
make -C test/unit-test/build/ all
- name: Test
env:
VERSION_NUMBER: ${{ github.event.inputs.version_number }}
run: |
cd zip-check/FreeRTOS-Plus-TCP-${{ github.event.inputs.version_number }}/FreeRTOS-Plus-TCP
cd zip-check/FreeRTOS-Plus-TCP-"$VERSION_NUMBER"/FreeRTOS-Plus-TCP
pushd test/unit-test/build/
ctest -E system --output-on-failure
popd
Expand Down Expand Up @@ -147,6 +167,8 @@ jobs:
- name: Checkout code
uses: actions/checkout@v4
- name: Delete branch created for Tag by SBOM generator
env:
VERSION_NUMBER: ${{ github.event.inputs.version_number }}
run: |
# Delete the branch created for Tag by SBOM generator
git push -u origin --delete refs/heads/${{ github.event.inputs.version_number }}
git push -u origin --delete refs/heads/"$VERSION_NUMBER"
5 changes: 2 additions & 3 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -71,7 +71,7 @@ set(FREERTOS_PLUS_TCP_NETWORK_IF_LIST
POSIX WIN_PCAP # Native Linux & Windows respectively
RX
SH2A
STM32FXX STM32HXX # ST Micro
STM32 # ST Micro
MSP432
TM4C
XILINX_ULTRASCALE ZYNQ # AMD/Xilinx
Expand Down Expand Up @@ -117,8 +117,7 @@ if(NOT FREERTOS_PLUS_TCP_NETWORK_IF IN_LIST FREERTOS_PLUS_TCP_NETWORK_IF_LIST )
" PIC32MZEF_WIFI Target: pic32mzef Wifi Tested: TODO\n"
" RX Target: RX Tested: TODO\n"
" SH2A Target: SH2A Tested: TODO\n"
" STM32FXX Target: STM32Fxx Tested: TODO\n"
" STM32HXX Target: STM32Hxx Tested: TODO\n"
" STM32 Target: STM32 Tested: TODO\n"
" MSP432 Target: MSP432 Tested: TODO\n"
" TM4C Target: TM4C Tested: TODO\n"
" WIN_PCAP Target: Windows Tested: TODO\n"
Expand Down
3 changes: 1 addition & 2 deletions source/portable/NetworkInterface/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -49,8 +49,7 @@ add_subdirectory(mw300_rd)
add_subdirectory(pic32mzef)
add_subdirectory(RX)
add_subdirectory(SH2A)
add_subdirectory(STM32Fxx)
add_subdirectory(STM32Hxx)
add_subdirectory(STM32)
add_subdirectory(ThirdParty/MSP432)
add_subdirectory(TM4C)
add_subdirectory(WinPCap)
Expand Down
46 changes: 46 additions & 0 deletions source/portable/NetworkInterface/STM32/CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,46 @@
if (NOT ( (FREERTOS_PLUS_TCP_NETWORK_IF STREQUAL "STM32") ) )
return()
endif()

#------------------------------------------------------------------------------
add_library( freertos_plus_tcp_network_if STATIC )

set( FREERTOS_PLUS_TCP_STM32_IF_DRIVER "None" CACHE STRING "The driver sources to use with STM32 Network interface" )

target_sources( freertos_plus_tcp_network_if
PRIVATE
NetworkInterface.c
$<$<STREQUAL:${FREERTOS_PLUS_TCP_STM32_IF_DRIVER},F4>:
Drivers/F4/stm32f4xx_hal_eth.c>
$<$<STREQUAL:${FREERTOS_PLUS_TCP_STM32_IF_DRIVER},F7>:
Drivers/F7/stm32f7xx_hal_eth.c>
$<$<STREQUAL:${FREERTOS_PLUS_TCP_STM32_IF_DRIVER},H5>:
Drivers/H5/stm32h5xx_hal_eth_ex.c>
$<$<STREQUAL:${FREERTOS_PLUS_TCP_STM32_IF_DRIVER},H5>:
Drivers/H5/stm32h5xx_hal_eth.c>
$<$<STREQUAL:${FREERTOS_PLUS_TCP_STM32_IF_DRIVER},H7>:
Drivers/H7/stm32h7xx_hal_eth_ex.c>
$<$<STREQUAL:${FREERTOS_PLUS_TCP_STM32_IF_DRIVER},H7>:
Drivers/H7/stm32h7xx_hal_eth.c>
)

target_include_directories( freertos_plus_tcp_network_if
PUBLIC
$<$<STREQUAL:${FREERTOS_PLUS_TCP_STM32_IF_DRIVER},F4>:
Drivers/F4>
$<$<STREQUAL:${FREERTOS_PLUS_TCP_STM32_IF_DRIVER},F7>:
Drivers/F7>
$<$<STREQUAL:${FREERTOS_PLUS_TCP_STM32_IF_DRIVER},H5>:
Drivers/H5>
$<$<STREQUAL:${FREERTOS_PLUS_TCP_STM32_IF_DRIVER},H7>:
Drivers/H7>
)

target_link_libraries( freertos_plus_tcp_network_if
PUBLIC
freertos_plus_tcp_port
freertos_plus_tcp_network_if_common
PRIVATE
freertos_kernel
freertos_plus_tcp
)
Loading

0 comments on commit e8f5b2e

Please sign in to comment.