mirror of
https://github.com/lights0123/n-link.git
synced 2026-10-30 21:35:59 +00:00
- Correct the vendored libnspire-sys retry limit in spec and plan: the
actual constant in vendor/libnspire-sys/libnspire/src/cx2.cpp:391 is 30,
not 100. The '10 -> 100' claim originated in nlink-cli's own Cargo.toml
comment and was propagated into both documents unverified.
- Drop @tauri-apps/plugin-opener from desktop/package.json; the Rust plugin
and its capability entry were removed in Task 3, leaving this dangling.
- Reconcile desktop/package.json version 0.1.0 -> 0.1.6 to match Cargo.toml
and tauri.conf.json.
- Rewrite desktop/README.md, which still instructed users to
'sudo apt install webkit2gtk-4.0' -- the exact unavailable package this
port exists to move off. Now documents npm workspaces, the --legacy-peer-deps
requirement, the dist/-before-cargo gotcha, snap LD_LIBRARY_PATH breakage,
AppImage FUSE fallback, and the vendored patch.
Disclosure note: commit 4626858 also committed the previously untracked
nlink-cli/ and vendor/ trees (~5900 lines). Committing vendor/ is required --
the [patch.crates-io] override cannot resolve without it -- but the commit
message did not say so. Recorded here rather than rewriting branch history.
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
2.9 KiB
2.9 KiB
N-Link
Free, cross-platform, CX-II compatible computer linking program for the TI-Nspire.
This package is a Tauri 2 + Vue 3 + Vite application. It was ported from
Tauri 1.0.0-beta.8 / Vue CLI, which linked webkit2gtk-4.0 and could not build
or run on current distributions (Ubuntu 26.04 ships only webkit2gtk-4.1).
Currently Linux-only: bundle targets are deb and appimage.
Prerequisites
- Node.js 22+ (npm ships with it — this project uses npm workspaces, not yarn)
- Rust 1.97+
- System libraries (Ubuntu/Debian):
sudo apt-get install -y \
libwebkit2gtk-4.1-dev \
libjavascriptcoregtk-4.1-dev \
libsoup-3.0-dev \
librsvg2-dev \
libxdo-dev \
libayatana-appindicator3-dev \
libusb-1.0-0-dev \
build-essential curl wget file
Verify they resolve before building:
for p in webkit2gtk-4.1 javascriptcoregtk-4.1 libsoup-3.0 gtk+-3.0 libusb-1.0; do
printf "%-24s " "$p"; pkg-config --modversion "$p" || echo MISSING
done
Setup
Run from the repository root (this is a workspace member):
npm install --workspace desktop --legacy-peer-deps
--legacy-peer-deps is currently required: the sibling n-link-core package is
still on Vue 2 and its peer ranges conflict. It can be dropped once n-link-core
is ported to Vue 3.
Development
cd desktop
npm run tauri dev
Production build
cd desktop
npm run tauri build
Produces src-tauri/target/release/bundle/deb/*.deb and
.../appimage/*.AppImage.
Headless CLI
The same binary works without a GUI:
./src-tauri/target/release/n-link --help
./src-tauri/target/release/n-link ls /
Notes and gotchas
cargocommands needdist/to exist. Tauri'sgenerate_context!macro validates thefrontendDistpath at compile time, so a barecargo check/cargo buildinsrc-tauri/fails on a fresh clone until the frontend has been built once:npm run build --workspace desktop.npm run tauri builddoes this for you.- Do not run the binary from a snap-confined shell (for example, the
integrated terminal of VS Code installed as a snap). Snap injects an
LD_LIBRARY_PATHwhoselibpthreadshadows the system one, producingundefined symbol: __libc_pthread_init. Use a normal terminal. - AppImage needs FUSE. Without it, run the AppImage with
--appimage-extractand launchsquashfs-root/AppRuninstead. vendor/libnspire-sysat the repo root is a locally patched crate wired in via[patch.crates-io]. It raises the CX II NNSE handshake retry limit (10 → 30). The build will not reproduce upstream behaviour without it.- Known upstream limitation: libnspire's CX II support has been frozen since
2020. Against current CX II firmware, data transfers may return
Busyor hang. This is independent of the Tauri version and is not a defect in this port.