Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

installing on MacOS with nix fails because lnav pulls in gpm as a dpenendency #1350

Closed
mg opened this issue Dec 1, 2024 · 3 comments
Closed
Labels

Comments

@mg
Copy link

mg commented Dec 1, 2024

v0.12.3

Describe the bug
Installing lnav on MacOS using nix fails because latest version of lnav pulls in gpm (https://www.nico.schottelius.org/software/gpm/) as a dependency on MacOS.

To Reproduce
Steps to reproduce the behavior:
On a MacOS nix system try to install it in a nix shell
nix-shell -p lnav

output:

error:
       … while calling the 'derivationStrict' builtin
         at <nix/derivation-internal.nix>:34:12:
           33|
           34|   strict = derivationStrict drvAttrs;
             |            ^
           35|

       … while evaluating derivation 'shell'
         whose name attribute is located at /nix/store/5l2a0zjirsdyd87wxbvb9jf1g99dayy1-nixpkgs/nixpkgs/pkgs/stdenv/generic/make-derivation.nix:336:7

       … while evaluating attribute 'buildInputs' of derivation 'shell'
         at /nix/store/5l2a0zjirsdyd87wxbvb9jf1g99dayy1-nixpkgs/nixpkgs/pkgs/stdenv/generic/make-derivation.nix:383:7:
          382|       depsHostHost                = elemAt (elemAt dependencies 1) 0;
          383|       buildInputs                 = elemAt (elemAt dependencies 1) 1;
             |       ^
          384|       depsTargetTarget            = elemAt (elemAt dependencies 2) 0;

       (stack trace truncated; use '--show-trace' to show the full, detailed trace)

       error: Package ‘gpm-unstable-2020-06-17’ in /nix/store/5l2a0zjirsdyd87wxbvb9jf1g99dayy1-nixpkgs/nixpkgs/pkgs/servers/gpm/default.nix:60 is not available on the requested hostPlatform:
         hostPlatform.config = "aarch64-apple-darwin"
         package.meta.platforms = [
           "aarch64-linux"
           "armv5tel-linux"
           "armv6l-linux"
           "armv7a-linux"
           "armv7l-linux"
           "i686-linux"
           "loongarch64-linux"
           "m68k-linux"
           "microblaze-linux"
           "microblazeel-linux"
           "mips-linux"
           "mips64-linux"
           "mips64el-linux"
           "mipsel-linux"
           "powerpc64-linux"
           "powerpc64le-linux"
           "riscv32-linux"
           "riscv64-linux"
           "s390-linux"
           "s390x-linux"
           "x86_64-linux"
           "i686-cygwin"
           "x86_64-cygwin"
         ]
         package.meta.badPlatforms = [ ]
       , refusing to evaluate.

       a) To temporarily allow packages that are unsupported for this system, you can use an environment variable
          for a single invocation of the nix tools.

            $ export NIXPKGS_ALLOW_UNSUPPORTED_SYSTEM=1

          Note: When using `nix shell`, `nix build`, `nix develop`, etc with a flake,
                then pass `--impure` in order to allow use of environment variables.

       b) For `nixos-rebuild` you can set
         { nixpkgs.config.allowUnsupportedSystem = true; }
       in configuration.nix to override this.

       c) For `nix-env`, `nix-build`, `nix-shell` or any other Nix command you can add
         { allowUnsupportedSystem = true; }
       to ~/.config/nixpkgs/config.nix.
@mg mg added the bug label Dec 1, 2024
@CharlesChiuGit
Copy link

can comfirm

@tstack
Copy link
Owner

tstack commented Jan 25, 2025

Is there something you want me to do here? I don't control the packaging for lnav.

@mg
Copy link
Author

mg commented Jan 25, 2025

If this was just an packaging issue then no, there is nothing I am expecting of you here.
I just wasn't sure, and since I don't know your codebase I did not know it was something to do with Nix or something to do with the latest version of lnav.
But whatever it was, it has been resolved, installing lnav now works on MacOS.

Sorry about the bother.

@mg mg closed this as completed Jan 25, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

3 participants