Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
55 commits
Select commit Hold shift + click to select a range
cfe4db4
add --zig flag
matthme Jan 27, 2025
67078f9
add aarch64 to setup zig step
matthme Jan 27, 2025
92bface
echo zig
matthme Jan 28, 2025
9732be9
add install zig command
matthme Jan 28, 2025
0affdb5
install zig from snap
matthme Jan 28, 2025
8c55e54
add zig installation step
matthme Jan 28, 2025
3d2e49f
add logging
matthme Jan 28, 2025
6e335cc
pwd
matthme Jan 28, 2025
4ee626e
change path
matthme Jan 28, 2025
47a4258
merge main
matthme May 12, 2025
497dbd8
removed conductor config generation file and holochain_conductor_api …
matthme May 12, 2025
a1ddb7f
remove unused holochain_p2p dependency
matthme May 12, 2025
ea12692
use --zig flag
matthme May 12, 2025
cdb3d3b
add setup zig step
matthme May 12, 2025
a258da4
add logic to install zig in docker container
matthme May 12, 2025
225d515
use bash shell
matthme May 12, 2025
b6a9d3d
export
matthme May 12, 2025
cbeef86
fix path
matthme May 12, 2025
81a5939
add uname
matthme May 12, 2025
faec4ee
change to x86_64 zig
matthme May 12, 2025
6ebf080
added abi suffix
matthme May 12, 2025
c32a384
change abi suffix
matthme May 12, 2025
6503e32
remove zig
matthme May 12, 2025
173ef53
download libsodium and add SODIUM_DIST_DIR variable
matthme May 12, 2025
21c8cfb
fix env variable
matthme May 12, 2025
60eec08
change to SODIUM_LIB_DIR
matthme May 12, 2025
4a8b16b
add --zig to package.json
matthme May 12, 2025
4eff207
add step to print config.log
matthme Jun 17, 2025
41220d6
build outside docker
matthme Jun 17, 2025
68f86fe
remove --zig flag
matthme Jun 17, 2025
62f8dbe
change zig path export
matthme Jun 17, 2025
078c97c
add --zig flag
matthme Jun 17, 2025
b9c02e4
back inside docker
matthme Jun 17, 2025
06bdebc
add --zig to build command
matthme Jun 17, 2025
1feeeeb
change to SODIUM_LIB_DIR
matthme Jun 17, 2025
76bde7c
no docker
matthme Jun 17, 2025
04e78ff
comment out wrong command
matthme Jun 17, 2025
72f599f
add docker
matthme Jun 17, 2025
f92199a
change to aarch64 zig
matthme Jun 17, 2025
920e82c
no docker
matthme Jun 17, 2025
0e6f6ff
add linker env arg
matthme Jun 17, 2025
72053d6
install gcc
matthme Jun 17, 2025
d9069fb
add binding test
matthme Jun 17, 2025
3bfa490
without dist dir
matthme Jun 17, 2025
9dda234
back to normal
matthme Jun 17, 2025
7665659
cleanup
matthme Jun 17, 2025
5d7a964
remove branch
matthme Jun 17, 2025
e2ec1a2
add npm folder for aarch64
matthme Jun 17, 2025
b280ce2
temporarily remove test depdendency
matthme Jun 17, 2025
0e8ada6
change order
matthme Jun 17, 2025
60a8064
add push
matthme Jun 17, 2025
fb0a9a0
add triple to package.json
matthme Jun 17, 2025
55162d7
cleanup again
matthme Jun 17, 2025
bbb9945
change to on push
matthme Jun 17, 2025
49fb1d5
remove push rule
matthme Jun 17, 2025
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
119 changes: 69 additions & 50 deletions .github/workflows/CI.yml
Original file line number Diff line number Diff line change
Expand Up @@ -44,16 +44,37 @@ jobs:
build: |
yarn build --target aarch64-apple-darwin
strip -x *.node
# - host: ubuntu-latest
# target: aarch64-unknown-linux-gnu
# docker: ghcr.io/napi-rs/napi-rs/nodejs-rust:lts-debian-aarch64
# build: yarn build --target aarch64-unknown-linux-gnu
- host: ubuntu-latest
target: aarch64-unknown-linux-gnu
# docker: ghcr.io/napi-rs/napi-rs/nodejs-rust:lts-debian-aarch64
build: |
# We don't actually need zig currently
# curl --output zig-linux-x86_64-0.13.0.tar.xz https://ziglang.org/download/0.13.0/zig-linux-x86_64-0.13.0.tar.xz
# tar xf zig-linux-x86_64-0.13.0.tar.xz
# export PATH=$PATH:$(pwd)/zig-linux-x86_64-0.13.0
# zig version

# install gcc compiler for aarch64
sudo apt update
sudo apt install gcc-aarch64-linux-gnu

aarch64-linux-gnu-gcc --version

# Download libsodium
mkdir libsodium
curl -L --output ./libsodium/LATEST.tar.gz https://github.com/matthme/holochain-binaries/releases/download/libsodium-releases/LATEST.tar.gz
curl -L --output ./libsodium/LATEST.tar.gz.minisig https://github.com/matthme/holochain-binaries/releases/download/libsodium-releases/LATEST.tar.gz.minisig
curl -L --output ./libsodium/libsodium-1.0.19-stable.zip https://github.com/matthme/holochain-binaries/releases/download/libsodium-releases/libsodium-1.0.19-stable.zip
curl -L --output ./libsodium/libsodium-1.0.19-stable.zip.minisig https://github.com/matthme/holochain-binaries/releases/download/libsodium-releases/libsodium-1.0.19-stable.zip.minisig

CARGO_TARGET_AARCH64_UNKNOWN_LINUX_GNU_LINKER=aarch64-linux-gnu-gcc SODIUM_DIST_DIR="$(pwd)/libsodium" yarn build --target aarch64-unknown-linux-gnu

# - host: ubuntu-latest
# target: armv7-unknown-linux-gnueabihf
# setup: |
# sudo apt-get update
# sudo apt-get install gcc-arm-linux-gnueabihf -y
# build: yarn build --target armv7-unknown-linux-gnueabihf
# build: yarn build --zig --target armv7-unknown-linux-gnueabihf

name: stable - ${{ matrix.settings.target }} - node@20
runs-on: ${{ matrix.settings.host }}
Expand Down Expand Up @@ -90,11 +111,6 @@ jobs:
with:
go-version: 'stable'

# - uses: goto-bus-stop/setup-zig@v2
# if: ${{ matrix.settings.target == 'armv7-unknown-linux-gnueabihf' || matrix.settings.target == 'armv7-unknown-linux-musleabihf' }}
# with:
# version: 0.11.0

- name: Setup toolchain
run: ${{ matrix.settings.setup }}
if: ${{ matrix.settings.setup }}
Expand Down Expand Up @@ -212,47 +228,49 @@ jobs:
- name: Test bindings
run: docker run --rm -v $(pwd):/build -w /build node:${{ matrix.node }}-slim yarn test

# test-linux-aarch64-gnu-binding:
# name: Test bindings on aarch64-unknown-linux-gnu - node@${{ matrix.node }}
# needs:
# - build
# strategy:
# fail-fast: false
# matrix:
# node:
# - '18'
# - '20'
# runs-on: ubuntu-latest
# steps:
# - uses: actions/checkout@v4
# - name: Download artifacts
# uses: actions/download-artifact@v4
# with:
# name: bindings-aarch64-unknown-linux-gnu
# path: .
# - name: List packages
# run: ls -R .
# shell: bash
# - name: Install dependencies
# run: |
# yarn config set supportedArchitectures.cpu "arm64"
# yarn config set supportedArchitectures.libc "glibc"
# yarn install
# - name: Set up QEMU
# uses: docker/setup-qemu-action@v3
# with:
# platforms: arm64
# - run: docker run --rm --privileged multiarch/qemu-user-static --reset -p yes
# - name: Setup and run tests
# uses: addnab/docker-run-action@v3
# with:
# image: node:${{ matrix.node }}-slim
# options: '--platform linux/arm64 -v ${{ github.workspace }}:/build -w /build'
# run: |
# set -e
# yarn test
# ls -la
test-linux-aarch64-gnu-binding:
name: Test bindings on aarch64-unknown-linux-gnu - node@${{ matrix.node }}
needs:
- build
strategy:
fail-fast: false
matrix:
node:
- '18'
- '20'
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Download artifacts
uses: actions/download-artifact@v4
with:
name: bindings-aarch64-unknown-linux-gnu
path: .
- name: List packages
run: ls -R .
shell: bash
- name: Install dependencies
run: |
yarn config set supportedArchitectures.cpu "arm64"
yarn config set supportedArchitectures.libc "glibc"
yarn install
- name: Set up QEMU
uses: docker/setup-qemu-action@v3
with:
platforms: arm64
- run: docker run --rm --privileged multiarch/qemu-user-static --reset -p yes
- name: Setup and run tests
uses: addnab/docker-run-action@v3
with:
image: node:${{ matrix.node }}-slim
options: '--platform linux/arm64 -v ${{ github.workspace }}:/build -w /build'
run: |
set -e
yarn test
ls -la

# Adding this will also require adding an npm folder and adding the target triple to the
# root package.json: https://github.com/napi-rs/napi-rs/issues/1545
# test-linux-arm-gnueabihf-binding:
# name: Test bindings on armv7-unknown-linux-gnueabihf - node@${{ matrix.node }}
# needs:
Expand Down Expand Up @@ -299,6 +317,7 @@ jobs:
needs:
- test-macOS-windows-binding
- test-linux-x64-gnu-binding
- test-linux-aarch64-gnu-binding
steps:
- uses: actions/checkout@v4
- name: Setup node
Expand Down
Loading
Loading