Description
Independently of #9878, we need an easy way to declare additional packages for an ORT analyzer run to cover cases where packages cannot be determined automatically via one of the existing package managers.
Historically, our fallback for that case was the SpdxDocumentFile analyzer, allowing the user to put SPDX files in the file tree to get picked up and parsed by the analyzer. However, this approach has several drawbacks:
- SPDX is hard to write by hand (even the SPDX Lite profile).
- SPDX has too many ways to express the semantically same thing with different syntax (e.g. the
DEPENDENCY_OF
vsDEPENDS_ON
relations). - there may be other reasons for SPDX files being present in the file tree, which should not get picked up.
For a while now, the cli-helper offers a CreateAnalyzerResultFromPackageListCommand as a simpler way to declared additional packages via a (flat) PackageList. However, that command needs to be run separately, and creates a stand-alone ORT analyzer result, which makes integration with existing results hard (also see #4364). Any easy way to solve that would be to come up with a conventional filename for such package lists, and create a package manager implementation for them, very similar to the current SpdxDocumentFile
package manager.
Finally, also other approaches exist to simplify declaration of packages metadata, like ABCD or kissbom.
This issue is about finding our preferred way of "injecting" additional packages into an ORT analyzer run.