mirror of
https://github.com/lancedb/lancedb.git
synced 2026-05-17 20:10:39 +00:00
ci: refactor node releases (#2223)
This PR fixes build issues associated with `aws-lc-rs`, while simplifying the build process. Previously, we used custom scripts for the musl and Windows ARM builds. These were complicated and prone to breaking. This PR switches to a setup that mirrors https://github.com/napi-rs/package-template/blob/main/.github/workflows/CI.yml. * linux glibc and musl builds now use the Docker images provided by the napi project * Windows ARM build now just cross compiles from Windows x64, which turns out to work quite well.
This commit is contained in:
@@ -22,3 +22,4 @@ build.rs
|
||||
jest.config.js
|
||||
tsconfig.json
|
||||
typedoc.json
|
||||
typedoc_post_process.js
|
||||
|
||||
@@ -18,7 +18,7 @@ arrow-array.workspace = true
|
||||
arrow-schema.workspace = true
|
||||
env_logger.workspace = true
|
||||
futures.workspace = true
|
||||
lancedb = { path = "../rust/lancedb", features = ["remote"] }
|
||||
lancedb = { path = "../rust/lancedb" }
|
||||
napi = { version = "2.16.8", default-features = false, features = [
|
||||
"napi9",
|
||||
"async"
|
||||
@@ -30,3 +30,8 @@ log.workspace = true
|
||||
|
||||
[build-dependencies]
|
||||
napi-build = "2.1"
|
||||
|
||||
[features]
|
||||
default = ["remote"]
|
||||
fp16kernels = ["lancedb/fp16kernels"]
|
||||
remote = ["lancedb/remote"]
|
||||
|
||||
@@ -11,11 +11,9 @@ npm install @lancedb/lancedb
|
||||
This will download the appropriate native library for your platform. We currently
|
||||
support:
|
||||
|
||||
- Linux (x86_64 and aarch64)
|
||||
- Linux (x86_64 and aarch64 on glibc and musl)
|
||||
- MacOS (Intel and ARM/M1/M2)
|
||||
- Windows (x86_64 only)
|
||||
|
||||
We do not yet support musl-based Linux (such as Alpine Linux) or aarch64 Windows.
|
||||
- Windows (x86_64 and aarch64)
|
||||
|
||||
## Usage
|
||||
|
||||
|
||||
@@ -29,7 +29,6 @@
|
||||
"aarch64-apple-darwin",
|
||||
"x86_64-unknown-linux-gnu",
|
||||
"aarch64-unknown-linux-gnu",
|
||||
"x86_64-unknown-linux-musl",
|
||||
"aarch64-unknown-linux-musl",
|
||||
"x86_64-pc-windows-msvc",
|
||||
"aarch64-pc-windows-msvc"
|
||||
@@ -74,8 +73,10 @@
|
||||
"artifacts": "napi artifacts",
|
||||
"build:debug": "napi build --platform --no-const-enum --dts ../lancedb/native.d.ts --js ../lancedb/native.js lancedb",
|
||||
"build:release": "napi build --platform --no-const-enum --release --dts ../lancedb/native.d.ts --js ../lancedb/native.js dist/",
|
||||
"build": "npm run build:debug && tsc -b && shx cp lancedb/native.d.ts dist/native.d.ts && shx cp lancedb/*.node dist/",
|
||||
"build-release": "npm run build:release && tsc -b && shx cp lancedb/native.d.ts dist/native.d.ts",
|
||||
"build": "npm run build:debug && npm run tsc && shx cp lancedb/*.node dist/",
|
||||
"build-release": "npm run build:release && npm run tsc",
|
||||
"tsc": "tsc -b",
|
||||
"posttsc": "shx cp lancedb/native.d.ts dist/native.d.ts",
|
||||
"lint-ci": "biome ci .",
|
||||
"docs": "typedoc --plugin typedoc-plugin-markdown --treatWarningsAsErrors --out ../docs/src/js lancedb/index.ts",
|
||||
"postdocs": "node typedoc_post_process.js",
|
||||
|
||||
Reference in New Issue
Block a user