djanatyn / ssbm-nix

Nix expressions for Super Smash Bros. Melee players.
31 stars 17 forks source link

Update nixpkgs and downgrade mbedtls #35

Open jumper149 opened 1 year ago

ursi commented 1 year ago

I'm getting

Function called without required argument "mbedtls_2" at /nix/store/dl2ha5jv9ixifi64z1yfdznznr7dps5c-source/slippi/default.nix:5, did you mean "mbedtls"?
ursi commented 1 year ago

interesting, running nix build github:jumper149/ssbm-nix/mbedtls2#slippi-netplay does work for me. I'm not sure why my system won't build :thinking:

jumper149 commented 1 year ago

@ursi You are probably supplying your own nixpkgs.

This branch updated the pinned nixpkgs in the flake.lock: https://github.com/djanatyn/ssbm-nix/blob/3a02c38e1f1d318a2c8eb3022251e23796541448/flake.lock#L58


What you are doing is not completely wrong though.

I am currently stuck on this nixpkgs pin, because with newer nixpkgs it also won't build anymore. And using slippi from this flake, but without your system nixpkgs, can often fail, because there are some runtime dependencies like glibc which slippi expects.

The situation is pretty bad unfortunately :(

You would be fine, if you used the pinned nixpkgs from here also for your whole system, but that can't be the solution for too long.


If someone wanted to fix the problem, that I'm having they would have to do this:

  1. Clone this branch.
  2. Update nixpkgs to current unstable: nix flake lock --update-input nixpkgs
  3. Build slippi: nix build .#packages.x86_64-linux.slippi-netplay
  4. Find out, what the problem is. I got stuck on something like "Can't find glibconfig.h".
  5. Fix the problem...
ursi commented 1 year ago

I'm using my own nixpkgs, but I'm adding mbedtls_2 with an overlay, so I'm not sure why it can't find it. Adding it here if you're curious https://github.com/ursi/config/blob/e85e8ab5d1ad7517bafbe3a72e6eea0a747eec6d/flake.nix#L57-L71

jumper149 commented 1 year ago

Well, if you are on an older nixpkgs, you should just be using a different pin on this flake. Have you tried djanatyn:master instead of this branch?

Also I'm not sure, if a simple override/overlay would work here. Maybe some dependencies build upon each other, idk in particular though.

ursi commented 1 year ago

master works