-
Notifications
You must be signed in to change notification settings - Fork 17
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
7 changed files
with
185 additions
and
51 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,49 @@ | ||
# SPDX-License-Identifier: MIT | ||
# SPDX-FileCopyrightText: (c) 2024 Advanced Micro Devices, Inc. | ||
|
||
name: Build | ||
description: Build TCPDirect | ||
inputs: | ||
tcpdirect_tree: | ||
required: true | ||
type: string | ||
description: Path to the TCPDirect source tree to build | ||
onload_tree: | ||
required: true | ||
type: string | ||
description: Path to the Onload source tree to build TCPDirect with | ||
build_target: | ||
required: false | ||
default: all | ||
type: choice | ||
options: | ||
- all | ||
- shim | ||
description: TCPDirect target to build, all or shim | ||
debug: | ||
required: false | ||
default: false | ||
type: boolean | ||
description: Whether to build debug binaries | ||
runs: | ||
using: "composite" | ||
steps: | ||
- name: Input Validation | ||
shell: sh | ||
env: | ||
BUILD_TARGET: ${{ inputs.build_target }} | ||
run: | | ||
if [ "$BUILD_TARGET" != "all" ] && [ "$BUILD_TARGET" != "shim" ]; then | ||
echo "Input Error: build_target must be either all or shim!" | ||
exit 1 | ||
fi | ||
- name: Build | ||
shell: sh | ||
env: | ||
ONLOAD_TREE: ${{ inputs.onload_tree }} | ||
ZF_DEVEL: ${{ inputs.build_target == 'shim' && 1 || 0 }} | ||
NDEBUG: ${{ fromJSON(inputs.debug) && 0 || 1 }} | ||
BUILD_TARGET: ${{ inputs.build_target }} | ||
working-directory: ${{ inputs.tcpdirect_tree }} | ||
run: make -j $(nproc) "$BUILD_TARGET" |
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,13 @@ | ||
# SPDX-License-Identifier: MIT | ||
# SPDX-FileCopyrightText: (c) 2024 Advanced Micro Devices, Inc. | ||
|
||
name: Install dependencies | ||
description: Install build and test dependencies for TCPDirect | ||
runs: | ||
using: "composite" | ||
steps: | ||
- name: Install dependencies | ||
shell: sh | ||
run: | | ||
sudo apt-get update | ||
sudo apt-get install -y build-essential perl |
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,42 @@ | ||
# SPDX-License-Identifier: MIT | ||
# SPDX-FileCopyrightText: (c) 2024 Advanced Micro Devices, Inc. | ||
|
||
name: Test | ||
description: Run the TCPDirect unit tests | ||
inputs: | ||
tcpdirect_tree: | ||
required: true | ||
type: string | ||
description: Path to the TCPDirect source tree to build | ||
onload_tree: | ||
required: true | ||
type: string | ||
description: Path to the Onload source tree to build TCPDirect with | ||
debug: | ||
required: false | ||
default: true | ||
type: boolean | ||
description: Whether to build debug binaries | ||
test_timeout_multiplier: | ||
description: Value to multiply with default test timeouts | ||
default: 1 | ||
required: false | ||
type: number | ||
run_slow_tests: | ||
description: Whether the unit tests should run tests marked as slow | ||
default: true | ||
required: false | ||
type: boolean | ||
runs: | ||
using: "composite" | ||
steps: | ||
- name: Run tests | ||
shell: sh | ||
working-directory: ${{ inputs.tcpdirect_tree }} | ||
env: | ||
ONLOAD_TREE: ${{ inputs.onload_tree }} | ||
NDEBUG: ${{ fromJSON(inputs.debug) && 0 || 1 }} | ||
TIMEOUT_MULTIPLIER: ${{ inputs.test_timeout_multiplier }} | ||
ZF_RUN_SLOW_TESTS: ${{ fromJSON(inputs.run_slow_tests) && 1 || 0 }} | ||
ZF_DEVEL: 1 | ||
run: UT_OUTPUT="$GITHUB_STEP_SUMMARY" make -j $(nproc) test |
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
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