Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func NaturalLibraryName ¶
func NaturalLibraryName() string
NaturalLibraryName is the natural platform shared-library file name for the runtime cdylib — the `.node` file renamed to what a Rust cdylib would be called on this OS. The library is loaded by absolute path, so the on-disk name is ours to choose; this matches the flat name the bundler installs next to the CLI binary and the name the other SDKs use.
func PrebuildsFolder ¶
func PrebuildsFolder() string
PrebuildsFolder returns the napi-rs `<node-platform>-<arch>` folder name the runtime package ships under prebuilds/ (e.g. linux-x64, darwin-arm64, win32-x64, including the musl variant on Alpine). Returns "" for unsupported platforms.
func ResolveLibraryPath ¶
ResolveLibraryPath resolves the native runtime library next to the given CLI entrypoint. It checks, in order:
- The natural platform library name next to the CLI (bundled/flat layout).
- prebuilds/<platform>/runtime.node next to the CLI (dev/package layout).
It returns an error when neither exists.
Types ¶
This section is empty.