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

Build dependencies only #1181

Open
deemp opened this issue Jan 25, 2024 · 1 comment
Open

Build dependencies only #1181

deemp opened this issue Jan 25, 2024 · 1 comment

Comments

@deemp
Copy link
Contributor

deemp commented Jan 25, 2024

Related to #1180.

As spago supports offline builds, it's now possible to use spago in Nix derivations.

If a package has some non-local and local dependencies, I'd like to build them and put into a derivation and then use that derivation for building the package derivation. This way, I'll be able to avoid rebuilding dependencies when the package code changes.

However, for spago 0.93.24, I only see:

  • spago install that builds non-local dependencies
  • spago build that builds the package and its dependencies

So, I can't build only local dependencies in a derivation. I have to run spago build for each local dependency, which isn't particularly convenient.

Moreover, I have to include the package directory into dependencies derivation. Hence, when I change a file in that directory, the whole dependencies derivation has to be rebuilt.

@bakhtiyarneyman
Copy link

+1.

IMHO it would be fantastic if spago facilitated cargo2nix-style (1 nix package per 1 spago package or workspace) rather than crane-style (1 package with all of deps) building.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants