Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

linux/arm64 support (including a Rust rewrite) #2261

Draft
wants to merge 153 commits into
base: master
Choose a base branch
from
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
153 commits
Select commit Hold shift + click to select a range
1ac2652
Update workflows for arm
RedstoneWizard08 Jun 23, 2023
30dd044
Prebuild image
RedstoneWizard08 Jun 23, 2023
3dba57c
XZ for glib
RedstoneWizard08 Jun 23, 2023
a7380b4
Update prebuild image
RedstoneWizard08 Jun 23, 2023
ada3551
Tag
RedstoneWizard08 Jun 23, 2023
0f50315
Updated prebuild image
RedstoneWizard08 Jun 23, 2023
47456f8
Add git
RedstoneWizard08 Jun 23, 2023
ffe65bf
FNM
RedstoneWizard08 Jun 23, 2023
682140b
Scanelf
RedstoneWizard08 Jun 23, 2023
8523d92
Why
RedstoneWizard08 Jun 23, 2023
4f1fd46
Image
RedstoneWizard08 Jun 23, 2023
ef2a2e6
Fail slow
RedstoneWizard08 Jun 23, 2023
9d03fcd
Fix PAX
RedstoneWizard08 Jun 23, 2023
94060c4
Update changelog
RedstoneWizard08 Jun 23, 2023
a26c2ff
Fix PAX problem
RedstoneWizard08 Jun 23, 2023
15d701f
Fixed node 9 bug
RedstoneWizard08 Jun 23, 2023
fb5f50f
Fix node 9
RedstoneWizard08 Jun 23, 2023
3c974da
Master tag
RedstoneWizard08 Jun 23, 2023
1c2ed11
Add hackier fix
RedstoneWizard08 Jun 23, 2023
f4fb5e6
Utility script
RedstoneWizard08 Jun 23, 2023
00bdad3
Updates for fixes
RedstoneWizard08 Jun 24, 2023
5bcba4d
Fix debian sources
RedstoneWizard08 Jun 24, 2023
afa5c54
Fix sources
RedstoneWizard08 Jun 24, 2023
8cb721f
Fix sources list
RedstoneWizard08 Jun 24, 2023
062f69f
Bookworm testing
RedstoneWizard08 Jun 24, 2023
13673a8
lddtree & squash
RedstoneWizard08 Jun 24, 2023
07d8646
Fix pax utils install
RedstoneWizard08 Jun 24, 2023
065bbc9
Python is python3
RedstoneWizard08 Jun 24, 2023
b25f486
[ci skip] Update scripts
RedstoneWizard08 Jun 24, 2023
6297dfc
pip & elftools
RedstoneWizard08 Jun 24, 2023
175eb64
pyelftools
RedstoneWizard08 Jun 24, 2023
237200f
[ci skip] Update prebuild script
RedstoneWizard08 Jun 24, 2023
3642575
Tarball fix [ci skip]
RedstoneWizard08 Jun 24, 2023
4ccab4f
Fix detect-libc
RedstoneWizard08 Jun 24, 2023
bbccada
Fix node gyp
RedstoneWizard08 Jun 24, 2023
a5f8665
[ci skip] Fix prebuild things
RedstoneWizard08 Jun 24, 2023
2689186
[ci skip] Fix ~~un~~insecure commands
RedstoneWizard08 Jun 24, 2023
d457bdf
Fix node gyp on macos?
RedstoneWizard08 Jun 24, 2023
e37cfc3
I just realized i did a stupid
RedstoneWizard08 Jun 24, 2023
eea02c9
Fix msys2?
RedstoneWizard08 Jun 24, 2023
34aa1be
Fix python3 hopefully
RedstoneWizard08 Jun 24, 2023
98ab17c
Revert build.sh change [ci skip]
RedstoneWizard08 Jun 24, 2023
9ace183
Fix python version maybe
RedstoneWizard08 Jun 24, 2023
abe0890
Fix nodegyp again
RedstoneWizard08 Jun 24, 2023
9d57f6d
Fix
RedstoneWizard08 Jun 24, 2023
bac6ff0
Fix dependency issues
RedstoneWizard08 Jun 24, 2023
4897c4e
[ci skip] Fix macos preinstall
RedstoneWizard08 Jun 24, 2023
a55fff8
Cross env compilers
RedstoneWizard08 Jun 24, 2023
f9fcf38
[ci skip] Cross env in prebuild workflow
RedstoneWizard08 Jun 24, 2023
c4c74ac
[ci skip] Apply python version for macos
RedstoneWizard08 Jun 24, 2023
dde63e9
[ci skip] Revert windows changes
RedstoneWizard08 Jun 24, 2023
21fdc03
Merging things from prebuild branch
RedstoneWizard08 Jun 24, 2023
3aa5253
[ci skip] Windows updates
RedstoneWizard08 Jun 24, 2023
b726aec
[ci skip] Fix things
RedstoneWizard08 Jun 24, 2023
f04b190
[ci skip] Fix MSYS2 ACTIONS_ALLOW_UNSECURE_COMMANDS
RedstoneWizard08 Jun 24, 2023
a6e515d
[ci skip] Fix macpack?
RedstoneWizard08 Jun 24, 2023
507dda8
[ci skip] Fix windows?
RedstoneWizard08 Jun 24, 2023
4fa140e
[ci skip] Fixing gyp in windows
RedstoneWizard08 Jun 24, 2023
4ef3a33
[ci skip] Not being stupid maybe?
RedstoneWizard08 Jun 24, 2023
391bc4a
[ci skip] Ok
RedstoneWizard08 Jun 24, 2023
c7695c1
[ci skip] Python, hello?
RedstoneWizard08 Jun 24, 2023
ea4bb92
[ci skip] MSYS2 please work
RedstoneWizard08 Jun 24, 2023
5e60c29
[ci skip] Cairo
RedstoneWizard08 Jun 24, 2023
097cb38
[ci skip] Fix msys2 again?
RedstoneWizard08 Jun 24, 2023
179887d
[ci skip] Update Windows build scripts.
RedstoneWizard08 Jun 24, 2023
65d5e32
[ci skip] Revert msys2 change
RedstoneWizard08 Jun 25, 2023
0a34817
You're kidding me, right?
RedstoneWizard08 Aug 26, 2023
be644de
Wow debian
RedstoneWizard08 Aug 26, 2023
1013c29
Thanks for changing it ever so slightly guys, real cool
RedstoneWizard08 Aug 26, 2023
a36e293
Fix libxml for the 503498509th time
RedstoneWizard08 Aug 26, 2023
704c52b
[ci skip] Remove act
RedstoneWizard08 Aug 26, 2023
c2fe7bc
Disable cross image for now
RedstoneWizard08 Aug 26, 2023
df1a6b3
Fix friggin posix sh weirdness
RedstoneWizard08 Aug 26, 2023
c907f52
Fix thing
RedstoneWizard08 Aug 26, 2023
989354d
Fix thing again
RedstoneWizard08 Aug 26, 2023
bb0cb0d
Try another method
RedstoneWizard08 Aug 26, 2023
2041c13
Fix extra dep
RedstoneWizard08 Aug 26, 2023
9ead73e
Apparently it broke it
RedstoneWizard08 Aug 26, 2023
eaf27f0
[ci skip] disable multilib
RedstoneWizard08 Aug 26, 2023
3160662
arm toolchain?
RedstoneWizard08 Aug 26, 2023
6f00014
Try with zig
RedstoneWizard08 Aug 26, 2023
b8d0671
Target
RedstoneWizard08 Aug 26, 2023
825fe66
Diagnostic
RedstoneWizard08 Aug 26, 2023
140f074
Patching!
RedstoneWizard08 Aug 26, 2023
42f2ae6
Patch v8
RedstoneWizard08 Aug 26, 2023
9f2e7c3
Fix patch script
RedstoneWizard08 Aug 26, 2023
3ce8d7f
Update zig
RedstoneWizard08 Aug 26, 2023
1799b94
Switch params
RedstoneWizard08 Aug 26, 2023
2d04c85
[ci skip] Revert binding.gyp
RedstoneWizard08 Aug 26, 2023
d757e01
Reset dir
RedstoneWizard08 Aug 26, 2023
620480a
Fix patches
RedstoneWizard08 Aug 26, 2023
23fa77f
This was a dumb idea
RedstoneWizard08 Aug 26, 2023
b5c4d5c
cmake-js?
RedstoneWizard08 Aug 26, 2023
ef7ce67
Fix an error
RedstoneWizard08 Aug 26, 2023
74a9971
I'm stupid
RedstoneWizard08 Aug 26, 2023
0df2542
Trying another idea
RedstoneWizard08 Aug 26, 2023
0287f90
Back to gyp
RedstoneWizard08 Aug 26, 2023
8e15a3d
Working on sysroot
RedstoneWizard08 Aug 26, 2023
184f379
I forgor
RedstoneWizard08 Aug 26, 2023
87ebddd
LLVM has impeccable documentation with 0 errors
RedstoneWizard08 Aug 26, 2023
6d91d95
Arm sysroot hopefully
RedstoneWizard08 Aug 26, 2023
0aaa7a1
Fix arm s ysroot for actions
RedstoneWizard08 Aug 26, 2023
21a334d
Split builds.
RedstoneWizard08 Aug 26, 2023
01555d9
It is stage0.
RedstoneWizard08 Aug 26, 2023
1495983
Stage0 doesn't need main
RedstoneWizard08 Aug 26, 2023
2acc020
Fix docker pull
RedstoneWizard08 Aug 26, 2023
cb280d7
Fix manifest creation?
RedstoneWizard08 Aug 26, 2023
0c4db99
Fix cache switching
RedstoneWizard08 Aug 26, 2023
98eb05e
Revert merge script
RedstoneWizard08 Aug 27, 2023
6eda564
I forgor login
RedstoneWizard08 Aug 27, 2023
51c26ac
Fix finish dockerfile
RedstoneWizard08 Aug 27, 2023
8d3f401
Fix finish script
RedstoneWizard08 Aug 27, 2023
f402f86
Make image build on workflow_dispatch
RedstoneWizard08 Aug 27, 2023
d3551f0
No verbose anymore
RedstoneWizard08 Aug 27, 2023
fca8a2d
More longer
RedstoneWizard08 Aug 27, 2023
b183b9b
Haha get scrapped NERD
RedstoneWizard08 Dec 12, 2023
1e5de7b
Clean
RedstoneWizard08 Dec 12, 2023
e0b2ccb
Init
RedstoneWizard08 Dec 12, 2023
7a154c5
Progress doc
RedstoneWizard08 Dec 12, 2023
698bfd1
Simplify
RedstoneWizard08 Dec 12, 2023
fc8e633
Init project
RedstoneWizard08 Dec 12, 2023
15e4c34
First completion!
RedstoneWizard08 Dec 12, 2023
0b1f6b3
Create files
RedstoneWizard08 Dec 13, 2023
b4b61cd
Low-hanging fruit
RedstoneWizard08 Dec 13, 2023
4626fc3
More low-hanging fruit
RedstoneWizard08 Dec 13, 2023
95dc955
Defaults
RedstoneWizard08 Dec 13, 2023
3881a75
napi
RedstoneWizard08 Dec 14, 2023
0c528fb
We're fine, everything's fine, and nothing was ever wrong
RedstoneWizard08 Dec 14, 2023
a45b921
Many things!
RedstoneWizard08 Dec 14, 2023
fb372dc
fix
RedstoneWizard08 Dec 14, 2023
8c98cf2
pnpm fix
RedstoneWizard08 Dec 14, 2023
733ff99
yooo
RedstoneWizard08 Dec 14, 2023
1737625
Beeg things are happening
RedstoneWizard08 Dec 14, 2023
2003f4d
yooo 68.5% done (sort of)
RedstoneWizard08 Dec 14, 2023
6c56605
createCanvas()
RedstoneWizard08 Dec 14, 2023
e53d770
Things
RedstoneWizard08 Dec 14, 2023
a254ae3
First passing test!
RedstoneWizard08 Dec 14, 2023
65a034a
Entire suite passes!
RedstoneWizard08 Dec 14, 2023
dca3f0e
I still can't understand linear algebra.
RedstoneWizard08 Dec 15, 2023
02fefca
someone please help me i am going insane
RedstoneWizard08 Dec 16, 2023
4ce1562
YOOOOOO
RedstoneWizard08 Jan 23, 2024
72aac43
translate
RedstoneWizard08 Jan 23, 2024
708076d
Rotate vec
RedstoneWizard08 Jan 23, 2024
7d586cb
Rotation is done!
RedstoneWizard08 Jan 23, 2024
7bcebbc
doc
RedstoneWizard08 Jan 23, 2024
eba7cde
skew
RedstoneWizard08 Jan 23, 2024
259cb8b
doc
RedstoneWizard08 Jan 23, 2024
d604d88
inverse & flip
RedstoneWizard08 Jan 24, 2024
c175c36
doc
RedstoneWizard08 Jan 24, 2024
e3c18dc
scale & premultiply
RedstoneWizard08 Jan 24, 2024
456d25e
*reconsiders life choices*
RedstoneWizard08 Jan 25, 2024
3e7c83f
i fixed it and it was stupid
RedstoneWizard08 Feb 5, 2024
cbf054a
More progress!
RedstoneWizard08 Feb 5, 2024
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
17 changes: 0 additions & 17 deletions .github/ISSUE_TEMPLATE.md

