ngipkgs icon indicating copy to clipboard operation
ngipkgs copied to clipboard

libresoc: centralize existing packages, fix bitrot, and enable all test suites

Open jleightcap opened this issue 1 year ago • 13 comments

Libre-SOC

  • Collect prior work (thanks @L-as!)
  • Refactor all packages to most recent upstream releases
  • Enable test suites for main projects components

Packages

This PR packages up to Verilog synthesis, ASIC and FPGA -specific derivations to follow.

verilog v

closes #11.

jleightcap avatar Apr 01 '24 00:04 jleightcap

Glad to see the work revived

L-as avatar Apr 01 '24 05:04 L-as

Still in the process of reviewing this, but I wonder if CI is failing because you made this PR from a fork similar to https://github.com/ngi-nix/ngipkgs/pull/163 . The error message isn't as clear though this time

albertchae avatar Apr 11 '24 18:04 albertchae

Still in the process of reviewing this, but I wonder if CI is failing because you made this PR from a fork similar to #163 . The error message isn't as clear though this time

Yep, creating PR within this repo shows a meaningful failure: https://github.com/ngi-nix/ngipkgs/actions/runs/8652912908/job/23726892007 CI should produce that same error when ran from forks, like in this PR.

jleightcap avatar Apr 11 '24 20:04 jleightcap

Thanks for listening through an explanation of this whole PR, @albertchae! Getting a second set of eyes really helped to clarify a lot of the explanatory comments.

jleightcap avatar Apr 26 '24 05:04 jleightcap

I pushed up https://github.com/ngi-nix/ngipkgs/tree/libresoc-history-cleanup which replaces https://github.com/ngi-nix/ngipkgs/pull/168/commits/416a9410d561d543c4e73ecc677dead951770b95 with git mv when relevant. Many of these got almost entirely rewritten anyway, but git blame pkgs/by-name/libresoc/verilog.nix or git blame pkgs/by-name/libresoc/pinmux.nix should be more interesting.

albertchae avatar Apr 26 '24 09:04 albertchae

The git repos of Libre-SOC (https://git.libre-soc.org/) seem to be down. Obviously, without them nothing works. Maybe we could ask in their mailing list

RCoeurjoly avatar Apr 27 '24 10:04 RCoeurjoly

The git repos of Libre-SOC (https://git.libre-soc.org/) seem to be down. Obviously, without them nothing works. Maybe we could ask in their mailing list

I was also seeing intermittent 502s and 504s the past few days but I think they are still up... I was able to build locally after a few tries. @jleightcap and I are discussing possibly setting up a mirror for the repos packaged by this PR

albertchae avatar Apr 28 '24 07:04 albertchae

Thanks for helping sort out the CI questions, @lorenzleutgeb! Very cool to get this caching.

jleightcap avatar May 02 '24 16:05 jleightcap

Appreciate @albertchae bearing with a lengthy review process, believe this is good for last pass and merge!

jleightcap avatar May 02 '24 16:05 jleightcap

Two things:

  1. What can be done about the repeated comments regarding git.libre-soc.org? Would it be possible to create something like
fetchLibresoc = { repo, hash, rev }: fetchgit { ... }

And pass this to all packages that need it? Then we'd have one single point where one may switch between the mirrors and upstream, and only a single place to comment about it.

This is the right idea. Rather than commenting per-package, abstracted into a function: https://github.com/ngi-nix/ngipkgs/pull/168/files#diff-ebb18410bbc22267bb8bf27c4f2b8c9378010347fb3ac7a1ece107ebd2e507ddR5-R14

  1. Who actually owns github.com/Libre-SOC-mirrors?

me and @albertchae.

jleightcap avatar May 10 '24 22:05 jleightcap

Thanks for the pass @lorenzleutgeb, I populated meta appropriately and reduced with ...; ... to minimal scopes.

jleightcap avatar May 11 '24 17:05 jleightcap

Can you please also add an appropriate project, that is, create directory under /projects and then create /projects/${PROJECT_NAME}/default.nix. The name should match a project at https://nlnet.nl/project/${PROJECT_NAME}. Check out other projects for inspiration.

done, under Libre-SOC-OpenPOWER-ISA. cool to see the progress made on associating packages with NGI funding! :tada:

jleightcap avatar May 13 '24 04:05 jleightcap

@jleightcap could you address https://github.com/ngi-nix/ngipkgs/pull/168#discussion_r1603576351? Otherwise I think it's almost there, or am I missing something?

lorenzleutgeb avatar Jun 04 '24 09:06 lorenzleutgeb

Buildbot is running into an HTTP 404 trying to fetch https://github.com/eliben/libresoc-pyelftools/archive/8b97f5da6838791fd5c6b47b1623fb414daed2f0.tar.gz, see https://buildbot.ngi.nixos.org/api/v2/logs/2519/raw_inline

lorenzleutgeb avatar Jun 04 '24 09:06 lorenzleutgeb

Buildbot is running into an HTTP 404 trying to fetch https://github.com/eliben/libresoc-pyelftools/archive/8b97f5da6838791fd5c6b47b1623fb414daed2f0.tar.gz, see https://buildbot.ngi.nixos.org/api/v2/logs/2519/raw_inline

Ah, this was a bad name change I had introduced. Thanks for pointing out the symptom in CI: https://github.com/ngi-nix/ngipkgs/pull/168/commits/f71ad57f1fd993efa7ea381788d3932af631a018

@jleightcap could you address https://github.com/ngi-nix/ngipkgs/pull/168#discussion_r1603576351? Otherwise I think it's almost there, or am I missing something?

Should be all resolved now!

jleightcap avatar Jun 06 '24 22:06 jleightcap

Awesome! Thank @jleightcap @albertchae @L-as @lorenzleutgeb @wegank for the great work!

fricklerhandwerk avatar Jun 10 '24 19:06 fricklerhandwerk