Skip to content

Commit 98e6c61

Browse files
authored
Merge pull request #157 from vlcn-io/prebuild
prebuild binaries for win, mac, linux x86_64 & arm64
2 parents f004009 + 9fc9f54 commit 98e6c61

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

48 files changed

+770
-1136
lines changed

.github/workflows/c-valgrind.yaml

Lines changed: 2 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -23,15 +23,10 @@ jobs:
2323
rustup default nightly
2424
rustup update
2525
26-
- name: Build Tests
27-
run: |
28-
cd core
29-
make dist/test
30-
3126
- name: Install valgrind
3227
run: sudo apt install -y valgrind
3328

34-
- name: Run Valgrind
29+
- name: Valgrind Test
3530
run: |
3631
cd core
37-
valgrind dist/test
32+
make valgrind

.github/workflows/js-tests.yaml

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,4 @@
11
on:
2-
push:
32
pull_request:
43
types: [opened, edited]
54
name: "js-tests"

.github/workflows/publish.yaml

Lines changed: 127 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,127 @@
1+
name: publish
2+
3+
on:
4+
push:
5+
tags:
6+
- "v*"
7+
- "prebuild-test.*"
8+
9+
jobs:
10+
prebuild:
11+
name: Prebuild for ${{ matrix.os }}
12+
runs-on: ${{ matrix.os }}
13+
strategy:
14+
fail-fast: false
15+
matrix:
16+
include:
17+
- os: ubuntu-latest
18+
artifact_name: crsqlite.so
19+
asset_name: crsqlite-linux-x86_64.so
20+
- os: windows-latest
21+
artifact_name: crsqlite.dll
22+
asset_name: crsqlite-windows-x86_64.dll
23+
- os: macos-latest
24+
artifact_name: crsqlite.dylib
25+
asset_name: crsqlite-darwin-x86_64.dylib
26+
27+
steps:
28+
- uses: actions/checkout@v3
29+
with:
30+
submodules: true
31+
32+
- name: Rust Nightly
33+
run: |
34+
rustup default nightly
35+
rustup update
36+
37+
- name: Windows rust toolchain
38+
if: runner.os == 'Windows'
39+
run: |
40+
rustup component add rust-src --toolchain nightly-x86_64-pc-windows-gnu
41+
rustup default nightly-x86_64-pc-windows-gnu
42+
43+
- name: Build
44+
run: |
45+
cd core
46+
make loadable
47+
48+
- name: Upload binaries to release
49+
uses: svenstaro/upload-release-action@v2
50+
with:
51+
repo_token: ${{ secrets.GITHUB_TOKEN }}
52+
file: core/dist/${{ matrix.artifact_name }}
53+
asset_name: ${{ matrix.asset_name }}
54+
tag: ${{ github.ref }}
55+
56+
# we can probably collapse all these into the prebuild job
57+
prebuild-macos-arm:
58+
name: Prebuild for macos arm
59+
runs-on: ${{ matrix.os }}
60+
strategy:
61+
matrix:
62+
include:
63+
- os: macos-latest
64+
artifact_name: crsqlite.dylib
65+
asset_name: crsqlite-darwin-aarch64.dylib
66+
67+
steps:
68+
- uses: actions/checkout@v3
69+
with:
70+
submodules: true
71+
72+
- name: Rust Nightly
73+
run: |
74+
rustup default nightly
75+
rustup update
76+
rustup target add aarch64-apple-darwin
77+
78+
- name: Build
79+
run: |
80+
cd core
81+
export CI_MAYBE_TARGET="aarch64-apple-darwin" && make loadable
82+
83+
- name: Upload binaries to release
84+
uses: svenstaro/upload-release-action@v2
85+
with:
86+
repo_token: ${{ secrets.GITHUB_TOKEN }}
87+
file: core/dist/${{ matrix.artifact_name }}
88+
asset_name: ${{ matrix.asset_name }}
89+
tag: ${{ github.ref }}
90+
91+
prebuild-linux-arm:
92+
name: Prebuild for linux arm
93+
runs-on: ${{ matrix.os }}
94+
strategy:
95+
matrix:
96+
include:
97+
- os: ubuntu-latest
98+
artifact_name: crsqlite.so
99+
asset_name: crsqlite-linux-aarch64.so
100+
101+
steps:
102+
- name: Install toolchain
103+
run: |
104+
sudo apt install -y gcc make gcc-aarch64-linux-gnu binutils-aarch64-linux-gnu
105+
106+
- uses: actions/checkout@v3
107+
with:
108+
submodules: true
109+
110+
- name: Rust Nightly
111+
run: |
112+
rustup default nightly
113+
rustup update
114+
rustup target add aarch64-unknown-linux-gnu
115+
116+
- name: Build
117+
run: |
118+
cd core
119+
export CI_MAYBE_TARGET="aarch64-unknown-linux-gnu" && export CI_GCC="aarch64-linux-gnu-gcc" && make loadable
120+
121+
- name: Upload binaries to release
122+
uses: svenstaro/upload-release-action@v2
123+
with:
124+
repo_token: ${{ secrets.GITHUB_TOKEN }}
125+
file: core/dist/${{ matrix.artifact_name }}
126+
asset_name: ${{ matrix.asset_name }}
127+
tag: ${{ github.ref }}

.github/workflows/py-tests.yaml

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,4 @@
11
on:
2-
push:
32
pull_request:
43
types: [opened, edited]
54
name: "py-tests"

.github/workflows/release.js

Lines changed: 0 additions & 34 deletions
This file was deleted.

.github/workflows/release.yaml

Lines changed: 0 additions & 81 deletions
This file was deleted.

core/CHANGELOG.md

Lines changed: 29 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,34 @@
11
# @vlcn.io/crsqlite
22

3+
## 0.8.0
4+
5+
### Minor Changes
6+
7+
- 6316ec315: update to support prebuild binaries, include primary key only table fixes
8+
9+
### Patch Changes
10+
11+
- b7e0b21df: create dist dir on install
12+
- 606060dbe: include install script
13+
14+
## 0.8.0-next.2
15+
16+
### Patch Changes
17+
18+
- create dist dir on install
19+
20+
## 0.8.0-next.1
21+
22+
### Patch Changes
23+
24+
- include install script
25+
26+
## 0.8.0-next.0
27+
28+
### Minor Changes
29+
30+
- update to support prebuild binaries, include primary key only table fixes
31+
332
## 0.7.2
433

534
### Patch Changes

0 commit comments

Comments
 (0)