This file was deleted.

3 changes: 0 additions & 3 deletions .github/PULL_REQUEST_TEMPLATE.md

This file was deleted.

215 changes: 215 additions & 0 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,215 @@
name: Build
on: [push]

env:
DEBUG: "napi:*"
MACOSX_DEPLOYMENT_TARGET: "10.13"

jobs:
build:
strategy:
fail-fast: false
matrix:
targets:
[
"x86_64-apple-darwin",
"aarch64-apple-darwin",
"x86_64-pc-windows-msvc",
"i686-pc-windows-msvc",
"aarch64-pc-windows-msvc",
"x86_64-unknown-linux-gnu",
"aarch64-unknown-linux-gnu",
"x86_64-unknown-linux-musl",
"aarch64-unknown-linux-musl",
"armv7-unknown-linux-gnueabihf",
"aarch64-linux-android",
"armv7-linux-androideabi",
]
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4

- name: Install
uses: dtolnay/rust-toolchain@stable
with:
toolchain: stable
targets: ${{ matrix.targets }}

- uses: actions/setup-node@v4
with:
node-version: "18"

- uses: pnpm/action-setup@v2
name: Install pnpm
with:
version: 8
run_install: false

- name: Get pnpm store directory
shell: bash
run: |
echo "STORE_PATH=$(pnpm store path --silent)" >> $GITHUB_ENV

