From 59d5b51d4172189f93dbfcfce55f1613c4ec2ceb Mon Sep 17 00:00:00 2001 From: Joel Smith <140545543+joelsmithTT@users.noreply.github.com> Date: Sat, 23 Nov 2024 13:36:17 -0600 Subject: [PATCH] Build ubench in CI (#305) ### Issue N/A ### Description tests/microbenchmark wasn't getting built by CI ### List of the changes modify CI yaml to build it with the unit tests ### Testing Builds locally, CI test pending ### API Changes There are no API changes in this PR. --- .github/workflows/build-tests.yml | 6 +++--- tests/CMakeLists.txt | 4 +--- 2 files changed, 4 insertions(+), 6 deletions(-) diff --git a/.github/workflows/build-tests.yml b/.github/workflows/build-tests.yml index 3916e4bf..1ed36a85 100644 --- a/.github/workflows/build-tests.yml +++ b/.github/workflows/build-tests.yml @@ -28,7 +28,7 @@ on: env: - BUILD_TARGET: umd_tests + BUILD_TARGETS: "umd_tests ubench" BUILD_OUTPUT_DIR: ./build LIB_OUTPUT_DIR: ./build/lib DEPS_OUTPUT_DIR: ./build/_deps @@ -62,11 +62,11 @@ jobs: submodules: recursive lfs: 'true' - - name: Build ${{ env.BUILD_TARGET }} + - name: Build ${{ env.BUILD_TARGETS }} run: | echo "Compiling the code..." cmake -B ${{ env.BUILD_OUTPUT_DIR }} -G Ninja -DTT_UMD_BUILD_TESTS=ON - cmake --build ${{ env.BUILD_OUTPUT_DIR }} --target ${{ env.BUILD_TARGET }} + cmake --build ${{ env.BUILD_OUTPUT_DIR }} --target ${{ env.BUILD_TARGETS }} echo "Compile complete." # This is needed to preserve file permissions diff --git a/tests/CMakeLists.txt b/tests/CMakeLists.txt index f7524f36..b24e19ea 100644 --- a/tests/CMakeLists.txt +++ b/tests/CMakeLists.txt @@ -58,9 +58,7 @@ else() include_directories("${CMAKE_CURRENT_BINARY_DIR}/$ENV{ARCH_NAME}") endif() -if(MASTER_PROJECT) - add_subdirectory(${CMAKE_CURRENT_SOURCE_DIR}/microbenchmark) -endif() +add_subdirectory(${CMAKE_CURRENT_SOURCE_DIR}/microbenchmark) add_subdirectory(${CMAKE_CURRENT_SOURCE_DIR}/api) add_subdirectory(${CMAKE_CURRENT_SOURCE_DIR}/pcie) add_subdirectory(${CMAKE_CURRENT_SOURCE_DIR}/simulation)