Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Detect go binary packages #3894

Merged
merged 7 commits into from
Oct 19, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions CHANGELOG.rst
Original file line number Diff line number Diff line change
Expand Up @@ -9,10 +9,13 @@ v33.0.0 (next next, roadmap)
- OpenWRT packages.
- Yocto/BitBake .bb recipes.


- Fallback packages for non-native dependencies of SCTK.
- Dependencies for
- Support for copyright detection objects.

- We can now collect packages from a Go binary using go-inspector (Linux-only)

- A new field in packages with the license category for the
detected license expression and also an API function to
compute license categories from license expressions.
Expand Down
1 change: 1 addition & 0 deletions requirements-linux.txt
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
packagedcode-msitools==0.101.210706
regipy==3.1.0
rpm-inspector-rpm==4.16.1.3.210404
go-inspector==0.3.1
1 change: 1 addition & 0 deletions setup-mini.cfg
Original file line number Diff line number Diff line change
Expand Up @@ -150,6 +150,7 @@ packages =
rpm_inspector_rpm >= 4.16.1.3; platform_system == 'Linux'
regipy >= 3.1.0; platform_system == 'Linux'
packagedcode_msitools >= 0.101.210706; platform_system == 'Linux'
go-inspector >= 0.3.1; platform_system == 'Linux'


[options.entry_points]
Expand Down
1 change: 1 addition & 0 deletions setup.cfg
Original file line number Diff line number Diff line change
Expand Up @@ -150,6 +150,7 @@ packages =
rpm_inspector_rpm >= 4.16.1.3; platform_system == 'Linux'
regipy >= 3.1.0; platform_system == 'Linux'
packagedcode_msitools >= 0.101.210706; platform_system == 'Linux'
go-inspector >= 0.3.1; platform_system == 'Linux'


[options.entry_points]
Expand Down
6 changes: 6 additions & 0 deletions src/packagedcode/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -247,6 +247,12 @@
win_reg.InstalledProgramFromDockerUtilityvmSoftwareHandler,
]

try:
from go_inspector.binary import get_go_binary_handler
APPLICATION_PACKAGE_DATAFILE_HANDLERS.append(get_go_binary_handler())
except ImportError:
pass

ALL_DATAFILE_HANDLERS = (
APPLICATION_PACKAGE_DATAFILE_HANDLERS + [
p for p in SYSTEM_PACKAGE_DATAFILE_HANDLERS
Expand Down
Loading
Loading