- uses: actions/cache@v3
name: Setup pnpm cache
with:
path: ${{ env.STORE_PATH }}
key: ${{ runner.os }}-pnpm-store-${{ hashFiles('**/pnpm-lock.yaml') }}
restore-keys: |
${{ runner.os }}-pnpm-store-

- name: Install ziglang
uses: goto-bus-stop/setup-zig@v1
with:
version: 0.11.0

- run: cargo install cargo-xwin
- run: pnpm install
- run: pnpm run gen-packages
- run: pnpm run build --target ${{ matrix.targets }}
- run: pnpm run postbuild

- uses: actions/upload-artifact@v3
with:
name: bindings-${{ matrix.targets }}
path: "*.node"
if-no-files-found: error

test-host:
strategy:
fail-fast: false
matrix:
settings:
- target: x86_64-apple-darwin
host: macos-latest
- target: x86_64-pc-windows-msvc
host: windows-latest
- target: i686-pc-windows-msvc
host: windows-latest
node: ["18", "20"]
runs-on: ${{ matrix.settings.host }}
needs:
- build
steps:
- uses: actions/checkout@v4

- uses: actions/setup-node@v4
with:
node-version: ${{ matrix.node }}

- uses: pnpm/action-setup@v2
name: Install pnpm
with:
version: 8
run_install: false

