files: fix activation under Nix 2.3
In Nix 2.3, all GC roots must be stored under `/nix/var/nix/gcroots`, unless `--indirect` is specified. In Nix 2.4 and above, this flag is ignored, because all GC roots created by `--add-root` are indirect. Change-Id: I3eb3d7bc774af2ff336a2cdf312d30a99cdcb928
This commit is contained in:
parent
b3a9fb9d05
commit
17431970b4
|
@ -274,7 +274,7 @@ in
|
||||||
run nix-env $VERBOSE_ARG --profile "$genProfilePath" --set "$newGenPath"
|
run nix-env $VERBOSE_ARG --profile "$genProfilePath" --set "$newGenPath"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
run --quiet nix-store --realise "$newGenPath" --add-root "$newGenGcPath"
|
run --quiet nix-store --realise "$newGenPath" --add-root "$newGenGcPath" --indirect
|
||||||
if [[ -e "$legacyGenGcPath" ]]; then
|
if [[ -e "$legacyGenGcPath" ]]; then
|
||||||
run rm $VERBOSE_ARG "$legacyGenGcPath"
|
run rm $VERBOSE_ARG "$legacyGenGcPath"
|
||||||
fi
|
fi
|
||||||
|
|
Loading…
Reference in a new issue