fusesoc icon indicating copy to clipboard operation
fusesoc copied to clipboard

Vunit dependencies

Open nopeslide opened this issue 3 years ago • 7 comments

added fields to return value of get_files

  • "fileset": fileset which included the src file
  • "core": name of the core which included the src file
  • "depend": name list of core dependencies

nopeslide avatar Nov 21 '22 15:11 nopeslide

WIP because I do not know if this is the intended way to add such a feature

nopeslide avatar Nov 21 '22 16:11 nopeslide

Ok, this is an interesting feature and I'm definitely open to adding more metadata to the EDAM file. I just want to be careful to not expose too much internal FuseSoC details since Edalize is intended to work without FuseSoC (and it is already used by a bunch of other projects).

Adding core is the least controversial in my opinion.

I'm less sure about fileset. To me that feels like an internal FuseSoC detail. Do you need that? I don't see it being used in https://github.com/olofk/edalize/pull/358

I see two issues with depend. The first is that we probably need to parse the list to evaluate the flags before sending it to the EDAM. The other thing is that the EDAM file already contains the dependency tree, so if you know which core a file belongs to, you can figure out its dependencies. So with that, I don't think we need to specify dependencies on a file-level as well.

So, I'm happy to accept a modified patch that only adds the "core" field. If you still want to include the other stuff, then we need to discuss that.

olofk avatar Nov 25 '22 23:11 olofk

@olofk I didn't know the edam already contained the dependency tree

nopeslide avatar Nov 28 '22 14:11 nopeslide

Anything else I missed? I did no thorough testing, is there any test setup I can use?

nopeslide avatar Dec 19 '22 08:12 nopeslide

I tested this just now and there is actually a test that breaks with this change. test_capi2_get_files in https://github.com/olofk/fusesoc/blob/main/tests/test_capi2.py breaks. Also, I think you should convert the Vlnv object to a string first, instead of adding it directly

olofk avatar Jan 08 '23 16:01 olofk

@nopeslide I'm planning to release FuseSoC 2.0 very soon. If we want this patch to go in before that, then we need to fix the failing test and do the VLNV to string conversion.

olofk avatar Jan 16 '23 21:01 olofk

@olofk rebased on latest main see olofk/edalize#384

nopeslide avatar May 20 '23 09:05 nopeslide