config.contentAddressedByDefault: init option
This commit is contained in:
parent
d76021402d
commit
33415135b0
@ -75,7 +75,7 @@ rec {
|
||||
inherit (bootstrapFiles) mkdir bzip2 cpio tarball;
|
||||
|
||||
__impureHostDeps = commonImpureHostDeps;
|
||||
} // lib.optionalAttrs (config.contentAddressedByDefault or false) {
|
||||
} // lib.optionalAttrs config.contentAddressedByDefault {
|
||||
__contentAddressed = true;
|
||||
outputHashAlgo = "sha256";
|
||||
outputHashMode = "recursive";
|
||||
|
@ -182,7 +182,7 @@ in
|
||||
buildInputs = [ make ];
|
||||
mkdir = "/bin/mkdir";
|
||||
ln = "/bin/ln";
|
||||
} // lib.optionalAttrs (config.contentAddressedByDefault or false) {
|
||||
} // lib.optionalAttrs config.contentAddressedByDefault {
|
||||
__contentAddressed = true;
|
||||
outputHashAlgo = "sha256";
|
||||
outputHashMode = "recursive";
|
||||
|
@ -90,7 +90,7 @@ let
|
||||
allowedRequisites = allowedRequisites
|
||||
++ defaultNativeBuildInputs ++ defaultBuildInputs;
|
||||
}
|
||||
// lib.optionalAttrs (config.contentAddressedByDefault or false) {
|
||||
// lib.optionalAttrs config.contentAddressedByDefault {
|
||||
__contentAddressed = true;
|
||||
outputHashAlgo = "sha256";
|
||||
outputHashMode = "recursive";
|
||||
|
@ -93,7 +93,7 @@ in
|
||||
|
||||
, __contentAddressed ?
|
||||
(! attrs ? outputHash) # Fixed-output drvs can't be content addressed too
|
||||
&& (config.contentAddressedByDefault or false)
|
||||
&& config.contentAddressedByDefault
|
||||
|
||||
, ... } @ attrs:
|
||||
|
||||
|
@ -66,7 +66,7 @@ let
|
||||
bootstrapTools = import (if localSystem.libc == "musl" then ./bootstrap-tools-musl else ./bootstrap-tools) {
|
||||
inherit system bootstrapFiles;
|
||||
extraAttrs = lib.optionalAttrs
|
||||
(config.contentAddressedByDefault or false)
|
||||
config.contentAddressedByDefault
|
||||
{
|
||||
__contentAddressed = true;
|
||||
outputHashAlgo = "sha256";
|
||||
|
@ -235,7 +235,7 @@ in with pkgs; rec {
|
||||
|
||||
bootstrapTools =
|
||||
let extraAttrs = lib.optionalAttrs
|
||||
(config.contentAddressedByDefault or false)
|
||||
config.contentAddressedByDefault
|
||||
{
|
||||
__contentAddressed = true;
|
||||
outputHashAlgo = "sha256";
|
||||
|
@ -36,6 +36,10 @@ let
|
||||
feature = "set <literal>strictDeps</literal> to true by default";
|
||||
};
|
||||
|
||||
contentAddressedByDefault = mkMassRebuild {
|
||||
feature = "set <literal>__contentAddressed</literal> to true by default";
|
||||
};
|
||||
|
||||
allowAliases = mkOption {
|
||||
type = types.bool;
|
||||
default = true;
|
||||
|
Loading…
Reference in New Issue
Block a user