question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Project won't build when using a dependency installed using nix

See original GitHub issue

Hello,

First of all I think this plugin is awesome. It provides a lot of cool features, and even if I struggled to get it to work at the begining, it was working like a charm so far, so thank you for the amazing work !

I am working on an llvm project right now. I need to use llvm-6.0 for that, and I needed nix to get this specific package.

My whole project is working just fine, all the plugin’s options work. However, since I added llvm, the plugin goes crazy, and spams me with messages like [global-stack-repl] Stack REPL couldn't be started within 5 seconds The first error message is Project won't be built because building its dependencies failed so I guessed that my llvm dependency broke it all.

My stack.yaml:

resolver: lts-12.18

packages:
- .

extra-deps:
  - llvm-hs-6.0.0
  - llvm-hs-pure-6.0.0

flags:
  llvm-hs:
    shared-llvm: true

nix:
  enable: true
  packages: [llvm_6]

My dependencies in the package.yaml (only thing I changed in the file):

dependencies:
- base >= 4.7 && < 5
- llvm-hs
- llvm-hs-pure
- bytestring

In short, none of the plugin’s features work since I added that llvm-6.0 dependency via nix to the project.

Issue Analytics

  • State:closed
  • Created 4 years ago
  • Comments:70 (37 by maintainers)

github_iconTop GitHub Comments

2reactions
fabriencommented, Feb 27, 2020

Wow, it is working now!

I still need to set the PATH variable to

PATH $PATH$:/home/Arthamios/.nix-profile/bin

but if that is set, together with the other variables

NIX_PATH /nix/store/6lpcyrjnzj5kqksghpn6z1aw0bxhaygc-user-environment
NIX_PROFILES /nix/var/nix/profiles/default /home/Arthamios/.nix-profile
NIX_SSL_CERT_FILE /etc/pki/ca-trust/extracted/pem/tls-ca-bundle.pem

Everything is actually running fine! The only thing now not functionnal is the documentation, but that did not work before this llvm issue, so it is another issue.

Thanks a lot for all the support and help you provided and the time you invested on resolving this issue!

1reaction
rikvdkleijcommented, Feb 27, 2020

Btw, released beta63 with again improvements

Read more comments on GitHub >

github_iconTop Results From Across the Web

Nix external software built/installed is not being found
I've just started using the Nix package manager on OSX and I'm attempting to create my first package for the pass binary (https://www.passwordstore.org) ......
Read more >
Introduction - NixOS
Complete dependencies. Nix helps you make sure that package dependency specifications are complete. In general, when you're making a package for a package ......
Read more >
Nix integration - The Haskell Tool Stack
When using the Nix integration, Haskell dependencies are handled as usual: They are downloaded from Stackage and built locally by Stack.
Read more >
Install prebuilt packages without root, from nixpkgs - The Gallery
Project URL: Glitch :・゚✧ I've been trying out Nix, that package manager that ... We can't create that directory out in the root...
Read more >
How to package my software in nix or ... - Unix Stack Exchange
So create another file default.nix (the name is important here as nix ... annoying to debug a program using nix-build as nix-build will...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found