Skip to content

Commit 352497c

Browse files
authored
Remove pinned cudaq_realtime_version (#561)
- Remove `.cudaq_realtime_version` in favor of `.cudaq_version` - Add logging to indicate the chosen CUDA-Q version in the `get-cudaq-version` action Signed-off-by: Angela Burton <angelab@nvidia.com>
1 parent 008a3d2 commit 352497c

4 files changed

Lines changed: 14 additions & 15 deletions

File tree

.cudaq_realtime_version

Lines changed: 0 additions & 6 deletions
This file was deleted.

.github/actions/build-lib/build_qec.sh

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -10,17 +10,17 @@ cudaq_prefix=$3
1010
# Build cuda-quantum realtime library + hololink tools (if CUDAQ_REALTIME_ROOT not set)
1111
if [ -z "$CUDAQ_REALTIME_ROOT" ]; then
1212
CUDAQ_REALTIME_ROOT=/tmp/cudaq-realtime
13-
CUDAQ_REALTIME_REPO=https://github.com/NVIDIA/cuda-quantum.git
14-
CUDAQ_REALTIME_REF=$(jq -r '.cudaq_realtime.ref' .cudaq_realtime_version)
13+
CUDAQ_REPO=$(jq -r '.cudaq.repository' .cudaq_version)
14+
CUDAQ_REF=$(jq -r '.cudaq.ref' .cudaq_version)
1515
_build_cwd=$(pwd)
1616

1717
cd /tmp
1818
rm -rf cudaq-realtime-src $CUDAQ_REALTIME_ROOT
19-
git clone --filter=blob:none --no-checkout $CUDAQ_REALTIME_REPO cudaq-realtime-src
19+
git clone --filter=blob:none --no-checkout https://github.com/${CUDAQ_REPO}.git cudaq-realtime-src
2020
cd cudaq-realtime-src
2121
git sparse-checkout init --cone
2222
git sparse-checkout set realtime
23-
git checkout $CUDAQ_REALTIME_REF
23+
git checkout $CUDAQ_REF
2424

2525
# Install build tools and DOCA/Holoscan SDK for HSB.
2626
# The cudaqx CI container has Mellanox OFED pre-installed, so we cannot use

.github/actions/get-cudaq-version/action.yaml

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11
name: Get CUDAQ version
2+
description: Read the pinned CUDA-Q repository and ref from .cudaq_version
23

34
outputs:
45
repo:
@@ -30,8 +31,8 @@ runs:
3031
run: |
3132
repo=$(jq -r '.cudaq.repository' .cudaq_version)
3233
ref=$(jq -r '.cudaq.ref' .cudaq_version)
34+
echo "Using CUDA-Q version: ${repo}@${ref}"
3335
echo "repo=$repo" >> $GITHUB_OUTPUT
3436
echo "ref=$ref" >> $GITHUB_OUTPUT
3537
shell: bash
3638

37-

.github/workflows/all_libs_release.yaml

Lines changed: 8 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -99,18 +99,22 @@ jobs:
9999
# Build cuda-quantum realtime (base library, no Hololink tools)
100100
# ========================================================================
101101

102+
- name: Get required CUDAQ version
103+
id: get-cudaq-version
104+
uses: ./.github/actions/get-cudaq-version
105+
102106
- name: Build cuda-quantum realtime
103107
run: |
104-
CUDAQ_REALTIME_REPO=https://github.com/NVIDIA/cuda-quantum.git
105-
CUDAQ_REALTIME_REF=$(jq -r '.cudaq_realtime.ref' .cudaq_realtime_version)
108+
CUDAQ_REPO="${{ steps.get-cudaq-version.outputs.repo }}"
109+
CUDAQ_REF="${{ steps.get-cudaq-version.outputs.ref }}"
106110
CUDAQ_REALTIME_ROOT=/tmp/cudaq-realtime
107111
cd /tmp
108112
rm -rf cudaq-realtime-src $CUDAQ_REALTIME_ROOT
109-
git clone --filter=blob:none --no-checkout $CUDAQ_REALTIME_REPO cudaq-realtime-src
113+
git clone --filter=blob:none --no-checkout "https://github.com/${CUDAQ_REPO}.git" cudaq-realtime-src
110114
cd cudaq-realtime-src
111115
git sparse-checkout init --cone
112116
git sparse-checkout set realtime
113-
git checkout $CUDAQ_REALTIME_REF
117+
git checkout "$CUDAQ_REF"
114118
cd realtime && mkdir -p build && cd build
115119
cmake -G Ninja -DCMAKE_INSTALL_PREFIX=$CUDAQ_REALTIME_ROOT ..
116120
ninja && ninja install

0 commit comments

Comments
 (0)