- name: Get pnpm store directory
shell: bash
run: |
echo "STORE_PATH=$(pnpm store path --silent)" >> $GITHUB_ENV

- uses: actions/cache@v3
name: Setup pnpm cache
with:
path: ${{ env.STORE_PATH }}
key: ${{ runner.os }}-pnpm-store-${{ hashFiles('**/pnpm-lock.yaml') }}
restore-keys: |
${{ runner.os }}-pnpm-store-

- name: Setup node x86
if: matrix.settings.target == 'i686-pc-windows-msvc'
run: pnpm config set cpu "ia32"
shell: bash

- name: Install dependencies
run: pnpm install

- name: Setup node x86
uses: actions/setup-node@v4
if: matrix.settings.target == 'i686-pc-windows-msvc'
with:
node-version: 18
cache: pnpm
architecture: x86

- name: Download bindings
uses: actions/download-artifact@v3
with:
name: bindings-${{ matrix.settings.target }}

- name: Run tests
run: pnpm test

test-docker:
strategy:
fail-fast: false
matrix:
settings:
- target: x86_64-unknown-linux-gnu
docker: node:18-slim
args: ""
- target: aarch64-unknown-linux-gnu
docker: node:18-slim
args: "--platform linux/arm64"
- target: x86_64-unknown-linux-musl
docker: node:18-alpine
args: ""
- target: aarch64-unknown-linux-musl
docker: node:18-alpine
args: "--platform linux/arm64"
- target: armv7-unknown-linux-gnueabihf
docker: node:18-bullseye-slim
args: "--platform linux/arm/v7"

