dapphub / dapptools

Dapp, Seth, Hevm, and more
https://dapp.tools
2.1k stars 325 forks source link

flake: expose solc static versions #973

Closed d-xo closed 1 year ago

d-xo commented 1 year ago

Description

Exposes our solc versions in the nix flake

Checklist

d-xo commented 1 year ago

It lets someone install the patched (for nixos compat) versions of solc without installing dapp or seth.

asymmetric commented 1 year ago

@d-xo I think this breaks nix flake show. In case it does, maybe the packages could be exposed directly as attributes of packages, without the system attribute in between?

d-xo commented 1 year ago

oh I didn't even know nix flake show was a thing. why does this change break it?

asymmetric commented 1 year ago

Because it's supposed to find derivations (attrsets with a specific structure), whereas it finds an attrset like

{ x86_64-linux = { /* packages */}; x86_64-darwin = { /* packages */}; }

So you basically can't have package hierarchies under packages (or any other flake output, for that matter)

d-xo commented 1 year ago

oh I see, this stuff would really be a lot more obvious if nix had types. so whats the correct way to go about this? I want to be able to install every single solc version ever on my system using the flake interface, and I'm not sure the best way to expose them right now...

asymmetric commented 1 year ago

@d-xo I rebased on top of master (to fix the conflict) and added a couple of commits that should fix nix flake show.

Note that I had to remove aarch64-linux support for that, as we don't have static solc builds for it -- but I had been the one who added it, without thinking about it too much.

d-xo commented 1 year ago

sweet. looks great. thanks a lot ❤️