Skip to content

Commit

Permalink
Restore support for CPUs without AES-NI support
Browse files Browse the repository at this point in the history
  • Loading branch information
nazar-pc committed Nov 13, 2024
1 parent 96cb482 commit 206c0bf
Show file tree
Hide file tree
Showing 5 changed files with 8 additions and 4 deletions.
4 changes: 4 additions & 0 deletions .github/workflows/snapshot-build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -106,9 +106,13 @@ jobs:
ARTIFACT="${{ matrix.build.base-artifact }}"
docker run --rm --platform linux/amd64 --entrypoint /bin/cat $IMAGE /$ARTIFACT > $ARTIFACT-ubuntu-x86_64-skylake-${{ github.ref_name }}
# TODO: Pull is a workaround for https://github.com/moby/moby/issues/48197#issuecomment-2472265028
docker pull --platform linux/amd64/v2 $IMAGE
docker run --rm --platform linux/amd64/v2 --entrypoint /bin/cat $IMAGE /$ARTIFACT > $ARTIFACT-ubuntu-x86_64-v2-${{ github.ref_name }}
if [ "${{ matrix.build.image }}" == "farmer" ]; then
docker run --rm --platform linux/amd64 --entrypoint /bin/cat $IMAGE /$ARTIFACT-rocm > $ARTIFACT-rocm-ubuntu-x86_64-skylake-${{ github.ref_name }}
# TODO: Pull is a workaround for https://github.com/moby/moby/issues/48197#issuecomment-2472265028
docker pull --platform linux/amd64/v2 $IMAGE
docker run --rm --platform linux/amd64/v2 --entrypoint /bin/cat $IMAGE /$ARTIFACT-rocm > $ARTIFACT-rocm-ubuntu-x86_64-v2-${{ github.ref_name }}
fi
docker run --rm --platform linux/arm64 --entrypoint /bin/cat $IMAGE /$ARTIFACT > $ARTIFACT-ubuntu-aarch64-${{ github.ref_name }}
Expand Down
2 changes: 1 addition & 1 deletion docker/bootstrap-node.Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -78,7 +78,7 @@ RUN \
if [ $TARGETARCH = "amd64" ] && [ "$RUSTFLAGS" = ""]; then \
case "$TARGETVARIANT" in \
# x86-64-v2 with AES-NI
"v2") export RUSTFLAGS="-C target-cpu=x86-64-v2 -C target-feature=+aes" ;; \
"v2") export RUSTFLAGS="-C target-cpu=x86-64-v2" ;; \
# x86-64-v3 with AES-NI
"v3") export RUSTFLAGS="-C target-cpu=x86-64-v3 -C target-feature=+aes" ;; \
# v4 is compiled for Zen 4+
Expand Down
2 changes: 1 addition & 1 deletion docker/farmer.Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -117,7 +117,7 @@ RUN \
if [ $TARGETARCH = "amd64" ] && [ "$RUSTFLAGS" = "" ]; then \
case "$TARGETVARIANT" in \
# x86-64-v2 with AES-NI
"v2") export RUSTFLAGS="-C target-cpu=x86-64-v2 -C target-feature=+aes" ;; \
"v2") export RUSTFLAGS="-C target-cpu=x86-64-v2" ;; \
# x86-64-v3 with AES-NI
"v3") export RUSTFLAGS="-C target-cpu=x86-64-v3 -C target-feature=+aes" ;; \
# v4 is compiled for Zen 4+
Expand Down
2 changes: 1 addition & 1 deletion docker/node.Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -79,7 +79,7 @@ RUN \
if [ $TARGETARCH = "amd64" ] && [ "$RUSTFLAGS" = ""]; then \
case "$TARGETVARIANT" in \
# x86-64-v2 with AES-NI
"v2") export RUSTFLAGS="-C target-cpu=x86-64-v2 -C target-feature=+aes" ;; \
"v2") export RUSTFLAGS="-C target-cpu=x86-64-v2" ;; \
# x86-64-v3 with AES-NI
"v3") export RUSTFLAGS="-C target-cpu=x86-64-v3 -C target-feature=+aes" ;; \
# v4 is compiled for Zen 4+
Expand Down
2 changes: 1 addition & 1 deletion docker/runtime.Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -78,7 +78,7 @@ RUN \
if [ $TARGETARCH = "amd64" ] && [ "$RUSTFLAGS" = ""]; then \
case "$TARGETVARIANT" in \
# x86-64-v2 with AES-NI
"v2") export RUSTFLAGS="-C target-cpu=x86-64-v2 -C target-feature=+aes" ;; \
"v2") export RUSTFLAGS="-C target-cpu=x86-64-v2" ;; \
# x86-64-v3 with AES-NI
"v3") export RUSTFLAGS="-C target-cpu=x86-64-v3 -C target-feature=+aes" ;; \
# v4 is compiled for Zen 4+
Expand Down

0 comments on commit 206c0bf

Please sign in to comment.