I am trying to set up an environment with ssreflect 2.0.0. Here are the relevant lines of my config.nix
file:
buildInputs = [ "mathcomp-ssreflect" ];
/* ... */
bundles.default = {
coqPackages.coq.override.version = "8.17";
coqPackages.mathcomp.ssreflect.override.version = "2.0.0";
};
If I run nix-shell
, however, it is version 1.16 that is pulled up, not 2.0.0.
I have also tried pulling in all of mathcomp 2.0.0, by using "mathcomp"
as a build input, and by using coqPackages.mathcomp.override.version = "2.0.0";
in the above snippet. This works, but I would rather avoid the unnecessary dependencies...
Maybe you can coqPackages.mathcomp.fingroup.job = false
, coqPackages.mathcomp.algebra.job = false
and so on (not great though)
@Pierre Roux Do you mean writing coqPackages.mathcomp.fingroup.override.job = false;
?
without the override yes
@Pierre Roux Is there any way of testing whether this works without garbage collecting the previous derivations? I just ran nix-shell --pure
with the modified file, but it seems that it is just finding the packages that I had built earlier.
Maybe modifying the code to force recompilation? I don't know.
First, mathcomp is a bit peculiar. You need to override the version of coqPackages.mathcomp
even if what you are putting in your buildInputs is mathcomp-ssreflect
and nothing more.
Second, there is no need to garbage collect anything. If it is still finding the packages that you had built earlier, then somehow it means that you have not changed what it evaluates. Nix is functional in the sense that packages are pure functions of their inputs. So no side effect, like garbage-collection, should have any impact on the result.
@Théo Zimmermann That worked! Thanks.
Last updated: Nov 29 2023 at 21:01 UTC