mirror of
https://github.com/nix-community/dream2nix.git
synced 2024-11-29 23:35:33 +03:00
Merge pull request #430 from nix-community/feat/make-crane-default
This commit is contained in:
commit
2d7d68505c
@ -14,11 +14,11 @@ Translates a `Cargo.toml` file to a dream2nix lockfile by generating a `Cargo.lo
|
||||
|
||||
## Builders
|
||||
|
||||
### build-rust-package (pure) (default)
|
||||
### build-rust-package (pure)
|
||||
|
||||
Builds a package using `buildRustPackage` from `nixpkgs`.
|
||||
|
||||
### crane (ifd)
|
||||
### crane (ifd) (default)
|
||||
|
||||
Builds a package using [`crane`](https://github.com/ipetkov/crane).
|
||||
This builder builds two separate derivations, one for dependencies and the other for your crate.
|
||||
@ -173,3 +173,19 @@ in
|
||||
# ...
|
||||
}
|
||||
```
|
||||
|
||||
### Specifying the `stdenv`
|
||||
|
||||
`crane` supports specifying the `stdenv` like so:
|
||||
```nix
|
||||
{
|
||||
# ...
|
||||
packageOverrides = {
|
||||
# change all derivations' stdenv to clangStdenv
|
||||
"^.*".set-stdenv.override = old: {stdenv = pkgs.clangStdenv;};
|
||||
};
|
||||
# ...
|
||||
}
|
||||
```
|
||||
|
||||
`build-rust-package` builder does not support specifying the `stdenv`.
|
||||
|
@ -2,7 +2,7 @@
|
||||
l = config.lib;
|
||||
defaults = {
|
||||
# TODO: define a priority in each builder and remove the defaults here.
|
||||
rust = "build-rust-package";
|
||||
rust = "crane";
|
||||
nodejs = "granular-nodejs";
|
||||
python = "simple-python";
|
||||
php = "granular-php";
|
||||
|
Loading…
Reference in New Issue
Block a user