Skip to content

Linux

Linux #78

name: Linux
on:
schedule:
- cron: "0 8 * * *"
workflow_dispatch:
jobs:
update:
name: Linux
runs-on: ubuntu-latest
strategy:
matrix:
arch: [amd64, arm64]
include:
- arch: arm64
is_arm: true
# container:
# image: ubuntu:devel
steps:
# - name: Update system
# run: apt-get update && apt-get install -y sudo
- name: Setup ccache
uses: actions/cache@v4
with:
key: ${{ github.workflow }}-${{ matrix.arch }}
path: .ccache
- uses: pguyot/arm-runner-action@v2
with:
base_image: https://dietpi.com/downloads/images/testing/DietPi_RPi5-ARMv8-Bookworm.img.xz
image_additional_mb: 10240
commands: |
ls ./
ls ./libnode-distributable
ls ../
ls ../libnode-distributable
export CC="ccache gcc"
export CXX="ccache g++"
apt-get update
apt-get install --yes ca-certificates curl gnupg && curl -sL https://deb.nodesource.com/setup_21.x | bash - && apt-get update
apt-get install --yes git python3 python3-pip gcc g++ make linux-headers-generic build-essential binutils libz-dev linux-libc-dev ccache ninja-build nodejs
git clone https://github.com/devraymondsh/libnode-distributable
ARCH=arm64 cd libnode-distributable && node index.js
# - name: Install Nodejs 21 repo
# run: apt-get install --yes ca-certificates curl gnupg && curl -sL https://deb.nodesource.com/setup_21.x | bash - && apt-get update
# - name: Install building tools
# run: apt-get install --yes git python3 python3-pip gcc g++ make linux-headers-generic build-essential binutils libz-dev linux-libc-dev ccache ninja-build nodejs
# - if: ${{ matrix.is_arm }}
# name: Install cross platform building tools
# run: apt-get install --yes crossbuild-essential-arm64 linux-libc-dev-arm64-cross binutils-aarch64-linux-gnu gcc-aarch64-linux-gnu g++-aarch64-linux-gnu
# - name: Clone the repo
# run: git clone https://github.com/devraymondsh/libnode-distributable
# # - if: ${{ ! matrix.is_arm }}
# - name: Run ccache-cache
# uses: hendrikmuhs/[email protected]
# with:
# create-symlink: true
# key: ${{ github.workflow }}-${{ matrix.arch }}
# - name: Run the script
# env:
# CC: "gcc"
# CXX: "g++"
# ARCH: ${{ matrix.arch }}
# run: cd libnode-distributable && node index.js
# - name: Find the shared library
# run: find libnode-distributable/node -name libnode.so\* -not -name '*.TOC' -not -name '*.toc' -exec ls {} \;