Skip to content

Commit 78e594d

Browse files
committed
feat: add aarch64 Linux builds
1 parent e74f872 commit 78e594d

File tree

4 files changed

+16
-23
lines changed

4 files changed

+16
-23
lines changed

.github/workflows/release.yml

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -152,8 +152,6 @@ jobs:
152152

153153
- name: Download artifacts
154154
uses: actions/download-artifact@v2
155-
with:
156-
name: builds
157155

158156
- name: Upload
159157
uses: softprops/action-gh-release@v1

.github/workflows/test.yml

Lines changed: 0 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -116,20 +116,3 @@ jobs:
116116
build/Release/*.so
117117
prebuilds/*
118118
retention-days: 1
119-
120-
test-deploy:
121-
name: Test Deploy
122-
permissions:
123-
contents: write
124-
packages: write
125-
needs: [ build, build-cross ]
126-
runs-on: ubuntu-latest
127-
steps:
128-
- name: Clone Repository
129-
uses: actions/checkout@v2
130-
131-
- name: Download artifacts
132-
uses: actions/download-artifact@v2
133-
134-
- name: My test
135-
run: find . -type f

deno_dist/ffi.ts

Lines changed: 8 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
// @ts-nocheck
22
/* eslint-disable */
3-
import { Plug } from "https://deno.land/x/plug@0.5.2/mod.ts";
3+
import { Plug } from "https://deno.land/x/plug@1.0.0-rc.3/mod.ts";
44
import { dirname, fromFileUrl, resolve } from "https://deno.land/std@0.158.0/path/posix.ts";
55
import { symbols } from "./symbols.ts";
66
import { Bindings } from "./bindings.ts";
@@ -92,14 +92,20 @@ export const resolveBindings: BindingsResolver = async (): Promise<Bindings> =>
9292
name: LIBNAME,
9393
url: `${REPO}/releases/download/v${VERSION}`,
9494
policy: Plug.CachePolicy.STORE,
95+
suffixes: {
96+
linux: {
97+
aarch64: ".aarch64",
98+
x86_64: ".x86_64",
99+
},
100+
},
95101
}, symbols);
96102
} else {
97103
const importDir = dirname(fromFileUrl(import.meta.url));
98104
const buildDir = resolve(importDir, "..", "build");
99105
const filename = {
100106
windows: `${buildDir}/Release/${LIBNAME}.dll`,
101107
darwin: `${buildDir}/Release/lib${LIBNAME}.dylib`,
102-
linux: `${buildDir}/Release/lib${LIBNAME}.so`,
108+
linux: `${buildDir}/Release/lib${LIBNAME}.${Deno.build.arch}.so`,
103109
}[Deno.build.os];
104110
lib = Deno.dlopen(filename, symbols);
105111
}

src/ffi.deno.ts

Lines changed: 8 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
// @ts-nocheck
22
/* eslint-disable */
3-
import { Plug } from "https://deno.land/x/plug@0.5.2/mod.ts";
3+
import { Plug } from "https://deno.land/x/plug@1.0.0-rc.3/mod.ts";
44
import { dirname, fromFileUrl, resolve } from "https://deno.land/std@0.158.0/path/posix.ts";
55
import { symbols } from "./symbols.ts";
66
import { Bindings } from "./bindings.ts";
@@ -92,14 +92,20 @@ export const resolveBindings: BindingsResolver = async (): Promise<Bindings> =>
9292
name: LIBNAME,
9393
url: `${REPO}/releases/download/v${VERSION}`,
9494
policy: Plug.CachePolicy.STORE,
95+
suffixes: {
96+
linux: {
97+
aarch64: ".aarch64",
98+
x86_64: ".x86_64",
99+
},
100+
},
95101
}, symbols);
96102
} else {
97103
const importDir = dirname(fromFileUrl(import.meta.url));
98104
const buildDir = resolve(importDir, "..", "build");
99105
const filename = {
100106
windows: `${buildDir}/Release/${LIBNAME}.dll`,
101107
darwin: `${buildDir}/Release/lib${LIBNAME}.dylib`,
102-
linux: `${buildDir}/Release/lib${LIBNAME}.so`,
108+
linux: `${buildDir}/Release/lib${LIBNAME}.${Deno.build.arch}.so`,
103109
}[Deno.build.os];
104110
lib = Deno.dlopen(filename, symbols);
105111
}

0 commit comments

Comments
 (0)