runs-on: ubuntu-latest
needs:
- build
steps:
- uses: actions/checkout@v4

- uses: actions/setup-node@v4
with:
node-version: 18

- uses: pnpm/action-setup@v2
name: Install pnpm
with:
version: 8
run_install: false

- name: Get pnpm store directory
shell: bash
run: |
echo "STORE_PATH=$(pnpm store path --silent)" >> $GITHUB_ENV

- uses: actions/cache@v3
name: Setup pnpm cache
with:
path: ${{ env.STORE_PATH }}
key: ${{ runner.os }}-pnpm-store-${{ hashFiles('**/pnpm-lock.yaml') }}
restore-keys: |
${{ runner.os }}-pnpm-store-

- name: Install dependencies
run: pnpm install

- name: Download bindings
uses: actions/download-artifact@v3
with:
name: bindings-${{ matrix.settings.target }}

- name: Set up QEMU
uses: docker/setup-qemu-action@v3
with:
platforms: arm64,arm

- run: docker run --rm --privileged multiarch/qemu-user-static --reset -p yes

- name: Run tests
uses: addnab/docker-run-action@v3
with:
image: ${{ matrix.settings.docker }}
options: ${{ matrix.settings.args }} -v ${{ github.workspace }}:/build -w /build
run: |
set -e
pnpm test
89 changes: 0 additions & 89 deletions .github/workflows/ci.yaml

This file was deleted.

Loading