Skip to content

Tests can't find libjanet on NixOS #88

@hatzka-nezumi

Description

@hatzka-nezumi

NixOS has an unusual filesystem layout in which packages live under unique paths in /nix/store, and PATH and similar environment variables are manipulated to ensure each program can find the libraries meant for it and no others. For example, on my system ,which janet is /nix/store/n36k55y82g9qlcdxwy7v0gpjwhias7xw-janet-1.33.0/bin/janet. (If janet linked to any dynamic libraries, this would be a shell script that sets up the variables and then execs into the actual janet binary, but it doesn't so that step isn't necessary.)

Although jpm show-paths prints the correct paths, for whatever reason, when running jpm test, it defaults to /usr/local/lib/libjanet.a and fails when that file doesn't exist. Setting JANET_LIBPATH explicitly makes it work.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions